From patchwork Mon Aug 22 15:21:26 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 74445 Delivered-To: patch@linaro.org Received: by 10.140.29.52 with SMTP id a49csp1626701qga; Mon, 22 Aug 2016 08:23:24 -0700 (PDT) X-Received: by 10.28.20.139 with SMTP id 133mr15309967wmu.78.1471879404796; Mon, 22 Aug 2016 08:23:24 -0700 (PDT) Return-Path: Received: from theia.denx.de (theia.denx.de. [85.214.87.163]) by mx.google.com with ESMTP id i7si18885277wjo.244.2016.08.22.08.23.24; Mon, 22 Aug 2016 08:23:24 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 85.214.87.163 as permitted sender) client-ip=85.214.87.163; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 85.214.87.163 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 1A9F2A7528; Mon, 22 Aug 2016 17:22:45 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id F-_x75LGwISG; Mon, 22 Aug 2016 17:22:45 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 86B17A7544; Mon, 22 Aug 2016 17:22:25 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 4011E4B62B for ; Mon, 22 Aug 2016 17:21:54 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ExJJ7D5-b3Nb for ; Mon, 22 Aug 2016 17:21:54 +0200 (CEST) Received: from comal.ext.ti.com (comal.ext.ti.com [198.47.26.152]) by theia.denx.de (Postfix) with ESMTPS id 2ED874B624 for ; Mon, 22 Aug 2016 17:21:52 +0200 (CEST) Received: from dflxv15.itg.ti.com ([128.247.5.124]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id u7MFLZnn026363; Mon, 22 Aug 2016 10:21:35 -0500 Received: from DFLE73.ent.ti.com (dfle73.ent.ti.com [128.247.5.110]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id u7MFLYak018810; Mon, 22 Aug 2016 10:21:34 -0500 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE73.ent.ti.com (128.247.5.110) with Microsoft SMTP Server id 14.3.294.0; Mon, 22 Aug 2016 10:21:33 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id u7MFLYPp017998; Mon, 22 Aug 2016 10:21:34 -0500 Received: from localhost (uda0226330.am.dhcp.ti.com [128.247.83.105]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id u7MFLX327539; Mon, 22 Aug 2016 10:21:33 -0500 (CDT) From: "Andrew F. Davis" To: Lokesh Vutla , Heiko Schocher , Gilles Gameiro , Daniel Allred , Madan Srinivas , Simon Glass , Enric Balletbo i Serra , Hannes Schmelzer , Tom Rini , Tero Kristo Date: Mon, 22 Aug 2016 10:21:26 -0500 Message-ID: <20160822152131.15340-7-afd@ti.com> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20160822152131.15340-1-afd@ti.com> References: <20160822152131.15340-1-afd@ti.com> MIME-Version: 1.0 Cc: u-boot@lists.denx.de Subject: [U-Boot] [PATCH v2 06/11] board: am33xx-hs: spl: Allow post-processing of FIT image on AM33xx X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" When CONFIG_FIT_IMAGE_POST_PROCESS or CONFIG_SPL_FIT_IMAGE_POST_PROCESS is enabled board_fit_image_post_process will be called, add this function to am33xx boards when CONFIG_TI_SECURE_DEVICE is set to verify the loaded image. Signed-off-by: Andrew F. Davis --- board/ti/am335x/board.c | 8 ++++++++ 1 file changed, 8 insertions(+) -- 2.9.3 _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c index 56f4984..0ed16ca 100644 --- a/board/ti/am335x/board.c +++ b/board/ti/am335x/board.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #include #include @@ -775,3 +776,10 @@ int board_fit_config_name_match(const char *name) return -1; } #endif + +#ifdef CONFIG_TI_SECURE_DEVICE +void board_fit_image_post_process(void **p_image, size_t *p_size) +{ + secure_boot_verify_image(p_image, p_size); +} +#endif