Message ID | 1514377566-28512-24-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 90csp2133578qgn; Wed, 27 Dec 2017 04:45:27 -0800 (PST) X-Google-Smtp-Source: ACJfBosCzseiuU2vhPH1fQu8xIysj6CXYygLbOPlwSg/Calzf8bVneD5RB1EY71JHB8gnrP7xmCO X-Received: by 10.80.138.199 with SMTP id k7mr35005745edk.229.1514378727318; Wed, 27 Dec 2017 04:45:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1514378727; cv=none; d=google.com; s=arc-20160816; b=XM267hfd5uBQaLciDmWxPK2yDjmtsIo/jWlSqGoROeyi2fnx18/qTAwZ9n4rn/p5x0 4ACRqc9m8MvcSUG3gyTkiEWUad5vvKpkuSqLDE6hCvr/QF4E49vSFOUPXNHaXyfVCShv EsJd48Vc3ir6CLky0KCb/ckYGfVVbOgy/OCoxXTLqJqZMOAzeSMJZLnI4tuA9QXoLzHV 6vGgWFX2bqaJBhUhIYyb9X18VZOWcZVtOKiGgKoONi1SiWGILrvOKNvOi67HbH88H+rr RwoN6qIsfACr9x7fkFI2/RsO4U0Jovi2vCGzpfExngSW9k5W5Ehh5GrPJTfiqg43xRfG m90A== 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=fplaxKaVmB8RWlntY2KkRbKiVodIIVasQWusHPi9wSY=; b=HOZHu/fXjqw10IpyG5EnuzLHwDQKk0gxrVSwMyeNOGQY1vBW07+iVwT2e0N6LIaf/a tpx9eq3gNn7PcmFxKnKRmNeIYOM/frp0+U2Wfui9O9Z604FZCTxhNJFbizdk48A8tI56 HkYVOcqVZkJxzTj01W1M0jaR7jLprUMJEDj1tO4NmfLyOi2n49Oo9mRC9ietXWispjOS IgjUPMzthDyiosWeIoA01/IhajcNJdIHbkkIOWvGxVRsOlltAbse2+ip65Dkjpy3ypsq 6jGJJM4oXLBQ11eztX8jzXw3K8QltN2fnUh4BSUHdb4ShCgt/qu6NwIOB/G36jsLaaIS iCLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=T8sMbes9; 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 h89si4550620edc.472.2017.12.27.04.45.27; Wed, 27 Dec 2017 04:45:27 -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=T8sMbes9; 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 DB0F6C21E57; Wed, 27 Dec 2017 12:40:18 +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_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 07435C21F2A; Wed, 27 Dec 2017 12:33:21 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 6AEEEC21D5D; Wed, 27 Dec 2017 12:26:47 +0000 (UTC) Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by lists.denx.de (Postfix) with ESMTPS id E733AC21C8F for <u-boot@lists.denx.de>; Wed, 27 Dec 2017 12:26:46 +0000 (UTC) Received: by mail-wm0-f66.google.com with SMTP id r78so39361997wme.5 for <u-boot@lists.denx.de>; Wed, 27 Dec 2017 04:26:46 -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=iW0SWzXaSHTpKelEfU3j73cWIg9x778LQqkP/QMdCWo=; b=T8sMbes9vHqqB1lvvQjgqk5CDTTfgxf+HQY2gWmBuqrdenYzx+ZlggJwL9y25X6ksv kjEsBw99DR4QJrpez/QzO+WsWcsz/17tFPQbj5yvRXw+US5A73krffPYJPqGquVa5LYi VrpDWPDc0i5Ik3PmnzxGz8SBoy42yMF5Nb7Jw= 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=iW0SWzXaSHTpKelEfU3j73cWIg9x778LQqkP/QMdCWo=; b=DkxQYrtt7P+CLQ/gVbCRNO0hCKsAzZ8ns8rIrlHOUCFWq9DDwq/v8t+yZ33RywiLZz Kkw98S4OqSNpLWIOMJkeGubY0WI4jymNOSGgXrTWCwd8FovSWjck0tDcHrXhvZ5V+JgD gp2GXa7JQf3ZRgUEpY8n0l4GtLOL1w++7/g9biTeJpF6znGnZq2FsLT9cF6sB5SSTYJS sXzK5yjSY0gzIejBztzm59F95rpZapprp3qVI3Ad7KHUI0zGbmdASDewgu3la5b5XX3m LZf7nE5KDBDIuL8PN6aiK0L+ajbXwa4tuTh1KXJ99RzTAj1y1lv5j7BwQmyw2zaK+AZS 6M9w== X-Gm-Message-State: AKGB3mIQ+Hzkz8L9ymSRgo3JNrwWdsz0V3eL822+f5Z1XtijahSoTKRm hxss8Q9HzsKhrKgG8XwWX9GAPEn5Bx4= X-Received: by 10.80.153.13 with SMTP id k13mr35530629edb.208.1514377606369; Wed, 27 Dec 2017 04:26:46 -0800 (PST) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id a5sm28388838edm.47.2017.12.27.04.26.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 27 Dec 2017 04:26:45 -0800 (PST) From: Bryan O'Donoghue <bryan.odonoghue@linaro.org> To: u-boot@lists.denx.de Date: Wed, 27 Dec 2017 12:26:06 +0000 Message-Id: <1514377566-28512-24-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1514377566-28512-1-git-send-email-bryan.odonoghue@linaro.org> References: <1514377566-28512-1-git-send-email-bryan.odonoghue@linaro.org> X-Mailman-Approved-At: Wed, 27 Dec 2017 12:32:59 +0000 Cc: Fabio Estevam <fabio.estevam@nxp.com> Subject: [U-Boot] [PATCH 23/23] arm: imx: hab: Add hab_failsafe console command 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/mach-imx/hab.c b/arch/arm/mach-imx/hab.c index 93e11dd..e36aa0d 100644 --- a/arch/arm/mach-imx/hab.c +++ b/arch/arm/mach-imx/hab.c @@ -414,6 +414,22 @@ static int do_authenticate_image(cmd_tbl_t *cmdtp, int flag, int argc, return rcode; } +static int do_hab_failsafe(cmd_tbl_t *cmdtp, int flag, int argc, + char * const argv[]) +{ + hab_rvt_failsafe_t *hab_rvt_failsafe; + + if (argc != 1) { + cmd_usage(cmdtp); + return 1; + } + + hab_rvt_failsafe = hab_rvt_failsafe_p; + hab_rvt_failsafe(); + + return 0; +} + U_BOOT_CMD( hab_status, CONFIG_SYS_MAXARGS, 1, do_hab_status, "display HAB status", @@ -429,6 +445,11 @@ U_BOOT_CMD( "ivt_offset - hex offset of IVT in the image" ); +U_BOOT_CMD( + hab_failsafe, CONFIG_SYS_MAXARGS, 1, do_hab_failsafe, + "run BootROM failsafe routine", + "" + ); #endif /* !defined(CONFIG_SPL_BUILD) */
hab_failsafe when called puts the part into BootROM recovery mode. This will allow u-boot scripts to script the dropping down into recovery mode. => hab_failsafe Shows the i.MX7 appear as "hiddev0,hidraw5: USB HID v1.10 Device [Freescale SemiConductor Inc SP Blank ULT1] " in a Linux dmesg thus allowing download of a new image via the BootROM USB download protocol routine. 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> --- arch/arm/mach-imx/hab.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+)