Message ID | 1515433001-13857-23-git-send-email-bryan.odonoghue@linaro.org |
---|---|
State | Superseded |
Headers | show
Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp3022247qgn; Mon, 8 Jan 2018 09:53:50 -0800 (PST) X-Google-Smtp-Source: ACJfBou5kQznhiuvL28Kugp7kQ8F6mjvKlSHJYzEYewG36raG5Jdi/CefaJdKcv17XUbPtPcd5ke X-Received: by 10.80.244.195 with SMTP id v3mr17369722edm.165.1515434030732; Mon, 08 Jan 2018 09:53:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1515434030; cv=none; d=google.com; s=arc-20160816; b=FGduv15hrwDyvzYFOIuunmuKrdfzInrPoILOUn5QjJG+Jvz6WrXu3n1M+VQKhIkoKo IbDi2Ho/z4E7Cr4WYX9Zptg9GRhmkqvWzZEfzlPRnosP5r4UrwsaKjb+TOGs/AWQKpPx H+Kk+BEuyWyx+4BmeX26hYeDNgWM3GcarAYz8SL825NrEBuhv9b1qg+R/pf3mdxxfJ/+ SQR3vHWIt3hZa4Dtxgzxn4VEjXKolsazJlqjDX5Dd2nqarz2M8DLpkBSBvM6GrrOxcgZ jXTvBqyW1bus2EGK6zpF6FyhI1pN2yEBjTkvoBUBv/kM4F9ujLIhJkEmQzeQVP1InW7K u35Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:references:in-reply-to:message-id :date:to:from:dkim-signature:arc-authentication-results; bh=nEiq0xect4AoWDmrA6PY0pIBd0aNAXXS+iZ9gzfxaCI=; b=yX9+mpED5ph5EMHNbM+A2VANQ1iZA+XVGVb0QCELmbHn6BAn04s6bZkrHyNU7PTvPQ 75oH2thnIqMyBFm9NDYvQs6Remc2YqopBdROb3AVzMI2iL3dRPsnoEYmR9B/+IEVJX94 CCw896JEBj2pM8DzHbbRn95CkayVxBwNl/rjKskQnfUN9kvqtf1mDDoRe+uuYx1bGmq4 XfCCoL1mIP/6Y6TXFuXTF0X4CutVOUh+IovIZ8FJfdKa03hxuZRmaHcnzR0Q8fmTZK1W P4xTBWm7QA3me5EP+HYWrpUXrhd+Ir0liHunKwa3vOfIihrtXNazAR76Bi75NXLbmHGQ 73kw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=dDHefnh8; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: <u-boot-bounces@lists.denx.de> Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id n11si273880edi.134.2018.01.08.09.53.50; Mon, 08 Jan 2018 09:53:50 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=dDHefnh8; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.denx.de (Postfix, from userid 105) id 029D1C21F7E; Mon, 8 Jan 2018 17:42:49 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 74AF8C21F7E; Mon, 8 Jan 2018 17:38:54 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 3DFC1C21FC9; Mon, 8 Jan 2018 17:37:17 +0000 (UTC) Received: from mail-wm0-f67.google.com (mail-wm0-f67.google.com [74.125.82.67]) by lists.denx.de (Postfix) with ESMTPS id A0AE1C21FD4 for <u-boot@lists.denx.de>; Mon, 8 Jan 2018 17:37:12 +0000 (UTC) Received: by mail-wm0-f67.google.com with SMTP id y82so16766486wmg.1 for <u-boot@lists.denx.de>; Mon, 08 Jan 2018 09:37:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=cYwMYV7HIFFPZjWLmuiyD2xuH7kQg/RPLyU9z34NM2o=; b=dDHefnh8kFxSCWT9sfNJKHCIJDl+/VHYIAsZ1CqqNBtvHGRbMNKYDuW6N2vX8nGxZi f+9uwEHtS/liviBQo6dXjxSPkALOTUPIS22FETub3Bo8WnBHg20D6OUisUgcmazdtsRE 6G3xT4CL7WskQetHQDjKA8SLCd8VNVoeBUo/A= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=cYwMYV7HIFFPZjWLmuiyD2xuH7kQg/RPLyU9z34NM2o=; b=cdQGfKn+Z2qlXXxWQQJGnEEj9KMkZ/ki2SZUJ+frxDUVawTrQy0r2QpSQrXbIkC6QC vSDSll9vQjjid3ERCCTrkSVBzGsrPEPdDRX6vZcMewGKMJA7eTcw0JVnaZwulun4/H0R m67BcXIElOHcLFxqeBZbS3si33RapOGenlz/ZPSUs7LEyupyYvWixsKAJVfhxWYwv6jK nYoMsU/tvqG/vSG3LnBW2+qB4RONnJoRpkOY/vJB22YzzHJUnw/SzvoLq9WHvf3sugtE iE9iLmlNXKq23fQB6HFb8nPiEsTbUX9BDBc0hVb6CsG7CgXmsw3bn/9WyV2lNVWTAaSh m8Hg== X-Gm-Message-State: AKGB3mJWygKTIV3dwmUU+hGfVTp25Dg+F7Iu7IxUgkTtMkMhBhJ/qmAI +skGJoEdx2rqqpsmynNRlefCrmG9IyI= X-Received: by 10.80.173.163 with SMTP id a32mr17850453edd.114.1515433032052; Mon, 08 Jan 2018 09:37:12 -0800 (PST) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id a38sm7160033edf.3.2018.01.08.09.37.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 08 Jan 2018 09:37:11 -0800 (PST) From: Bryan O'Donoghue <bryan.odonoghue@linaro.org> To: u-boot@lists.denx.de, brenomatheus@gmail.com Date: Mon, 8 Jan 2018 17:36:39 +0000 Message-Id: <1515433001-13857-23-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1515433001-13857-1-git-send-email-bryan.odonoghue@linaro.org> References: <1515433001-13857-1-git-send-email-bryan.odonoghue@linaro.org> Cc: Fabio Estevam <fabio.estevam@nxp.com> Subject: [U-Boot] [PATCH v5 22/24] arm: imx: hab: Define rvt_failsafe() X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion <u-boot.lists.denx.de> List-Unsubscribe: <https://lists.denx.de/options/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=unsubscribe> List-Archive: <http://lists.denx.de/pipermail/u-boot/> List-Post: <mailto:u-boot@lists.denx.de> List-Help: <mailto:u-boot-request@lists.denx.de?subject=help> List-Subscribe: <https://lists.denx.de/listinfo/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=subscribe> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" <u-boot-bounces@lists.denx.de> |
Series |
Fix and extend i.MX HAB layer
|
expand
|
diff --git a/arch/arm/include/asm/mach-imx/hab.h b/arch/arm/include/asm/mach-imx/hab.h index 5c13aff..a0cb19d 100644 --- a/arch/arm/include/asm/mach-imx/hab.h +++ b/arch/arm/include/asm/mach-imx/hab.h @@ -140,6 +140,7 @@ typedef void *hab_rvt_authenticate_image_t(uint8_t, ptrdiff_t, void **, size_t *, hab_loader_callback_f_t); typedef enum hab_status hab_rvt_check_target_t(enum hab_target, const void *, size_t); +typedef void hab_rvt_failsafe_t(void); typedef void hapi_clock_init_t(void); #define HAB_ENG_ANY 0x00 /* Select first compatible engine */ @@ -170,6 +171,7 @@ typedef void hapi_clock_init_t(void); #define HAB_RVT_AUTHENTICATE_IMAGE (*(uint32_t *)(HAB_RVT_BASE + 0x10)) #define HAB_RVT_REPORT_EVENT (*(uint32_t *)(HAB_RVT_BASE + 0x20)) #define HAB_RVT_REPORT_STATUS (*(uint32_t *)(HAB_RVT_BASE + 0x24)) +#define HAB_RVT_FAILSAFE (*(uint32_t *)(HAB_RVT_BASE + 0x28)) #define HAB_RVT_REPORT_EVENT_NEW (*(uint32_t *)0x000000B8) #define HAB_RVT_REPORT_STATUS_NEW (*(uint32_t *)0x000000BC)
The hab_rvt_failsafe() callback according to the HABv4 documentation: "This function provides a safe path when image authentication has failed and all possible boot paths have been exhausted. It is intended for use by post-ROM boot stage components, via the ROM Vector Table." Once invoked the part will drop down to its BootROM USB recovery mode. Should it be the case that the part is in secure boot mode - only an appropriately signed binary will be accepted by the ROM and subsequently executed. Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> Cc: Stefano Babic <sbabic@denx.de> Cc: Fabio Estevam <fabio.estevam@nxp.com> Cc: Peng Fan <peng.fan@nxp.com> Cc: Albert Aribaud <albert.u.boot@aribaud.net> Cc: Sven Ebenfeld <sven.ebenfeld@gmail.com> Cc: George McCollister <george.mccollister@gmail.com> Cc: Breno Matheus Lima <brenomatheus@gmail.com> --- arch/arm/include/asm/mach-imx/hab.h | 2 ++ 1 file changed, 2 insertions(+)