From patchwork Mon Apr 2 22:42:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132679 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3098758ljb; Mon, 2 Apr 2018 15:44:23 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+13YwqgCEiiVGOjuKPKjCZQHysDI1uYC23E1bHMcVqO+ray4FGgrUDCacPOcUgrS3ENQfe X-Received: by 10.80.232.1 with SMTP id e1mr14129021edn.67.1522709063086; Mon, 02 Apr 2018 15:44:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709063; cv=none; d=google.com; s=arc-20160816; b=gVy3EZ7q81xikwG8wgqhsxFEXfXuu1Fhj+VntNIl8Ds24hNZrzBDJYUB3FX3KbKnEo pRc8apalRn2XqJ0JsqgfIm/O7KmjalInGFxLRuAPs61fkYkxZ8uTP8CAAQJ+Et3AGb0U 3ZOwpH9gp4s8eMXoAT6VWMl06pltJ/PKaZePP4Eay3h/bo8Skz5C4JZdUKvkfy1I0Cq1 lSVdGpIlwHMJf3wc120AhgzjdFTAR1s+SNBgCU9/zwcTJYIwSv6Lcdu1z6UElMRwajUi vjKKWrtsBhFlu5a9GSC+9ksOPP9qQkL8gkiNyNfp57Loip16vg9mkkat/svI4yMbNO51 bX8A== 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=I8gKKcvg0ChOXiulGqPSbZBiHxe+ezmD43IWCZnxFOo=; b=mfpovlBOGRBfUpLA2/0pQeq9WG7WsZlHZJNn9lWi0LKPDDaajvu6UxBnG0NDZnyCys 4+VGA3nF83Xz0uaW+4WeNhBIqcZxSfQLyebLPzPCv3Jpqc3WAAUwy9Pa2kfNf+XrqUni tBmwaE3G/HMSnUjthIZHLAyL/C+euQYZGr+B0MOC5Ufz5CwtJdsE0ZTCaVK8KXOwksnV g/Y803QKt8/WYYSAPXTvar2aClw4y5BmDjKcEyVjpvwL7WUGJjQFrL80b6Ax2xdNev6F JedjnsZ2EUUFbbxQ4lBO+JtwZFweQaXl/KdmQ5c5NTcaVyqtt6ooKJkVwnpmXIrYdIvg 3fDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=B7aYO7p2; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id k31si156795edb.284.2018.04.02.15.44.22; Mon, 02 Apr 2018 15:44:23 -0700 (PDT) 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=B7aYO7p2; 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 A4AD1C21E45; Mon, 2 Apr 2018 22:42:45 +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_H2, 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 345C0C21DFA; Mon, 2 Apr 2018 22:42:22 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 09D08C21DB3; Mon, 2 Apr 2018 22:42:20 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by lists.denx.de (Postfix) with ESMTPS id 791A8C21CB1 for ; Mon, 2 Apr 2018 22:42:20 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id v21so29029969wmc.1 for ; Mon, 02 Apr 2018 15:42:20 -0700 (PDT) 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=CA2atoKRAAeZaRXet7yXYeavk5dzsuMokIvwFjiBCMU=; b=B7aYO7p2qZK8jWalKoc1+N0VmvoX26LGmY9TNf9rlENhX+1pd2iHSrj2Zfvyw6jhT+ 1Hm8axaDPMhXxerpN65flWxIM9Vo7WzxWTpdFNUJOBdM9EEUoAYjNCn+sGWvB4F+/xc0 GHxNzFkedUaqXv38+y/3V6p/ZIM76nO1pQzAQ= 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=CA2atoKRAAeZaRXet7yXYeavk5dzsuMokIvwFjiBCMU=; b=a6q23GdAWy1SSYeC32Q2spG8SR3bf5wGzVghzy4QpG1uIfPoOtD9sUhK3VyFclHUUN SA9kJmgl8fABMNALkfPG4y+jezK35hFTCsbX06Dk2RkXp6dDiEv/G0KzmInB4NKMFy3J Of9fdq/5okONS8o3qnWWjAazg6gnSMiB8Hp416TdftQXEJ74/4lAlPHdhM4ETE4VdKN3 crQTYE8HvdU/dHQiHfcUW/yhZZHNr09xjt7htrJw9zYeV9b2+/J4tFsPaLTSAhpLYSlB Ya/ZYf2KEM+xp45JFAk8b8E2f2y+ssjp8VmvFig3j3m0MEkUcwEi81K+6V5ihyktcTwL vP7A== X-Gm-Message-State: AElRT7H4sVtDC5Ng5b9zOADI9l7ngLAMkv78Bad/fjnd0VeNdCB6s5XY THmK+NMB1yb7PEQG9g+tSjzvbtMOXRM= X-Received: by 10.80.164.182 with SMTP id w51mr10677424edb.152.1522708939893; Mon, 02 Apr 2018 15:42:19 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:19 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:00 +0100 Message-Id: <1522708936-7603-2-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, Utkarsh Gupta , rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 01/17] imximage: Specify default IVT offset in IMX image X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This patch adds BOOTROM_IVT_HDR_OFFSET at 0xC00. The BootROM expects to find the IVT header at a particular offset in an i.MX image. Defining the expected offset of the IVT header in the first-stage BootROM image format is of use of later stage authentication routines where those routines continue to follow the first-stage authentication layout. This patch defines the first stage offset which later patch make use of. Signed-off-by: Bryan O'Donoghue Cc: Utkarsh Gupta Cc: Breno Lima Cc: Fabio Estevam --- include/imximage.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/imximage.h b/include/imximage.h index 553b852..800fd63 100644 --- a/include/imximage.h +++ b/include/imximage.h @@ -14,6 +14,9 @@ #define APP_CODE_BARKER 0xB1 #define DCD_BARKER 0xB17219E9 +/* Specify the offset of the IVT in the IMX header as expected by BootROM */ +#define BOOTROM_IVT_HDR_OFFSET 0xC00 + /* * NOTE: This file must be kept in sync with arch/arm/include/asm/\ * mach-imx/imximage.cfg because tools/imximage.c can not From patchwork Mon Apr 2 22:42:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132680 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3099575ljb; Mon, 2 Apr 2018 15:45:26 -0700 (PDT) X-Google-Smtp-Source: AIpwx49yudW1erWpD20sV9Wr6SyklaFnOz+lJLhd3/4nTGQEGltydYbo5JoNpjDWF9TJOgN/NufR X-Received: by 10.80.173.196 with SMTP id b4mr14510946edd.168.1522709126927; Mon, 02 Apr 2018 15:45:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709126; cv=none; d=google.com; s=arc-20160816; b=vX/ana/s03sDQoRYIENq/BzUdE5nOWYcPvTvuM8opYEmtqA9YUJ8OTsdOylYIJbpCs Wq5bTl78tXu5Uqa5/WDtB82ZEN42Cqgnem78Zy+etrXEtilSWIl8KnP+rImnnWR7XtUe VIlQbqBYUxq9rEC5zEQxyWWlzz6ILJU72DU8It741BkRletyhc07QJthzHNs0QFxhnPY R3Gv4CNGF+FNcCGGTdLODxcX9GsDQq5sGmR1woJ8AEY22bFAAIKLdo5I+qQDrQi1h7ov 7Ogeub4kR/VQ4MmMtFrqYfCg/7SGUMn4Ex4zlJ9T1wNltfIusR7UCGjmKysopavSInlO ixCQ== 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=wP/v909xFYGre5ags3Nmyk6UA/y6X71vDRJQXtvrloE=; b=H6CCZSZXwl++11AK5MhTouoYDr7MYADOqREI1eqvs2L9p4jqDrpKPs7oH2qN5Q4avv ddK5t9YJbXI4qd/KOfIm/jJuXk4/uJp18E3MAl1Aq8SZmVpr9yeW0NOkCWwY26hqZA/j E/R9gLl+8o/D93wMinJLW96Iq+NRMntsmxDiX6Hu7rtnCXJVniMD4vKLj2g3OKw7EQfL 9aOI8iPFjPYuHFoRENiMgJ4QSm1JeUjZ/QMpwK+P4oG2jtraD4vD9o+2OKH2jS+XIH6d yBji8j5PKGTFeroH0ncvucEymQGA/SU/fXB5N6fXbtWDfkrPGTGo7vfUWDh7sCDCm4Uu 3svw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Cp11bVGa; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id q24si1205570edg.181.2018.04.02.15.45.26; Mon, 02 Apr 2018 15:45:26 -0700 (PDT) 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=Cp11bVGa; 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 7110CC21E31; Mon, 2 Apr 2018 22:43:21 +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_H2, 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 25D61C21EE4; Mon, 2 Apr 2018 22:42:36 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 541A6C21EDE; Mon, 2 Apr 2018 22:42:26 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by lists.denx.de (Postfix) with ESMTPS id 8FBCCC21DD7 for ; Mon, 2 Apr 2018 22:42:21 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id w2so8389776wmw.1 for ; Mon, 02 Apr 2018 15:42:21 -0700 (PDT) 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=xp3EILTG9IfrkkHtXk2iwGfCG5Gib4/zSdFgIY1RNXo=; b=Cp11bVGamGf8g63+zc2+eBmFInovQM2jeXmdN8MbXTDQ4yprhC4i7gDVhJ8t0ZG063 2AOcZ81cqtYisrVioVsKUBUD7qxyP5Dv+8yvviYq49gbFr4QCFlfn9GqhmZz9wlTK3Qj EkJahQFK1IjQ5ZmDJySUL05Im+7xxozzPQFFc= 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=xp3EILTG9IfrkkHtXk2iwGfCG5Gib4/zSdFgIY1RNXo=; b=tgRois6kR4h7m5rxe+83cc+hdbVJETSHlUqCj3VaHRoV4f54EO2kTnA6SC/67rUa3Q QNdEJGttAsdNjng+Ba6phKrwRxu8gNtfZol4tiwLxSTE7lbvluPBbSafDC/Qq+a2hpNd mXc2HWCsEaPi32wdx3Gy+v4w0qwXyZLBnYLIeuUsdEcPTrUsF9qpWZn0nAIdAEJHHMBL JRpftleKMQqcHdzxTmX0fIQl4taPnMyBlOx1Q+AlRBhWb42kdW/zsb0tHHLLDtqtNDr6 d3tb+NV6QoSrYq48f+Z2MVlGnJUcu+NR+62+hCXre3Eplf3zCozIF+fcYcADiEzltOjq F+vw== X-Gm-Message-State: AElRT7GRzmaJs/VsmK2OxHhHzOi8eSH1emJMbvBxjdoezVdL9kvt5n1H +l70Olwv/w8vb9lAYrmCSCP9BsN6aoM= X-Received: by 10.80.137.149 with SMTP id g21mr14183330edg.25.1522708940922; Mon, 02 Apr 2018 15:42:20 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.19 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:20 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:01 +0100 Message-Id: <1522708936-7603-3-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 02/17] warp7: hab: Add a CSF location definition X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" In order to correctly produce an image with a IVT/DCD header we need to define a CSF in imximage.cfg. We just use the mx7 default here. All we have to do with this option switched on is "make u-boot.imx" and we then will get - u-boot.imx - u-boot.imx.log The log file is really important because it gives the addresses for the HAB that we will require to sign the u-boot image using the CST. Since the addresses can change this logfile is a critical output. Signed-off-by: Bryan O'Donoghue --- board/warp7/imximage.cfg | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/board/warp7/imximage.cfg b/board/warp7/imximage.cfg index 5b42793..51a5bff 100644 --- a/board/warp7/imximage.cfg +++ b/board/warp7/imximage.cfg @@ -13,6 +13,10 @@ #include IMAGE_VERSION 2 +#ifdef CONFIG_SECURE_BOOT +CSF CONFIG_CSF_SIZE +#endif + BOOT_FROM sd /* From patchwork Mon Apr 2 22:42:02 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132678 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3098610ljb; Mon, 2 Apr 2018 15:44:10 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/Xf+B23whrkj7n4HA0Qo7n/GUaC3XR/lr9G2bGMZ9g0iH1ecfc7bLq/RjN7R+ufbDyGzar X-Received: by 10.80.135.233 with SMTP id 38mr14446584edz.8.1522709050747; Mon, 02 Apr 2018 15:44:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709050; cv=none; d=google.com; s=arc-20160816; b=ed8RkjO3zIQwAUiBKLiZUBbbq3igJ33OMzaqNF38gfrKkcjSMrJqS57HkDlhcL4rtk GXjjbigKOYOTREUE1Kyc7JdIFGVk3zLvJSHAcDUHsRrfkT47X5wn9Bv1xHBCW7cJDELq dhFanLFvtRt7h4W07XLhYuKNE8Z2exyMs3QYqVkX/E0ToyfGGvmbCxOHPV91qYWEnX/G lNObbQbFos4bCHLcUr6AANAYsuGg5OHQ+NSAekSB5Ug4jvLMRn2gfzuemFMQTiWHidir AAAx+dE2v1qBgih7MBagNfi9HKKzGJhaDn6t+uJaRE/k/g8DPiVofzHbo7E5CkcKXOEm ZnHQ== 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=1IYszOfkYydCuAHasd4AqVpWZ/pV7C0zaSvkM1I0aGo=; b=cslXu5xJa1clm0tKtnCLSQOEEXAjqPVm02FzutLCNrpC2qXMKfb8P0HWO8ToFDf22i T+G4bLibB1Io80hDeBZ/MUjBaeO1WH0D4KGo2Rjmz/xt+mNxKgFAgECRAf0XZ3+obRV2 QamNNzHWqXY0HUzuOZZe3fBJOb7EQE+MkbDpGiV87DvCT1S6QRWgyl17MeJtKbFj4KWT eoThuu//kU0Ur6qZfCd8a3OmR16i+yRguFF2SU7pswTI0+mrFlpFIT5ogVazOEeRIdg8 4r055cWeh54iLjCz9RiyiWhon+34ZBOOUy5W2WQSuicD+Ck/nXMCq6Gy+Ld8d8fYChQO EeGg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=SHMCNmmn; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id o13si1050364edh.136.2018.04.02.15.44.10; Mon, 02 Apr 2018 15:44:10 -0700 (PDT) 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=SHMCNmmn; 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 2AFF4C21DB5; Mon, 2 Apr 2018 22:43:03 +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 257C1C21E90; Mon, 2 Apr 2018 22:42:33 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id E5B0AC21E90; Mon, 2 Apr 2018 22:42:27 +0000 (UTC) Received: from mail-wm0-f42.google.com (mail-wm0-f42.google.com [74.125.82.42]) by lists.denx.de (Postfix) with ESMTPS id 9F21BC21E34 for ; Mon, 2 Apr 2018 22:42:22 +0000 (UTC) Received: by mail-wm0-f42.google.com with SMTP id r82so30718317wme.0 for ; Mon, 02 Apr 2018 15:42:22 -0700 (PDT) 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=h6EqZiKNRXZebAavX1JfxB4zDl1X1AgKjbKEYNfKeEM=; b=SHMCNmmnac9GRKN6XDxB8hh8hnyeAvxmzdDIxju6p1rpeyr1jZOJVaOiCZAVsNahA+ iOF5VLhSS+t9zyj2IyHT3XYrl2RUxKbDDfFpP9Gtr7OiE2p2pjUtzMuN8uYkhvdIXr4+ plKpmHmUfYSxRU3iATwphkM69cyGJrLQL8Kms= 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=h6EqZiKNRXZebAavX1JfxB4zDl1X1AgKjbKEYNfKeEM=; b=UhddMUCN2e0LrGQCGyuBxilySkUWg7deTufggYtzkUrSOSrvXKdHTjiJKck+PgVahh J8S2FGyGl1HtKoLqynk2k5maJHDAJD3UsJm4Qvq8kMaeCbjX79xmEMjBQ/szCyNC2wRM aH4O5qYxE8C6TL35piI5nWfyDE7KBFOzziKMtFYEzkPMYybj6TFwTWzGHr4bWQuxmWwL GVriMx2fa9EhxZHJ9MJdWTpbgDza1/GTGTFGGFL5xa115P0rX7fiz//cBbisqSVScXRU XsdmsxQF/2C0xdP/yvRkFTYu0SlCo3OyqEp7yYHmCPHraALiuoKk4i0T9K3liSOCcR94 mC+g== X-Gm-Message-State: ALQs6tArLf6FJtG9MkoU6DgTTKB65IA7MLgOgxQ42ThNRR7RWGRbQasL OGMSrAcls0HFjYVbXOL2yeYmY6H5fc4= X-Received: by 10.80.232.131 with SMTP id f3mr2249719edn.240.1522708942012; Mon, 02 Apr 2018 15:42:22 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:21 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:02 +0100 Message-Id: <1522708936-7603-4-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 03/17] warp7: hab: Set environment variable indicating HAB enable X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This patch adds an environment variable called "hab_enabled" which gets set to a boolean status indicating whether HAB is enabled or not. Subsequent patches can use this environment variable to determine if its necessary to run a given binary through the hab_auth_img console command. Signed-off-by: Bryan O'Donoghue --- board/warp7/warp7.c | 8 ++++++++ include/configs/warp7.h | 3 +++ 2 files changed, 11 insertions(+) diff --git a/board/warp7/warp7.c b/board/warp7/warp7.c index 327f656..0d3d324 100644 --- a/board/warp7/warp7.c +++ b/board/warp7/warp7.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include #include @@ -203,6 +204,13 @@ int board_late_init(void) */ clrsetbits_le16(&wdog->wcr, 0, 0x10); +#ifdef CONFIG_SECURE_BOOT + /* Determine HAB state */ + env_set_ulong(HAB_ENABLED_ENVNAME, imx_hab_is_enabled()); +#else + env_set_ulong(HAB_ENABLED_ENVNAME, 0); +#endif + #ifdef CONFIG_SERIAL_TAG /* Set serial# standard environment variable based on OTP settings */ get_board_serial(&serialnr); diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 98fedb8..10db716 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -139,4 +139,7 @@ #define CONFIG_USBNET_DEV_ADDR "de:ad:be:af:00:01" +/* Environment variable name to represent HAB enable state */ +#define HAB_ENABLED_ENVNAME "hab_enabled" + #endif From patchwork Mon Apr 2 22:42:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132686 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3102176ljb; Mon, 2 Apr 2018 15:48:52 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/jclFMpMA/yXQfkp2qX02jrv1fnCukq6xti0LWW8Pu1B82aMhvm5AXJwVp3miGCuRmRdbA X-Received: by 10.80.165.175 with SMTP id a44mr14304968edc.308.1522709332190; Mon, 02 Apr 2018 15:48:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709332; cv=none; d=google.com; s=arc-20160816; b=WBsrKuN1eEWEmt9z+3uZoQSwvDB9ZFah5yidoA3twhrMjbWtfDnA2PkEAhwTDa8FI8 Q4aOUgydgvItMQoPo67/YfKpO7bKxSnxoxpJDWop3NljOXmVL++S8Zl0fVVJ3yEZjYQO XzLV4BWmvkwzdiiXaHP6qL1LAhuPsN0/IrJGc3IFsKJKToUuqVW2jQN5DnZ1LPc4fjyv 7pVqG1xNyWvhGD/abHepTxHqhoquzUHgny8hOyHgJnFRt+FV9TFmXaZ0mTVZ7CvEArs/ j5FhWASG6ZMbRy9l8vNVFIPBtZzmtfPQJSzL34PqHSahl+kqcCnRGLhk3QsDR4WU02Cf m58A== 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=PVFKhoD/hJ7FG/sTjXPzVm5ZmJa/9+c+6kRkHhcRHRQ=; b=a9stO5SMuBods+lTw/jtGCGpxelIVZFlVozbaUlGmbtfIWQf+aHw9cxb/cZT1CQ+fM BqIno0wtQKtHQ+fPpovpj29DlHHr+cWFA1n5pyxDW4ZclkmP9QXgxBHGZoxYqKcLd9XT FI4BxaUGC5MHGmhHbC3203i2X0oCT/6DydYAR6rosBxirALZOxCjaYcVZ7Kkx2a16c/g ufErLEvT1Mm1JOF8f71na2YGs/gY3veyrg8gxiqEPputI25zyGSogCIrJPkmBAPO2TRU 7oFPP4inJ9dh00GLpBMbt+Y+05XH7tFttqgxVbUTORtC8qktWcMb4xKaqZlxsDVALEPV q1gQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Q02wrl+s; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id o60si365314edb.128.2018.04.02.15.48.51; Mon, 02 Apr 2018 15:48:52 -0700 (PDT) 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=Q02wrl+s; 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 C57BDC21E85; Mon, 2 Apr 2018 22:43:53 +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_H2, 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 23980C21E08; Mon, 2 Apr 2018 22:42:43 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 6DA67C21E56; Mon, 2 Apr 2018 22:42:29 +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 C996FC21E30 for ; Mon, 2 Apr 2018 22:42:23 +0000 (UTC) Received: by mail-wm0-f67.google.com with SMTP id x4so30420026wmh.5 for ; Mon, 02 Apr 2018 15:42:23 -0700 (PDT) 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=C0sny3vVK9FUbANb2k3ag+BlDBiGPUikaYJuZ1wtGC8=; b=Q02wrl+sjEalJoGW06m7MN+256qvydmkwR0NE4JxYTYHI3lXlC7YV6uqh7FLnL6cvj aL50cEDEGZahwfqldV9matNvLy7NTVjySJTnhNGZAUoxwBIaPfJ7GtNIyM6lDcsKA9pT Le9pIKdE8+kBm8aYY+Zs2SzClzfvSW44VDVJQ= 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=C0sny3vVK9FUbANb2k3ag+BlDBiGPUikaYJuZ1wtGC8=; b=kEVvQ3lAjoLtwUDD8iG6dKXkdzi8WjiIzzy2FOvA23IGwwQKsoxjOxbIUONkskMKvp lTmSCTclaeT/7pHizuKTQc5s3iGlQQFBGuLvprHdD/mCiqtBy/wFSCl+edTIjurQfVwV 7jZbG+zm/JdXBKKIKCvlkP9yYyQ5KRfSYRdtkVKpoWDC+dzX/pqxkquvgOFIFfZ7CAAu jMA5c8txXwpwlqBmKyczy1zHQ/IXuFQXSnOWhvoDPhyyJRD/0K7EgYG5pHN+6sWQ617N PJBOFZtamQmePd72thDr8gWUdj+ZRnDMe4Xv8BSDmwwM2UeqZ1MHATLY9gnaLeJvEsbu Nwxw== X-Gm-Message-State: AElRT7EBgTTxtRQO3DCQhnjMqbEbu5+/3wQZ++b0+2SYoQ0eHRX/uTmb lBlplKiGO+fCSkaU3jAVViEfHxdCjuc= X-Received: by 10.80.189.130 with SMTP id y2mr13847123edh.138.1522708943089; Mon, 02 Apr 2018 15:42:23 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:22 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:03 +0100 Message-Id: <1522708936-7603-5-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 04/17] warp7: defconfig: Enable OPTEE for WaRP7 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Requires setting CONFIG_OPTEE=y and setting an OPTEE TrustZone DRAM base in include/configs/warp7.h. Signed-off-by: Bryan O'Donoghue --- configs/warp7_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig index d720bac..3dbcd69 100644 --- a/configs/warp7_defconfig +++ b/configs/warp7_defconfig @@ -44,3 +44,4 @@ CONFIG_USB_ETHER=y CONFIG_USB_ETH_CDC=y CONFIG_USBNET_HOST_ADDR="de:ad:be:af:00:00" CONFIG_OF_LIBFDT=y +CONFIG_OPTEE=y From patchwork Mon Apr 2 22:42:04 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132694 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3105684ljb; Mon, 2 Apr 2018 15:53:37 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/RKfX6M0Zyi4M07FO1GBfP3mWKpxIoIS1FrHbXYNuP3dQKSb4qILKAY2zRPpm2yBlcSnPA X-Received: by 10.80.181.58 with SMTP id y55mr14224536edd.256.1522709617453; Mon, 02 Apr 2018 15:53:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709617; cv=none; d=google.com; s=arc-20160816; b=SCQgsU/OZWXkeSUkKNkzCNd441jmXPRl7vdha41dsfM+wlLC6e0hL7TziuDexFK8To 1EbJWxnSmH6VEB+hNL6Asgp0ZuayaQFHJCo+CpNLrY/rQZ1b+kq/mab2gn5v6HKAN6bI yIs77sJc9SJSJ9u9TVNnpn1eQeKPYYYXYKAyz+6+kuhUlebgJiUXEmt2MfESxroKs1q+ Tm0ckHQCZCTuQ+X3lgK9VO+/tnzBIOt2PS4ZL4SBSgIK1T2RS0MDgKXZwUxFqbzigCw3 BMyHtkqOr6UV25AOMskjizKsZNUg+3tHC05ktAPGPbIdyNeAiX78PDT8XCJ2CCJDmO3q gmDg== 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=rBkpxiGD8KPp6kxNYRZxaaUl6cGgyfdl5DfMU+fQSYM=; b=irb9DlMK5uFoG+PieiZq59fO1aUSDjT8Go1zJ5vvvdfS1jdlfIY9yjjEpEPoJb+Qee hYQAqUMRgwprDhlg4UB1bJhOimipXVMbhpDdBggTJ7wKycdhGcN6++6aTq2uG166UAj5 TaEqaxqeVimpoYXAm1sUkt9tAk/xZ8/PSVDpdDnGyI1L8+/eOuTu8LVVokzWmbhXkqA+ lzUpnjxeiJRAe4KiK2+CHfrjzo/xhQ6gjf+kHNnU2ujIZrgxldA51pX3RBaf5uJfvso7 HNKlPtKijH/RKMT6n91M1WMejtz87SVJxjXLcgmmeeXF0geHvsTVyzFl56p56MO4b9kL o8Vg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=eL49gY2z; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id l32si516827ede.111.2018.04.02.15.53.37; Mon, 02 Apr 2018 15:53:37 -0700 (PDT) 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=eL49gY2z; 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 0AFABC21EE4; Mon, 2 Apr 2018 22:45:32 +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_H2, 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 811B8C21E12; Mon, 2 Apr 2018 22:43:04 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id A0A34C21F05; Mon, 2 Apr 2018 22:42:29 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by lists.denx.de (Postfix) with ESMTPS id DC224C21EB1 for ; Mon, 2 Apr 2018 22:42:24 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id r131so30460079wmb.2 for ; Mon, 02 Apr 2018 15:42:24 -0700 (PDT) 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=ZyVbqfzifusuZrywaBiF1R7LagXEDVoA5r4yyEJ3MCo=; b=eL49gY2zBZ+vZbB9IQ9q1UHZEfkxYpvr90c6nJE07CE4Y8kUVCL4vkX8ahCg6sX0W7 SVz3RaPFuJIgOZLGy/35HPXBRur/9Ui7qcm1Jq+LvbQIobHNXiVtKEMPRsPRlg0r94ky k+oVHK9ZsAZiVIP/15t9ot9EFYfniM88c3Oo8= 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=ZyVbqfzifusuZrywaBiF1R7LagXEDVoA5r4yyEJ3MCo=; b=sq+9J234HFXHKDbygZdZnqfwsjoahKnIUhItcY2qjG9q3aXg+2jpfakz1G6yOfFVUy G7i9KRGV3oPyPMocTteK+Ja92JsQPszzdDpJDyb43oOSvr/xJ6giArNtRxgNUWxeRnoe KB82T+fDrXOGUUjLHXph0jZLDdNhveLGB/MwhnD22p7oxP1vBVnvBFBHLtUxq3PNlAhm NhsWGPCKiIQo0yR2szQPk0vCtzYkJG3bZmxN3mpde1o7W+Iqv8RrW0J5xOfCOigb+6se 3UQyHBNaTAC5OBx5Z0p5QE5AimAEhh11VExGVUkcemtiIMhBwKYN9KrZK8EBnL7Bm94i LVGQ== X-Gm-Message-State: AElRT7EU7/IJGTTISQ4AJWjQ3ARYeS4kKumsIhBBOXybErvAXu9Njo6V xB1rQNvMlJMgInKv4yG8JSSh/y7PV8A= X-Received: by 10.80.136.107 with SMTP id c40mr14140728edc.231.1522708944143; Mon, 02 Apr 2018 15:42:24 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:23 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:04 +0100 Message-Id: <1522708936-7603-6-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 05/17] warp7: Allocate specific region of memory to OPTEE X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Subtracts CONFIG_OPTEE_TZDRAM_SIZE from the available DRAM size. On WaRP7 we simply define the OPTEE region as from the maximum DRAM address minus CONFIG_OPTEE_TZDRAM_SIZE bytes. Note the OPTEE boot process will itself subtract the DRAM region it lives in from the memory map passed to Linux. Signed-off-by: Bryan O'Donoghue --- board/warp7/warp7.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/board/warp7/warp7.c b/board/warp7/warp7.c index 0d3d324..56f0cdd 100644 --- a/board/warp7/warp7.c +++ b/board/warp7/warp7.c @@ -58,6 +58,11 @@ int dram_init(void) { gd->ram_size = PHYS_SDRAM_SIZE; + /* Subtract the defined OPTEE runtime firmware length */ +#ifdef CONFIG_OPTEE_TZDRAM_SIZE + gd->ram_size -= CONFIG_OPTEE_TZDRAM_SIZE; +#endif + return 0; } From patchwork Mon Apr 2 22:42:05 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132682 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3101632ljb; Mon, 2 Apr 2018 15:48:13 -0700 (PDT) X-Google-Smtp-Source: AIpwx48uoi2MiB2YSTO53yA3Y5/S2h7Ui4q7xa76D7rFwVUKZPBxEUGvkwEqGXos1GtD+AcCguPM X-Received: by 10.80.231.5 with SMTP id a5mr14179279edn.109.1522709293471; Mon, 02 Apr 2018 15:48:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709293; cv=none; d=google.com; s=arc-20160816; b=D6mDGiPjg2l59zoyIF4MxiRCN8uhGNZ+zJOl8P2YWvVi9xmNoMnok9kdwywyWRBjuX B0Zg8GMAd186122zQv9qOa2/NI/YGDw8YC4ihbU39uzAhykDW2c99v6f/px9g2bevVgs 1SOjh66NAXL6jw8luNTa7Glep+O/fxhwG0b8wZIbSeACqWiMw+/T2wrmLmI39k+eamqN F88mWPLMyUOHdl1vo9cB+/QsDRMp1K62zKuZ21JeeU7uPibKrUM++SJNXL2sfdtY0us3 sK2U0Qul7o6hZ3vYzXL18qDjt6NWJjokMOjNwYlM817/5dZZ+5j9XjgnFIcRdxG8HXBU /7yA== 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=RRfmoo63du375tRpAsTIK6bsdpqn75A04iMTbsICoh8=; b=BZSKAYeYyDjUdxuf4tL7QPLEXeabTwEIopMghpq0+ZgzUOAJyJ6v7xqsLn7LV3VEq1 iZWtieTdkhzAurE9JX9b570ixeg/kULxE1MyYWWEOup9cEVNa845HyKtYiU5gtHctv0q 1WWC0OYINiHwnf572fzi1F1hpRc/p5PIVr2laYyYfPI3Wso5t/BBBBsPuSfKU/9JQ79k ZqXmdeFRYMXZam98LyEoOkYabtv0/YD08nKo+UWv16p5fjk0nxpLySQpYRX3KNM7NUoo fNpVLKiYhPKm9usrSmaM60uV6ZfXnvfZa3v3eF0vx08K0l95XGbzVRJ1xexrmzbISrem 1B/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=X5rayfKC; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id 10si1297727edu.413.2018.04.02.15.48.13; Mon, 02 Apr 2018 15:48:13 -0700 (PDT) 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=X5rayfKC; 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 106C8C21CB1; Mon, 2 Apr 2018 22:45:00 +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_H2, 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 C135CC21F0C; Mon, 2 Apr 2018 22:42:54 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 99E1AC21EDE; Mon, 2 Apr 2018 22:42:30 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.denx.de (Postfix) with ESMTPS id 2878DC21E07 for ; Mon, 2 Apr 2018 22:42:26 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id x82so30477278wmg.1 for ; Mon, 02 Apr 2018 15:42:26 -0700 (PDT) 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=QYUQjDXk16GnMGixelcOEuFlaSZ/V4B2B/jP3GH8tgI=; b=X5rayfKC3u6pZuM543zgPfpPbaLiUrYpQMQFqAxJgWnhLOt7KOKiEO4Sg/RZp8LUQ3 8T80oHo/Aph+XvXgUBWFc488F0/OnbkQstte4NTNrnssFrC6PB/JD47z3VAEP6/SCjLR OAk9yoFDh+Qrmn6/xunsNMmtUwMVDegXocm90= 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=QYUQjDXk16GnMGixelcOEuFlaSZ/V4B2B/jP3GH8tgI=; b=cpLVDkYGU94jl5pmkTeKmc/pF6bFQAwO8+yOzfyzgGjoKuE9KlXOOpzdIjm0Sk5Zsw YIcjMrW+ynPi3Q+5HWV/cJsSBlbIK75PC4fT/wDDX5fEme7u71Z+TXfxr0/kXd9znlvf 34P8ZhvlFYn94eOxDlsSTnFdhk+IA/Z5cH3mLz7S75ct9raJiDLLivI9KLUZz2AiJ4Bz lM8IExdoH6P0mZghSEmKjAalPuZI1ik7zmG3oYPrbXWVDqPL8NbELRKO7hARzjew+ffg osRJqyS/B6xXlvCyPZmADZofoPOVypL/xc1QK0JX1xyZai7DIk9geZmlkEC6k6qlNnIZ VQuA== X-Gm-Message-State: AElRT7FM8v7BEjGqVhAqa0yGW4p5pXULYId+w2Wu+NKkfPFj75pJjMP7 GluiecWSjouB/whNNpYgs/FWtZMSCY4= X-Received: by 10.80.144.119 with SMTP id z52mr14051641edz.79.1522708945150; Mon, 02 Apr 2018 15:42:25 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:24 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:05 +0100 Message-Id: <1522708936-7603-7-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 06/17] warp7: Print out the OPTEE DRAM region X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Right now a region of 0x300000 bytes is allocated at the end of DRAM for the purposes of loading an OPTEE firmware inside of it. This patch adds the printout of the relevant address ranges. Signed-off-by: Bryan O'Donoghue --- board/warp7/warp7.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/board/warp7/warp7.c b/board/warp7/warp7.c index 56f0cdd..da52b18 100644 --- a/board/warp7/warp7.c +++ b/board/warp7/warp7.c @@ -181,7 +181,17 @@ int checkboard(void) else mode = "non-secure"; +#ifdef CONFIG_OPTEE_TZDRAM_SIZE + unsigned long optee_start, optee_end; + + optee_end = PHYS_SDRAM + PHYS_SDRAM_SIZE; + optee_start = optee_end - CONFIG_OPTEE_TZDRAM_SIZE; + + printf("Board: WARP7 in %s mode OPTEE DRAM 0x%08lx-0x%08lx\n", + mode, optee_start, optee_end); +#else printf("Board: WARP7 in %s mode\n", mode); +#endif return 0; } From patchwork Mon Apr 2 22:42:06 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132684 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3101895ljb; Mon, 2 Apr 2018 15:48:33 -0700 (PDT) X-Google-Smtp-Source: AIpwx4++j9UOisxySpLABgr5RzQPkws8/3EU1ebVKjjEJCphqFyTL/pKX8Xc0YFD0v/4Rr4MnGCQ X-Received: by 10.80.183.65 with SMTP id g59mr14098841ede.129.1522709313696; Mon, 02 Apr 2018 15:48:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709313; cv=none; d=google.com; s=arc-20160816; b=HAAcofwyHLX3O03o6r5iutB2+fBys4cDo3taR5zjJGSnC/4iPjVlrjymtTMKoTLaMH VeK7kFWTVoSeBPdV+3NcD1BmbujAHcCIDmQOmN1OPy0m7vJEcdGdKzbpfbgj6e0zSeW8 1NS3Q9yi8rjA2Ge7Axv8JEGCgPSQ6GCgc4+IPC/hi2m4tuQvDMiG7YSLBbvITRhSybhN fwirQeZmM0YeMKnacqH/eNakptG7rhjgU1A9vuzxG06WroMkVIv9utRDp6VQIaHPOdGz QQtY7/9dTqGV/H7O1QCN8Zcc3SZ/KWEhL9aQ6WYVET3ZY9u62HpH4Ntfo1uKck/2H/Bk 35EQ== 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=Z6W0JcJfnDWMz1Y6D8CblhvPp9xb8XoCYIBU+ObSeHA=; b=0ttD+v2zs2XBBs84+vfGCm+wybpy48mhkFHDYja8+5O+768fmIFGOErqOUww3xSan0 9k2rdaNZ2xLwy/cahcAlkMcr7kYCCuXEhVhxieCTD/PCPTRJ+Kj4k0Xvgp1Lcl2QcrEp LWH2vzW5REoLKrLvfvnIBWULwtQ2YWvDWJb2gcU+vv7N1XOUET3o7mVy4sl1Cez0BGPr xvXIy12Hia6EftQEknoiNoBUTKYxzgOqNkHsrJ5Y0UI1bL/mY+WaPflUAzZa0RMHqH8Q VqXKSYYKci9AihEcn5G138LSYCM5MrJT/Xh5Ibe19XN/Ge2Nh14llyx933fIYt3Ymdv/ TfIw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=kox7l3BF; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id g21si222913edj.211.2018.04.02.15.48.33; Mon, 02 Apr 2018 15:48:33 -0700 (PDT) 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=kox7l3BF; 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 51F36C21ED5; Mon, 2 Apr 2018 22:44:44 +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_H2, 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 6A6D5C21E53; Mon, 2 Apr 2018 22:42:51 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 992A4C21E30; Mon, 2 Apr 2018 22:42:31 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.denx.de (Postfix) with ESMTPS id 27221C21E90 for ; Mon, 2 Apr 2018 22:42:27 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id h76so29005156wme.4 for ; Mon, 02 Apr 2018 15:42:27 -0700 (PDT) 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=lmGswfnO4JBLqVcYz/fMo3k/jRcv8rEN3ZTfeotYkRY=; b=kox7l3BFRESlcSe+pb0iA3oIfhov+a28qs4rg4mqSk3HK34HaUxTjp/GtRdxEkH/gJ G5Byb5G41eTFqmqyX5QMHCZmtHg3hvugtTbS9YH63fc02mlstNmU3LuK0ECMHZs0MvJd 5f1+fM3Xwx4m4G4ceUdlgTN3XShHSFlmLFeOM= 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=lmGswfnO4JBLqVcYz/fMo3k/jRcv8rEN3ZTfeotYkRY=; b=fH/c7HrS5aLpBgk6pn4mlobFqik6Ut2gYdBdsTjM1gJ3pQ3zQ7jRGMxeQYyBeBAI3a 6OcRYYC+gKBz89mxHzUzVa8WFljFmRRgP6G7/EW/TjYSzYpHjipTYsF8d0lSTowmh7+b KOfZOb+za+2kJKQ+SXoJjyd1yKHJe9IkOioCy2Dm4IqLtcG9zbFtkHNHTFa9qU0/Nket BnY+GjKK5RLmkkJh82R0xtWXBsisNQIN1rQ4NmGOJ3mUES2tY5CA6r5n3DTwTalw693l 1jl5XRYjcsjqULESyNtFoLoWGamToAK4khkbdpPY+tT1LCqxaXnyaZXAej7SvuaKfzoX iq3A== X-Gm-Message-State: ALQs6tDZF7wCh9qiqDJwUSi0vMcuyxpRmf4V4CPiPKZnZgNrsggl2pqx 8U81478gX7h5p7KJs4nG1CfWvxtejas= X-Received: by 10.80.242.140 with SMTP id f12mr1168446edm.130.1522708946166; Mon, 02 Apr 2018 15:42:26 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:25 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:06 +0100 Message-Id: <1522708936-7603-8-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 07/17] warp7: Specify CONFIG_OPTEE_LOAD_ADDR X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" In order to sign images with the IMX code-signing-tool (CST) we need to know the load address of a given image. The best way to derive this load address is to make it into a define - so that u-boot.cfg contains the address - which we can then parse when generating the IMX CST headers. This patch makes the OPTEE_LOAD_ADDR available via u-boot.cfg for further parsing by external tools. Signed-off-by: Bryan O'Donoghue Reviewed-by: Ryan Harkin --- configs/warp7_defconfig | 1 + include/configs/warp7.h | 1 + 2 files changed, 2 insertions(+) diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig index 3dbcd69..c647cd0 100644 --- a/configs/warp7_defconfig +++ b/configs/warp7_defconfig @@ -45,3 +45,4 @@ CONFIG_USB_ETH_CDC=y CONFIG_USBNET_HOST_ADDR="de:ad:be:af:00:00" CONFIG_OF_LIBFDT=y CONFIG_OPTEE=y +CONFIG_OPTEE_LOAD_ADDR=0x84000000 diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 10db716..e12b90b 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -40,6 +40,7 @@ "initrd_high=0xffffffff\0" \ "fdt_file=imx7s-warp.dtb\0" \ "fdt_addr=0x83000000\0" \ + "optee_addr=" __stringify(CONFIG_OPTEE_LOAD_ADDR)"\0" \ "boot_fdt=try\0" \ "ip_dyn=yes\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ From patchwork Mon Apr 2 22:42:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132685 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3101999ljb; Mon, 2 Apr 2018 15:48:40 -0700 (PDT) X-Google-Smtp-Source: AIpwx48LWHi2ZleowljNoS77XxMUt00iZpuWcr3VDdO0539+JJV4OSiIW3DS+zOytRMaIH24FNyp X-Received: by 10.80.153.9 with SMTP id k9mr3563116edb.303.1522709320933; Mon, 02 Apr 2018 15:48:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709320; cv=none; d=google.com; s=arc-20160816; b=Sj/3gdxwvJ0II0UN+7PTHKqQJwomw4I4LBSrraiXy1jZNJ8Ov2bXr7XVe1jGVil99r 8xAaCYB2hU1pxhkNTMpfPXqyJ4nIGC6nhC+bA6yXHGgZxf3qiqHXC1KRoKSHLAzlPJcL ILFSq3pDtAgmlmw+kJVAd11iFQqQZ5BuyNU/Hs8No3iZiSDsJPSGIfU0i1aP4+hU1Bls b5DR7vJuBVpaZchaGy0ze3r7FvuOZsHwcXjGtt4ZjYdwdGCyzOclNmkFoxy8AmRKJlvl vwKeDnEKxNOhlVWPKDvuGZ/K1uOE2oi3F6S6zbf+y/73Qva+Lbd905nXEBPFER790Zw5 VK0g== 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=5cRg8ez1HYgE1u0a/GP8yHNEzI5roO8S7SqpyC9weLE=; b=lcMjUB4RHV77FU4Xg76orF4cbG7XzUaB4f6SSk9tat7if0To1JYMz6BbnI74/vRU2A oFuML4+f/Tm6GhCAfOJRGqqrVg4ywpdFj1Sy4/DTjRc/DslOEDFu7N2XzYw2uktNrKzz d+qsDf5qmNg8TdhnfTAUnGWWkAx900E94BB/m7+xfEy8XbdE+CzgekmRGUd6kXDM/mT3 xp+CzJcQM1XR/aG7koGz+HuJD0eWI17h4+Ag++Pqpfwhr7duMcNr7P22mJsey7ZM1p5u GcdtfSlXEeyLbkjloFUB8TBRNfJbfRTvaQFdTWh4TOANRdTJhCnjV2u0tCipnUar5NDI NiYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=YSD9BNtx; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id 35si1087046edp.549.2018.04.02.15.48.40; Mon, 02 Apr 2018 15:48:40 -0700 (PDT) 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=YSD9BNtx; 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 7D31CC21DD4; Mon, 2 Apr 2018 22:45:48 +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_H2, 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 93E51C21F29; Mon, 2 Apr 2018 22:43:05 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id C5BD4C21DD7; Mon, 2 Apr 2018 22:42:32 +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 4C957C21E53 for ; Mon, 2 Apr 2018 22:42:28 +0000 (UTC) Received: by mail-wm0-f66.google.com with SMTP id b127so28139719wmf.5 for ; Mon, 02 Apr 2018 15:42:28 -0700 (PDT) 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=VSGD7e4ky5DKmlDTuYNRjPCMufmihoax4/YMwg9zaPM=; b=YSD9BNtx/ffbWEropazkckUA0AWtqXCMmyGAhW6UO+CnJAYbqGH9dwiHfRTHfEipA+ 2s+/LxlodaG3Bf2qpDPecARCP+elyDwaAFJEy8nxxD8n0aQo5dnX13A6ydVSPCkUTBfJ BmjR5n1PpL766yKne+d7Ajny9axG9PyxyTW5M= 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=VSGD7e4ky5DKmlDTuYNRjPCMufmihoax4/YMwg9zaPM=; b=Gu6qbyORGHoLuUyn1NibTSa1fdHqL7cigf4CJXddJmMIB0iWARqCH+b3PGH1CQSKhg DpwU8Rk7Kj2+0bKeWN+Iy6hpXUkV+n06DQC+ifhxcL8vJoZqwAgNAkKxgaGejqVGp75c mHnl7lPY4zny1AswWhR0Uteg+9gVH8VrMGUDyyFyZqOHb+6AwnxKScG6wF7Gc+MNgp0L sm4RPqddkTU3Gc/lCZFHBVT5Fqon4EaBBcKGDL1TJtqRBK4kplCmwJ/0FXCrjwU3I5W1 ObaTWUlNaDEjQfKzhikHXpD3Y4SwKp301D+1cf9B7LWiuyiapoWSmvGafkrJ5LwoOxse SXOQ== X-Gm-Message-State: AElRT7FoSM5mPXni04bJpg09RABB6rBmJ5Fvi5J2ARDzmgbPWB+1npqP kwhgHoFHTon3ajSANQgYCn/eGFMSx0I= X-Received: by 10.80.190.67 with SMTP id b3mr3014341edi.84.1522708947164; Mon, 02 Apr 2018 15:42:27 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:26 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:07 +0100 Message-Id: <1522708936-7603-9-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 08/17] warp7: defconfig: Enable CONFIG_SECURE_BOOT X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Various function associated with booting the WaRP7 in High Assurance Boot (HAB) mode are enabled by switching on CONFIG_SECURE_BOOT. This patch enables CONFIG_SECURE_BOOT for the WaRP7 defconfig. Signed-off-by: Bryan O'Donoghue --- configs/warp7_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig index c647cd0..efb6f51 100644 --- a/configs/warp7_defconfig +++ b/configs/warp7_defconfig @@ -1,5 +1,6 @@ CONFIG_ARM=y CONFIG_ARCH_MX7=y +CONFIG_SECURE_BOOT=y CONFIG_SYS_TEXT_BASE=0x87800000 CONFIG_TARGET_WARP7=y CONFIG_ARMV7_BOOT_SEC_DEFAULT=y From patchwork Mon Apr 2 22:42:08 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132683 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3101663ljb; Mon, 2 Apr 2018 15:48:16 -0700 (PDT) X-Google-Smtp-Source: AIpwx49xE3rIKJglvJUrTlF7CLGcz3mMDrB1J88IwlDzPhn3oPEOOEmDHi5EI0Gb52jjt8q5eEmv X-Received: by 10.80.234.139 with SMTP id d11mr13975648edo.7.1522709296164; Mon, 02 Apr 2018 15:48:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709296; cv=none; d=google.com; s=arc-20160816; b=Vv9eCITgJXt2v3DeYvgRKodDCPBwZqOvG8F+Spzs8nj2ErbGASSnJAaJsdYZ59lfX0 AECPjFBF6NKlcz8swGpNdar1fT/B4BfITJxtFizfh3PWXXQGpVIVle+HMx8KTAbfsYTN QA1lo2Vy4H2AvJyxEv8jBVpQSP3paTRXE4UDnRx1dvbQxHrh3keCA/XlCLZBcMwplY9r ZWZtdpk66WLm75Z1kczYyXqP/YQxB5TlLtaPjhDZsz1RlJUBNjZ3dyuJGHSKIGj/95/g AF4ZppIXTsiqygrnKL5pruNSgbCe4MUhjM7yrFH0vWePMCC/3ipIqVXty2Vv25RVsLkz Q9tQ== 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=V783Gk5+VApNDVBpkvVMGMrDRqkBELBbYfYcEoPjLCE=; b=ZumJyOVM/JE8CHwa13kKQDkqYj4398RrjOSjb2b5VBgS+OpF3VHvyr7Tf+3ET1sdGB Ds+yffOZhS3BFloPw2sD8BikdTuBOi4hQylcBQE8GKG5oJIiLrQFiF4pU/gq0pFhrNyD 01CI9fT4fmWR03bdFhZK/DZiZ/8KJWl+UbH0F8xJOfvanhDZBUkkzisfe5Zfe05hAfYg I/1v78nzS1CSeAOlfzsc64Q+5HqRS22NS/zfb8L9HClwaJYxCiiOD7d3Hc8Ck6hVDKia jIp0mao1wFln2L3ffcCcp7P1rT91cZ7g5k3YDtH+HD2HxgYcb4IMJD5GGwjdrvNBHP/+ 4NxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Xx3UN2uf; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id h23si1197567eda.422.2018.04.02.15.48.15; Mon, 02 Apr 2018 15:48:16 -0700 (PDT) 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=Xx3UN2uf; 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 BC870C21E2C; Mon, 2 Apr 2018 22:46:05 +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_H2, 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 BCE25C21F32; Mon, 2 Apr 2018 22:43:06 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 58920C21EC9; Mon, 2 Apr 2018 22:42:33 +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 C18B5C21E56 for ; Mon, 2 Apr 2018 22:42:28 +0000 (UTC) Received: by mail-wm0-f67.google.com with SMTP id h76so29005279wme.4 for ; Mon, 02 Apr 2018 15:42:28 -0700 (PDT) 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=+nwn5lRaFWst3UwOtqR/ryFHXvSyVue8HZITpt8D1UE=; b=Xx3UN2uf/YvmtUGqcFwkHJF/RETvEi20xeg5K23DCzxg74TqsRjP6acOGLgv4i5Mkx YH0AM984pxEXtXaR5t611ym/1kMBL++22elfY8JOvJdWQvHupAhFmKrQYt+RR7voSG4X dDh0eZw6DcqetDr45NYmTOBKInQy5AMqjU5fc= 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=+nwn5lRaFWst3UwOtqR/ryFHXvSyVue8HZITpt8D1UE=; b=e2y0/IItdlDpawNGJUDl9I6cwOAqctM4csxkaFlJqj1TjVt93candTJD1vkLLcSo2t GzPCDhqNbRKAYmdtHHgNYeCysdac1l1XqSv59MlRrG6d+kqgHW+98YS4533IfEV/qV9C 55vQb+hPfKfuwdjh9FiI5YIwL1Uj664wZ9uGpmQ9hYnJ+OJ69PE8kqFJTCOkXXG/8jIB wxBRtOM4Hjf+UXk/N9di2TFNXt2ecujSGo77oVIq2tfPlJl5stBW4xtvTCxUb3KEWLZK cBkdvff0DbiBZJkhUcEeseB/Wxgr6caAOnTDEnAH+qJwkrby6Q5YT36qkdkiqorEqRw2 /hBg== X-Gm-Message-State: AElRT7HijhhdoN/NPx86XPN1Ax9quxXDh8feqis0YwZWlKrqgmO98mp9 UBXwdsujOvqxb7MADv2vCxKkycXnG8Y= X-Received: by 10.80.181.117 with SMTP id z50mr13938003edd.223.1522708948227; Mon, 02 Apr 2018 15:42:28 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:27 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:08 +0100 Message-Id: <1522708936-7603-10-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 09/17] warp7: defconfig: Enable CONFIG_BOOTM_TEE X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This patch enables CONFIG_BOOTM_TEE. Once enabled its possible to chain-load Linux through OPTEE. Loading kernel to 0x80800000 => run loadimage Load FDT to 0x83000000 => run loadfdt Load OPTEE to 0x84000000 => fatload mmc 0:5 0x84000000 /lib/firmware/uTee.optee Then chain-load to the kernel via OPTEE => bootm 0x84000000 - 0x83000000 Image Name: Image Type: ARM Trusted Execution Environment Kernel Image (uncompressed) Data Size: 249844 Bytes = 244 KiB Load Address: 9dffffe4 Entry Point: 9e000000 Verifying Checksum ... OK Loading Kernel Image ... OK Signed-off-by: Bryan O'Donoghue --- configs/warp7_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig index efb6f51..d5dc009 100644 --- a/configs/warp7_defconfig +++ b/configs/warp7_defconfig @@ -47,3 +47,4 @@ CONFIG_USBNET_HOST_ADDR="de:ad:be:af:00:00" CONFIG_OF_LIBFDT=y CONFIG_OPTEE=y CONFIG_OPTEE_LOAD_ADDR=0x84000000 +CONFIG_BOOTM_OPTEE=y From patchwork Mon Apr 2 22:42:09 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132687 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3102300ljb; Mon, 2 Apr 2018 15:49:03 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/sbBHVTo5g5rc0XSY6f40vV6LsD0jNbGtP9a4hdRMQsQcJVUnKjfcXFfulrIwsjTj7MKf5 X-Received: by 10.80.153.68 with SMTP id l4mr13987277edb.179.1522709343261; Mon, 02 Apr 2018 15:49:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709343; cv=none; d=google.com; s=arc-20160816; b=liDw3lGiaG+3lXKykXwPiidBQDqWU//6Qdh1C69490iHJy4CwWJRcieOTA2gnSb1H9 Ko9wG1+E0PwT2Mg87xe4hmAKO01eOA5dCumkXEySNrVvjyLUUZG/qFJvp8BoIEEU118S Gjaug+nBVWPdAtPj+qLy8dQNoxl0bodaRn3Bs44CQoJQerUOUne1WQe6BzfrJXTwbxum jkBuoP2eJ51xHFX/X+8QUmI14AfP71NyGZHN+gQ3Cwrkfhdh+xr0tRR1AKz/aTVFZsTh qoyv+y/aeegTMEIneMqA+ydoYlYBq+kZqwtghhu5s0WASEroqTpKgfk2zVtmrU0i9Kwi 5dbQ== 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=RmAxXXQbGBxOnk1Z8DYlAjK8h8J46hMi1PHrnfftetE=; b=ikzOcRx7cme+/O2H6hpUxqARJbIbKGUXc3haSPQ7b5cum44MhUvpS24uIES1rs6s1V DOUeark7hNKUrxi3lglnjZVCfq7iaL9HXk+8v58wAdDgPLGESg5ICjvK8/szLaa4aAcI s4B0Lb3d7FomABFLbSWkj6l1S8017iAnTw885WdIQfSvOexESt1sHYZdmOoNz3zdJCO+ eKs2imeLdp6cC0DU4pyyjs58bgvCFClxhEvp3qGWB06LxgO73d76p6hs63ankyB9W/wB 23OOP8sREKAMG2v4MJyauDvo0YVe4RP16jVVAD3WpquuDlsZOoyRXkszoHAbymJrdH7q jrTA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=ItxYiZeM; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id u15si1170286eda.233.2018.04.02.15.49.03; Mon, 02 Apr 2018 15:49:03 -0700 (PDT) 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=ItxYiZeM; 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 DE331C21EA2; Mon, 2 Apr 2018 22:44:11 +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_H2, 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 6441AC21EBE; Mon, 2 Apr 2018 22:42:44 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id E3533C21E7E; Mon, 2 Apr 2018 22:42:35 +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 89FDDC21EB1 for ; Mon, 2 Apr 2018 22:42:30 +0000 (UTC) Received: by mail-wm0-f66.google.com with SMTP id x82so30477527wmg.1 for ; Mon, 02 Apr 2018 15:42:30 -0700 (PDT) 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=jEJ2K86Wbbdpj7z+Xd0250Q+apqTUT7spA9kXplFwfQ=; b=ItxYiZeMucAlO1k+igfQYuYARwkd8QtGuhsc7bozSeqpPOZzl6KhWcAVHYwNkOhVLE uThoK2ytaHNt1iFXu5OGw/gouYxp95f4NMof0jB8mOon0uZ/r5OZJDPOqnfLTy6PrAJi 06oGIe9dAL5zmDd4G87eOEtBJhczHij6k82Bg= 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=jEJ2K86Wbbdpj7z+Xd0250Q+apqTUT7spA9kXplFwfQ=; b=L62Y9UzYEk7Xj3q8QESxS8AHTUv9D3TGbr58n4ML/mjqPwjVDpYqkuOlYnJIEjFkBG rtRR45OAm2qsh1efqRLgRewgyjaMdGVSizsYEWIUObBKx+HRGWuYM1X8iYijJD/dI+Yf AzGxLnnGoySnaKnk9XBKw2LXfi9mI4OvgX4COuyPVzBbCyD2PWnGOF69H8Ka3XuBP+X1 33nxdfmOk+GpKYSF/ZRGOKH+MAu8Dv5LFGZpIvxG/xY4/oMgtc5u+JZiM3DHvFTpMjSF Uv192kyxhvt/du7NAjMQniwfjhmUwpSBuvamVJiMkM5Y5Yk70lhnNi+pfw7YitygzL4G A1gw== X-Gm-Message-State: AElRT7GSYJNFAW+eYRCYNHPmI0ZFOFA1YQc5A17rwv2uNHN0Hm07jeWP 7oWhtGKRBf4Drox4m+C4Nvyxy+zYjeA= X-Received: by 10.80.170.152 with SMTP id q24mr14558439edc.43.1522708949238; Mon, 02 Apr 2018 15:42:29 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:28 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:09 +0100 Message-Id: <1522708936-7603-11-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 10/17] warp7: Make CONFIG_SYS_FDT_ADDR a define X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" In order to sign images with the IMX code-signing-tool (CST) we need to know the load address of a given image. The best way to derive this load address is to make it into a define - so that u-boot.cfg contains the address - which we can then parse when generating the IMX CST headers. Signed-off-by: Bryan O'Donoghue Reviewed-by: Ryan Harkin --- board/warp7/Kconfig | 6 ++++++ include/configs/warp7.h | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/board/warp7/Kconfig b/board/warp7/Kconfig index 61c33fb..00df19d 100644 --- a/board/warp7/Kconfig +++ b/board/warp7/Kconfig @@ -6,4 +6,10 @@ config SYS_BOARD config SYS_CONFIG_NAME default "warp7" +config SYS_FDT_ADDR + hex "FDT load address" + default 0x83000000 + help + The address the FDT file should be loaded to. + endif diff --git a/include/configs/warp7.h b/include/configs/warp7.h index e12b90b..344042c 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -39,7 +39,7 @@ "fdt_high=0xffffffff\0" \ "initrd_high=0xffffffff\0" \ "fdt_file=imx7s-warp.dtb\0" \ - "fdt_addr=0x83000000\0" \ + "fdt_addr=" __stringify(CONFIG_SYS_FDT_ADDR)"\0" \ "optee_addr=" __stringify(CONFIG_OPTEE_LOAD_ADDR)"\0" \ "boot_fdt=try\0" \ "ip_dyn=yes\0" \ From patchwork Mon Apr 2 22:42:10 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132681 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3100219ljb; Mon, 2 Apr 2018 15:46:21 -0700 (PDT) X-Google-Smtp-Source: AIpwx49KEWRIOFfeN0F3IpswG/pZcERWsj5jrDjZ0HTFfy/7993kYogxyq4bNCySmjPzfnykMeb3 X-Received: by 10.80.242.144 with SMTP id f16mr13749497edm.52.1522709181837; Mon, 02 Apr 2018 15:46:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709181; cv=none; d=google.com; s=arc-20160816; b=XZMR5QHmZjNhNJIxfXLC8iEs+1T1aLhQsdk8qpIQDDQGW4n1ayQoItIoW3ITQkYLwo qPz6WaoxzkBGFgsLqxmDFl0yFF7YlxwVCiOdOubMNeIOKtpIkLOeEWX5RNDIDX1rCa6P fzkETdG64gHnQZAtBdPktFeOL6Mjo8aRBeC/CqgTrvpdSRLiG6W06UgCnOVm3A/4TqBh Z5QR053pqUGtVGtAFcSf4GnIC16Sn7FN5bzhnUTc0V5amLx6ME7vNF0JwC+1qLipDfvu Wtf+2kZV29Fg1QvXWGkxgnkivix6E/YnsFWmQzv8N1B6YTJx4P9Y6L5O8k2C7gTaWPzm Tbjw== 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=pn8Hvq4XbmzvF5kRpbh+fA33Lc0pK39oKknyiqFVvcg=; b=utkVsepWTtSr4DOggNsV/vFBSKEVbMIUNI+p6qVy/RqtQREJZ++gPRUeZ8sh1XrYdY u3hHjuH9Lq6YFCQmqIH8GaWh+wT3o28O3DxZA4npq9WhoTU8h9txwE+KCzv5kzeNeXp7 zT8KqxDoG/G+4MQsKbs9qdIQyzquEDeVskbnmK0gDzpNAj2lZ8oO2NGgF04xIb2Sp1G6 DQJxBljh9+C9sQBSKPe8CXSqp4TjVsyMnPoQnyneJBGyfJzSXMzBiM4Ow9jcehbcZr82 +EoKOUXXZI84fshzu7AFrpXTQc4Bci1Q+OD3rePn77yKukQ/TNJnZXYiG927YEgcHyhP JF8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=eaPpAApA; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id p7si1245773edc.248.2018.04.02.15.46.21; Mon, 02 Apr 2018 15:46:21 -0700 (PDT) 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=eaPpAApA; 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 3E095C21E15; Mon, 2 Apr 2018 22:44:27 +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_H2, 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 89D01C21DFB; Mon, 2 Apr 2018 22:42:45 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 43341C21EC2; Mon, 2 Apr 2018 22:42:36 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.denx.de (Postfix) with ESMTPS id A47FCC21EF0 for ; Mon, 2 Apr 2018 22:42:31 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id f125so30446659wme.4 for ; Mon, 02 Apr 2018 15:42:31 -0700 (PDT) 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=/2tvjMqvheFPaxDToxnSUfvJvW4njbPu/uUoO+4TLH8=; b=eaPpAApAljrw9+SbfYs0mqiU9LwkvbM1YsZf2YC1WgJ9ncFTGxYlKMvwX8nlxEY+Eq 4e/+gmKsfA2f/yC42fP3HERL5qEHU6eYnDrw7YxLdgAP67+/lt32Lt5alBSjlofTn7nJ GEl2EWnAMR25F+iefY3RLJNNLatmvnUcgiKg4= 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=/2tvjMqvheFPaxDToxnSUfvJvW4njbPu/uUoO+4TLH8=; b=JjIxpfVhuTaCCoYmN/+Ixgf59Mh8cOcyvJHQxBrgoklK+kF3nepTgOqU33fSlgyGbZ gdm+edsQarbBosBuQYVhK0S8M2Thm1ntJLFUNiR6/JIn4o8MPabaPa/+tK5TauHMO+by A2PU9AkJTg+0X34eoBKxgkyjEu67pvkk86VdOg6AZxGx+965bajvoMaiyyL6IwHhvKyH lSNxB9Mq7wyFOYIc2vPEFhjiLw/3mBG7gADwIeBTfUo80SiyKzP1FOBtcWsnrVaU783d 1wPtbXPlBRQnnx1g9JrYWxdixJC4jbVtFCV4Di17Zd49x7p/QRUv59vdtLz81v9M43wW DlMg== X-Gm-Message-State: AElRT7GsS/wEYNakoHla+Tm8075kj+/5IY+mAoO/zwX0r3CVGlCM+2Sg UUN7iXJYcnQFnuMEwYs3WD6fCJkuB68= X-Received: by 10.80.144.195 with SMTP id d3mr13905117eda.54.1522708950249; Mon, 02 Apr 2018 15:42:30 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:29 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:10 +0100 Message-Id: <1522708936-7603-12-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 11/17] warp7: Add Kconfig WARP7_ROOT_PART X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Adding CONFIG_WARP7_ROOT_PART allows a defconfig to specify which partition is use as the root partition on WaRP7, this is a desirable change in order to support a different partitioning schemes. The default is the current partition #2. Signed-off-by: Bryan O'Donoghue --- board/warp7/Kconfig | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/board/warp7/Kconfig b/board/warp7/Kconfig index 00df19d..c089bca 100644 --- a/board/warp7/Kconfig +++ b/board/warp7/Kconfig @@ -6,6 +6,14 @@ config SYS_BOARD config SYS_CONFIG_NAME default "warp7" +config WARP7_ROOT_PART + int "Partition number to use for root filesystem" + default 2 + help + The partition number to use for root filesystem this is the + partition that is typically specified with root=/dev/sdaX or + which gets converted into a root=PARTUUID=some_uuid. + config SYS_FDT_ADDR hex "FDT load address" default 0x83000000 From patchwork Mon Apr 2 22:42:11 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132692 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3103496ljb; Mon, 2 Apr 2018 15:50:33 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/vynGDnWpYRaBk9QnqurYOUZJg4ARnWAIM+J/yHc5Xco8CKKJ5RTzwyDX8r59p6Lx46M/R X-Received: by 10.80.189.193 with SMTP id z1mr13897417edh.119.1522709433631; Mon, 02 Apr 2018 15:50:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709433; cv=none; d=google.com; s=arc-20160816; b=TDXDyNkWp0EegEzP6QF195SGa5Dn6vS9FkV8LH3Sl40YRYNrEzFHtJKaAPsMN8Xmyu hzC30MW9CPxA1cHNdMaWEk838UZO8VcJTl7LcvWsami6GiFlo4Kclu4vnmE21oC0NuM6 OA3qEpeKOCscwiZAMBvvKf/mcURKY/9tlYgpqi+FjWkVIHc7ZgWIcSjBzc2hdYqkCxvi cd/wxPbLrWmgbqdTz2R9nhbZASbgAjDqsUYlaAbN/vaIcy7rB+eJzf08uZNZVv7hWZD5 sBmKjALofkcxwFH3ACraHQvxYgu66KCEWSHqPbIPfh9rHFYC+rq5JSIKjmDg6v7vYJ2p EbSg== 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=C9UYAeiTsC1Nw4oST2JOhhJIGOzkUXaiXPclmszO33c=; b=xn+wFL3BqU912QRv0gFR1wrNw1q0HlkBsAdMwWLdqlWMUKlytqUpwxiZojAucJPk+B syVeSeE2vmhbZMyTynd2ppsc069stPsrK11CGG63vpua3wkD8O0hGaYoI/J2wneU57i2 BFBnllvG4zIoAIftZH3T8nvKR+l5WlwqpJa1tyZYmRlrm+dyZggGv5XJAoGqeMkY2Z7z plqoT1F7MTeKzxnWNObAFuz3KkDdArpEeByGgnJSwo3y3fZATPV8mVYb9bDNMDZ6WaMs nSWW3eHwQhnkPJwKZJfC9ne3ac0a+eq6PgIVjyXxlT7bRdmPH3n0ah1rw/+d2O2cdZc4 xFVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=RLs5jwHT; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id j20si1190236ede.348.2018.04.02.15.50.33; Mon, 02 Apr 2018 15:50:33 -0700 (PDT) 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=RLs5jwHT; 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 2943BC21EC2; Mon, 2 Apr 2018 22:43:37 +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_H2, 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 4690EC21EB1; Mon, 2 Apr 2018 22:42:41 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id A8B3EC21EB1; Mon, 2 Apr 2018 22:42:36 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by lists.denx.de (Postfix) with ESMTPS id 8AA93C21E8A for ; Mon, 2 Apr 2018 22:42:32 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id x82so30477652wmg.1 for ; Mon, 02 Apr 2018 15:42:32 -0700 (PDT) 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=KgrE6YnsKs+4xDftmSHKc3zTTtDMLVB3jc+2BUJ5WCU=; b=RLs5jwHTrd+p+8pxnHBmfk9IOC+1bOQhLy68ZvE9Sz0PxbHkHbB85O+6Ri0Hp0rbdG 6fJnZ0afbi4hJbdxCPYxfQPqHbjg1+Ezxs/lRR8Qipa9aO9zmkX0i1nuxr5DzGzRUy2n 5WVazC9/AVuAeaor7akryR7Rxhy9gt8ehvj3E= 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=KgrE6YnsKs+4xDftmSHKc3zTTtDMLVB3jc+2BUJ5WCU=; b=ACZCIHF+TP+nU7gTmyERq6ySu62AmEGtqJcEymMJMrMtoI5BapLJspG7wLrNqH/6iU u6PpDQYmNdro3+Vqqys2ei/GAIBrB1+1UifZ5JnBdU3ViojK+jFsW74tTlddjpcM77FL 35kf+l+0Kburpkm4H+Pe67hsN1EhOJm/CaesH8tKAEuC/eQvY2JJPoy7oYFNV1FP+/OQ KobiUuehWqiHD4zOuG9nQTI95F92UZKGcn6w4WUpCgrrT6sN19OZvyyvi5Of0Wbk9McS F8EUa7JsogALxcqbckdIH5USwQ2/8E0/tpV/0CruSooLNFBYAsQrvomCRUnDBnVYXWMd Nqeg== X-Gm-Message-State: AElRT7HAYJ3W9mO6yhvUJNCh7KQCCBQhc5OiCPfu54scS7jNKp5eEPJ7 xlPCwhz/eKYRbUyN6r8+XFBZCoGwKeI= X-Received: by 10.80.232.195 with SMTP id l3mr14092262edn.307.1522708951220; Mon, 02 Apr 2018 15:42:31 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:30 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:11 +0100 Message-Id: <1522708936-7603-13-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 12/17] warp7: select uuid partition based on rootpart X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Assigning the UUID discovery path to a tweakable environment variable means that later steps in the boot process - particularly a boot script can change the target root partition of a particular Linux boot. Retargeting the rootfs is an important feature when doing ping/pong upgrades allowing a boot script to select ping or pong as necessary without reprogramming the bootloader. Signed-off-by: Bryan O'Donoghue --- include/configs/warp7.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 344042c..54b3b31 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -45,7 +45,8 @@ "ip_dyn=yes\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ - "finduuid=part uuid mmc 0:2 uuid\0" \ + "rootpart=" __stringify(CONFIG_WARP7_ROOT_PART) "\0" \ + "finduuid=part uuid mmc 0:${rootpart} uuid\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ "root=PARTUUID=${uuid} rootwait rw\0" \ "loadbootscript=" \ From patchwork Mon Apr 2 22:42:12 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132689 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3103031ljb; Mon, 2 Apr 2018 15:50:00 -0700 (PDT) X-Google-Smtp-Source: AIpwx48VM2MkZSMVe0ejrrzP0UvSDBcUmj8DXVsyuWnRPz5fpMkdqHIsVfgIwAD0pRJjMNczdbFt X-Received: by 10.80.202.9 with SMTP id d9mr89497edi.32.1522709400756; Mon, 02 Apr 2018 15:50:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709400; cv=none; d=google.com; s=arc-20160816; b=JyNwH90sgA5xSDIOQG4dZDIJNl6KJaz0eIQKzv6didtCb8a7jx1eeW1AH0bMuIdiRb Mqrx45pb++f23tpSYeKJopWSTKiABm5MtqsoDI+V+NVixWIuYLXTvz0SDSXncPInYPJB QMhGmMX2VD1TqiBuPJW4WkHci5HfA0r9voI/Aeyoktai/PYpZDfI66ebDTARTQ/KqzzM q9wxkd318ladpVkk/qDzL65s3XhzGMOyP4ngOHBbIE2wRJPTZjcvrtSK+2edruOD+rXP lC+1PYEbTCDv16LMY0sqY0yFMldbHL2jrfpjPEMdrspuiq8QagSm4XERNEbPzmjNjeBh gzng== 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=QgeunUfCuKN7N9+bM1Yqonc7Lcfqaugkq7UMnxSu9uU=; b=h06gothki7FuwLiIQBxog/wHnl3VrZndGYkFSlNanAv8IZGUyJ/VpGiM0nq4lT4qVi gPYj+Ya3RGYTj34DtdoKDl4HUYjfE1ILvqJNAT45AH0ocSeepV7SEqWwSHaafYXf1BiB yU+KfGyTVcszizfKCQfN4RhDXP13FLpcq+DYSGGca6tVQJu6O8wUTuzyZ05y9cELoGjC NjVSXUiWEhPK1WxGE5VROMzV+883ydh1su4IOkUIfkSH4DhtGtb6oyDYj701ukroMPxT IeshOgbZFp1m5ZhjHlzdDx+al+2t90kCGWn3uy1CytzO8EbgmXQcORvidT9WHt2/AfmL Su5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=cqwZo3Xs; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id z7si1199417edk.273.2018.04.02.15.50.00; Mon, 02 Apr 2018 15:50:00 -0700 (PDT) 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=cqwZo3Xs; 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 5A093C21E39; Mon, 2 Apr 2018 22:45:16 +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_H2, 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 065D8C21E26; Mon, 2 Apr 2018 22:42:56 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id B5211C21F02; Mon, 2 Apr 2018 22:42:38 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.denx.de (Postfix) with ESMTPS id 62CD4C21E07 for ; Mon, 2 Apr 2018 22:42:33 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id r82so30719048wme.0 for ; Mon, 02 Apr 2018 15:42:33 -0700 (PDT) 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=I8ilgkoGvjpGEZgG/JpqUFbj6BMprlamKSA/Wtdwwuc=; b=cqwZo3Xsdd65LJiFAFDyPKbMZujcioV3ByPqsTZLCBlepeqxQRo1884h1S+AxQJudn PRb0io8QHGW/Bsn8GGXVN20IVUz0iaUQgdwTK9X7gu7nOZxfyylw/+2WxCfF4YEq5d76 eEfpMC4bdswPoBgCgyqD4r8pP4V12eBKRAdEY= 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=I8ilgkoGvjpGEZgG/JpqUFbj6BMprlamKSA/Wtdwwuc=; b=Hwm/vo4YMgvGrS+ftaL68dHmhgJwuhlXU1XMr0MMU5KsXgV+KWFJmWAblvzW9s3p8R b/TP3DWdAI/9XUuu8EQEIBTjfPZGSJjHfea27VqpdZJZ7SxKelPMyvCf48VynM/CjD7i pwtT2XRd3EdDSKCJuJGuNN3gPSmn9Ns77MK6aDLS3anJM05KUfeUWQbOXVNdLZcj3jNY QmK1Fd+BpsDC1if9iKjOhU5kcuVhv6OWW5GIT3Gw86Yr0m9s3cPCGtzhXJcnjF3noH8S D7MOvoqRqDr6iSnwB/uxJdaR0GlwWSAN2sozKJOf4dPzkg+k+GhI7Evibnh6pz7L07bO 4syQ== X-Gm-Message-State: AElRT7HqmG67ho2svEcfczN3Tm4SO5hLFHjGUQMM4EaydzNihZHlOJyI ZiqYCU1/scfhxlETn4Jyu1+LsPJ2OJY= X-Received: by 10.80.147.89 with SMTP id n25mr14229423eda.189.1522708952213; Mon, 02 Apr 2018 15:42:32 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:31 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:12 +0100 Message-Id: <1522708936-7603-14-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 13/17] warp7: Define the name of a signed boot-script file X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" We need to know the name of a signed boot-script, its better to have a separate variable for this then to simply append some fixed string to an existing image name. Signed-off-by: Bryan O'Donoghue --- include/configs/warp7.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 54b3b31..0ed95d8 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -33,6 +33,7 @@ #define CONFIG_EXTRA_ENV_SETTINGS \ CONFIG_DFU_ENV_SETTINGS \ "script=boot.scr\0" \ + "script_signed=boot.scr.imx-signed\0" \ "image=zImage\0" \ "console=ttymxc0\0" \ "ethact=usb_ether\0" \ From patchwork Mon Apr 2 22:42:13 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132693 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3105142ljb; Mon, 2 Apr 2018 15:52:51 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+Tz/rn9Lz8u1sv5pbatYbfVY5+SQvEGH911+FgbexwTKgcwFk1a63xztDuUa0O4FqhppPY X-Received: by 10.80.245.189 with SMTP id u58mr14025946edm.270.1522709571251; Mon, 02 Apr 2018 15:52:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709571; cv=none; d=google.com; s=arc-20160816; b=sO4VhtO+uHEwfqyhlkP7wh16PMjfHIYD1x3sVO9nkkVV47b6NINb56Ndhc3tSYN18v eHD3oJaUlFLy1b7gX/naUVR+F1ONdxvY1IZvmDcsHz0a5yUhH7vfVCwcrs0Cq7+08t4P FwtfWy0v8JMf+wEfL/IeEXX9Bg2fhOVS+VRE2MOEKlWjWebYDo06BbNUUGnGKZrSgAbV bT+uD0awzty/YY3pneXeqPqo6dHFrxGDcE0SGmi1UBVkjAENjk56q62QNde00Q0whTUM AzvQuHlwFM6hbJPQM6R7t0GvUYBfhy5NunsfnFzRhrs+IB5ihLAN12kBPkfrObS7M2jw Sy3A== 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=Nwje+9EdbgjXkvFQp12NdA3YQNRAed/bEiUIIndMttM=; b=WwT6MT0spcZFfyYJ2YytlGsWeR5kJPs5bBrGMS9xYcBIK1jA64ydIAT4bldE+J1Fwf aab9IGmlx8iOxp4f2wsnr2ue2gbWBm7du7J2xsvT3schAnzODJFoxqimDa61gs1l3324 YO0zk9EdXBo0qxto9jqHgr8UnrWZ7VWiaD1IQPEVPm7U2wpen+OR6+qgnbvmoeN3ob8u VkFihNxyyJxSZMNZZurNwM28AAJM2gwcKlO4l4x4O9U91f64PXJvlC3f97L3gOW+bOcV ry1iiFxjN+Yjl314s5FMLCGXngngl6k/g4L5a5n8Q1Vukx2F61Z+yoXSUtt8yAgD18Up cS9g== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=jB6jGIgq; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id 50si617413eds.499.2018.04.02.15.52.50; Mon, 02 Apr 2018 15:52:51 -0700 (PDT) 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=jB6jGIgq; 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 C054CC21E30; Mon, 2 Apr 2018 22:46:37 +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_H2, 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 94ECCC21F01; Mon, 2 Apr 2018 22:44:00 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 0EBA6C21EF2; Mon, 2 Apr 2018 22:42:38 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.denx.de (Postfix) with ESMTPS id 85499C21DFB for ; Mon, 2 Apr 2018 22:42:34 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id x4so30420751wmh.5 for ; Mon, 02 Apr 2018 15:42:34 -0700 (PDT) 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=bbFAncBFRkexED0uhJw8cduRh56y9IoLFmos07tqqVc=; b=jB6jGIgqBXE0QwdqxdxUZvVyagJmPcm184j2xMSJ1V+/lG8VJz+vzzJOyxSlMbuQ6O cID+4co7w3G1LWU5Yas7Itx5KWaePLz5LOz63xHpHyR7yj16Nw2ten2+cJWTF9dG1Ec9 P2Q8od+UTyBaY2ssjQNSp1yhjeVvjyAdoKxpA= 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=bbFAncBFRkexED0uhJw8cduRh56y9IoLFmos07tqqVc=; b=lxifx0M4sZgOEEToRuArkl/lhvTJ44+XIquFDZ3Dhvrr6/b4n0J4FIxGuNLbS22rdw vrXI1SRtJCi7JYikeCNBkP/zcR6GH4F/x0EWeG6LVVHf3xdqY56ZL/+JqK1qhpn/8AR8 6YLcIlhnJYGMn5I1y+KHywOnQW68lHLEnToZvchefDnGloM13XtZ9ib3XaDQ+8hHS8Mx qk0aCsTXnHvfp/7xxUg+xVcf6YeZW0brIEcy1w5/8rUXiBb3vOjw6BoxzO985MM6JKNe ztACa2U7Vtrc93EkfhDUli29ImMSHDUvtTpVdHyAatLnMblD22p7edNl6jP/j9eYYgmn K4WA== X-Gm-Message-State: AElRT7HZy17pwPIK/GicV5kJwpOOaX9GZe/QCcP9y6RqSHYpWGDmhwkw Gs4FHJSwichhWPmmJjd5CNv7AcSvu3A= X-Received: by 10.80.192.72 with SMTP id u8mr13996491edd.16.1522708953220; Mon, 02 Apr 2018 15:42:33 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:32 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:13 +0100 Message-Id: <1522708936-7603-15-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 14/17] warp7: add warp7_auth_or_fail X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Doing secure boot on the WaRP7 using a common image format and the same variable to represent the base address for each call means we can reduce down the command to a single environment command. This patch adds warp7_auth_or_fail as a wrapper around "hab_auth_img_or_fail ${hab_ivt_addr} ${filesize} 0". Signed-off-by: Bryan O'Donoghue --- include/configs/warp7.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 0ed95d8..454bc1c 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -50,6 +50,7 @@ "finduuid=part uuid mmc 0:${rootpart} uuid\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ "root=PARTUUID=${uuid} rootwait rw\0" \ + "warp7_auth_or_fail=hab_auth_img_or_fail ${hab_ivt_addr} ${filesize} 0;\0" \ "loadbootscript=" \ "load mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \ "bootscript=echo Running bootscript from mmc ...; " \ From patchwork Mon Apr 2 22:42:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132690 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3103178ljb; Mon, 2 Apr 2018 15:50:11 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+H+nYLFu3R1f5CMJuDnVDGu/DiKWKL9xAPE3a5iagKJVqQxI1+awOrhb0JxQlBWC93uzzm X-Received: by 10.80.202.199 with SMTP id f7mr3158952edi.190.1522709411677; Mon, 02 Apr 2018 15:50:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709411; cv=none; d=google.com; s=arc-20160816; b=N7I+v/8MjP9iCcmvwDLhiweTAUHaeasNnlJHcsg3ZS3DUwG9kfFBuXAViy4JSir8An iadarr5xSjtsS0sIuAmSgILHFdmUrl1xuKn7n9dZz0K3V60ei7CmRx/Wnf6YZHeqgVzI oZbNd8LroogbCqZliUWfcG3TYCdAwm0jUspKDgIJ3sftK0h8wpzLTgQ5Yxoq/P+M3EfK mJ4ijOxZoRavxRT2l/tX+OCZaCxaBnzSRVPn/P9zuajsFupqQ9UcOpW3uHjQFB0SwANm /Sn5CkOtZvbKk22HsasNO7IO9w6p22soGYrN0EFOeRMdLyKpYzQFtotmcHcfqTbedu0d nijA== 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=+3GY7jsHY4IOVIPrtDBTeZp6NikRmdXql7LrHtZGCJU=; b=b08Rf/FABW/9WE24ni3DmLP4LEuNEIR+jEj9xBERB+GMnfVaTePDZuXyW9VGW9wVPO 4AUQ51yq3KzetOBH5tsjK37eMJ0pzfpiOp/E0SUV84FseUp9Lh/EiWtoRnsGM/sOnueQ MGnPtzLASjXcAcD3bZPh5WMVkcskW8uz41r6CbTcnrb/XJ/IjTNhlvooLGnfv/xsxUOD DCCXW9qWSiONmgeIBp6DA7tzeqQAHv6Sj8toLiSm1n/pyqBSD1X7J4FrBuNtQ/fLSzpm ZfBcgXZP4Et7netPesF1PTQ71x1HcD7/uu2Kg04dXtcsaG/lMpbYghCAMX8gyicbS5ee P+tQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=OCdndTmh; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id a28si1164143eda.163.2018.04.02.15.50.11; Mon, 02 Apr 2018 15:50:11 -0700 (PDT) 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=OCdndTmh; 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 3C2FDC21EE4; Mon, 2 Apr 2018 22:47:10 +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_H2, 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 2783EC21EF2; Mon, 2 Apr 2018 22:44:33 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 5D3E6C21F1B; Mon, 2 Apr 2018 22:42:39 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.denx.de (Postfix) with ESMTPS id BDEBBC21E85 for ; Mon, 2 Apr 2018 22:42:35 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id t67so9088985wmt.0 for ; Mon, 02 Apr 2018 15:42:35 -0700 (PDT) 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=guTPV85x+THIISQjael5JIJYgZEJI5AyKYRcOCLdmuI=; b=OCdndTmhn8YPSm9TAjTDqYe0p054u2EA0VdrpyIjUubLJQHFWvrB8kp+q9CS1FPPHa x58lWsksO58YnNAU1pwyeBqjcQPnCZHJyvUu1GN8lQTfwQuSsQfgDqOrwP8YTDQ81Js8 tWwpXur++M3ajhg6ruc/KsvIV8MV5jRKP62FE= 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=guTPV85x+THIISQjael5JIJYgZEJI5AyKYRcOCLdmuI=; b=joUms73z0/IjzEsrXDklVcgs+RYYrnvSErcST4mRsuYbq0gUAeJtUvLOnjqX3iJ1sh NJlAWPsHIUwXbEdktoYfX8qkgVyMxT5vtog11igVz2YSJYbYdVRCtHROOgALeNQdAZA5 Gx+kZxmOLq5IDnYlaNtBvRqOVM/wJwRXKPeKnvf30I79s1vNEblPChIOcNK16DCtJ+yR 2RJSS9TlZHVpB/Ag+yoa5sN+ZcpmauOvo9JXLNAWowtfoSfmssBckW2VSAKGpsGzATiI egjC5o1+6dIrNEfVSksZYCp62Fpd0vElJHnuNBWxrbvzt2/5unn0r0zQNYDHJEdkmW0W CBpA== X-Gm-Message-State: AElRT7HEY8m6VvHyfC17fK8g+mc4rm+lL6I9PCJ0CRp/3WwajGK9D5gQ YiLv+SIx5xYs57t5DSwYOqvSJA5IKbE= X-Received: by 10.80.184.225 with SMTP id l88mr13972491ede.209.1522708954564; Mon, 02 Apr 2018 15:42:34 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:33 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:14 +0100 Message-Id: <1522708936-7603-16-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 15/17] warp7: hab: Set environment variable indicating IVT offset X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This patch introduces the environment variable ivt_offset. When we define a load address for Linux or DTB or any file the IVT associated with that file is prepended. We extract the actual load addresses from u-boot.cfg and feed these values into the code-signing process - hence we want u-boot to have the real load addresses exported in uboot.cfg. ivt_offset represents the addition or subtraction from the load address that must happen to find an IVT header. Signed-off-by: Bryan O'Donoghue --- include/configs/warp7.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 454bc1c..fe9b7d5 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -10,6 +10,7 @@ #define __WARP7_CONFIG_H #include "mx7_common.h" +#include #define PHYS_SDRAM_SIZE SZ_512M @@ -50,6 +51,7 @@ "finduuid=part uuid mmc 0:${rootpart} uuid\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ "root=PARTUUID=${uuid} rootwait rw\0" \ + "ivt_offset=" __stringify(BOOTROM_IVT_HDR_OFFSET)"\0"\ "warp7_auth_or_fail=hab_auth_img_or_fail ${hab_ivt_addr} ${filesize} 0;\0" \ "loadbootscript=" \ "load mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \ From patchwork Mon Apr 2 22:42:15 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132691 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3103390ljb; Mon, 2 Apr 2018 15:50:28 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/n/+rpj86PCAj3UupnRq9GGBSSEChYVF2TCLvOU53M0RZ6SFfXexL8UfW49tRihCP4sQaD X-Received: by 10.80.214.86 with SMTP id c22mr14349641edj.80.1522709428262; Mon, 02 Apr 2018 15:50:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709428; cv=none; d=google.com; s=arc-20160816; b=USb+RRlK7XfpqAeGdc8WEcatwWrwE4hRs03dyQI7V9q86zWXmROQDVk0Kcq0HJNMdP eP6DNkL722XZJfhigMT2OUgWLMKlompSkZd1aUOabKRD943HEjH4WGqBup9eGAwiJI1l +M6rS4VZkWwmTS3Q+BO5dK8237ogXj+dtKdkc65fHzcgOvGw4yPTYCSg7rYSbMyrdXAs sY+gpSIY5Fk2nTQ/3ib0GFIK0xCIJsDnBe/tSLGpoVFt15t4f/Z9zlew4ilGuDIR2CR3 WpPk/qZKQCy11LED8hgPQqH4n6yfiJhmz5bPlqtU2T+QzGTi8InJuopcbO63KFUiHAOv ECzQ== 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=lwPWWDeZid8ATC9ESacv++FQNk/wQXxKaAC8ax5iPb0=; b=cMHqK5M6pqyVKIPE9uPczaX0dRS/YUvdxI5nS8TZ6iLQmwS4MeX6EbA+7woY/fDUSb 5lE9UYe+JvnaW2zYRiyS/lskej5el1OueU3MaDuV9fMZ8gVtmnYbcq9Bw8ZxJxtwuGiY x+0ZPSIfaZK+MtMWDWwf5JQavD/KjMrkHE2oG2nBKZeV2fsGBMPyRc8wlggy2bQhGnzU IvxLW3+meMwDia3pUAcl0ST6Qlu+vpGmtMtUpGSGq9a9QbNHzHUhEbR1xPMGCD2i5TO0 dZ5akK4+kJtDfDtUOvotZ3s8aErhvgyi8rwt0rHRMPKp2LQQ5OvWyXLAkw+EZxvksKsx VwMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=c4myxT0I; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id s14si55788edk.435.2018.04.02.15.50.27; Mon, 02 Apr 2018 15:50:28 -0700 (PDT) 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=c4myxT0I; 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 D652CC21EFD; Mon, 2 Apr 2018 22:46:21 +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_H2, 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 3727FC21E2C; Mon, 2 Apr 2018 22:43:50 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id DF619C21EC9; Mon, 2 Apr 2018 22:42:41 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by lists.denx.de (Postfix) with ESMTPS id E90B1C21E56 for ; Mon, 2 Apr 2018 22:42:36 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id x4so30420922wmh.5 for ; Mon, 02 Apr 2018 15:42:36 -0700 (PDT) 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=NoOuJsslD8u7MngS0JkNYqbMms4lh4K/97xJlI8wXSo=; b=c4myxT0I3+Z0vPyaQ3UvQ5Aa1WCm7E2wtcdFCxqEJpVKOgJzKpQ/UvmHRjkJmHX0fP k0XMH/k84b9BYgh6Y43JPi6w6onm61MBukibxaig5SxxiYLdsob9IZZzGDV2PMs1lg5L tjNM5zxNRrWNIvQJrImE56IOAIzWdqL7K+VRc= 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=NoOuJsslD8u7MngS0JkNYqbMms4lh4K/97xJlI8wXSo=; b=ddNWAwg8tEc1AGJSVR0Rbt+0hBUz6zMsa/9klAxDm34INy8Q85LnJ/SmyFzl9NFBih 9xiQC18Ry7UpF15/jQ773CRIJslOQdkMy7KbkU4qjLN9/rwyqr61hxUFKYqWI3gTY1d5 bed6pviLJ/sMspHSX4eZ34ar4Nry0fb1bG7Byi4C21IGO2AlIm26KScy2ZnG95lLxLEv hGdwaOB20c0KWnHN/CPlIn7nRv1tCIBvbJm4wZx4Vwue8HkQYSv9FCD+tuWq4pOz9xZt aWRnZwWNJ/LXOntTN2aCWWMGOPo3IJ2cT3pomHPOe2bNjEYlqx0TnL/dqMzrtXu1Xruy iPHA== X-Gm-Message-State: AElRT7HgDu4skbvb6PQv1z5F3zVj5r0vY2RrFCSKdxHHulEWipQl71eN rRHVWpSMKuD6CQTtqRbPjPrd5033bY8= X-Received: by 10.80.164.182 with SMTP id w51mr10677895edb.152.1522708955623; Mon, 02 Apr 2018 15:42:35 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:35 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:15 +0100 Message-Id: <1522708936-7603-17-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 16/17] warp7: defconfig: Enable CMD_SETEXPR X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" setexpr allows us to do arithmetic for env variables - something that is both useful and required when doing HAB authentication without hard-coding HAB load addresses. Enable setexpr in the secure defconfig - it's not required for the unsecure version. Signed-off-by: Bryan O'Donoghue --- configs/warp7_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig index d5dc009..13c760d 100644 --- a/configs/warp7_defconfig +++ b/configs/warp7_defconfig @@ -21,7 +21,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_PART=y CONFIG_CMD_USB=y CONFIG_CMD_USB_MASS_STORAGE=y -# CONFIG_CMD_SETEXPR is not set +CONFIG_CMD_SETEXPR=y CONFIG_CMD_DHCP=y CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y From patchwork Mon Apr 2 22:42:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 132688 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp3102612ljb; Mon, 2 Apr 2018 15:49:27 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+GigU/i+z2k0EKEl8y4NnsaFIkE/8RbXu3MMGcQi1fx1f2WSeP8upph8L22kzuP6XWlhmf X-Received: by 10.80.240.5 with SMTP id r5mr14459579edl.91.1522709367173; Mon, 02 Apr 2018 15:49:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522709367; cv=none; d=google.com; s=arc-20160816; b=hFRCAoW2qXAYJS70UEd00CieFLM87bzs6O/nO38tbvTQdX6n+54m279emsFGvOrnvB hLBLGLx1I0x8VT8V3eks0bOVgrnNjBnrLgLgHCIostkncNsy4f70w47P4OuNA2nqXYVQ eiijvaNgg5GG5HmM5YQ0GtdqnwUhdiWAUqn0Tzylu0w/auexnUq7mLbsIf+YruxtcXXM vmzYS43FHNaMrx9TuYCkge3jCat/yhnoXT1qqjecDYPoMmFqNHOFBuTVS/aP3n96nYxu fjpsjY99OymzQKn4JDIj+NXwN4gGSC8YloPDli6O/H7AqMJC+vk7Ol6MBTiQ7ch8xFQH GsFA== 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=+PEQecFXTQRi6QNoMc/OCk5woixB7kz9PlC7HOEfhro=; b=LaDaSzLIwHLzopKfBi7I9j3MbXpBf1w0fkBmKmDOLeZQmVFbE9XenkAkoNzMwyrZ/m +ZSyoB7OVFEdS8m+5Y9J2GjOQBmTBRMPeeByu0kef7AquWd1+eHBVPeQlU3kAE8IYky6 EKu3nk3eCW639fOMvPooZ7/gtUNk0HndeXAK9kHbofGRheMqJHsEp+4gsFiCcNSDa+1T vH2Jv5DTLAq7ub20+f7lSzzHA4WfJ/vKttJhqwTpCpL9GMRsZJWd3h4eJlGpkmNztxck gp/m3nCRbxPyR/E7OinGajH/mLpH515mAKgPfeo56fuFjyKualWFWxqUknDURZcQTHcm qtRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=f5G3dbPx; 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: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id j9si1086116edf.548.2018.04.02.15.49.26; Mon, 02 Apr 2018 15:49:27 -0700 (PDT) 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=f5G3dbPx; 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 CA1BFC21EBB; Mon, 2 Apr 2018 22:46:54 +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_H2, 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 BEE6BC21F04; Mon, 2 Apr 2018 22:44:27 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 87406C21EE7; Mon, 2 Apr 2018 22:42:42 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by lists.denx.de (Postfix) with ESMTPS id E0A0BC21DB5 for ; Mon, 2 Apr 2018 22:42:37 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id h76so29005809wme.4 for ; Mon, 02 Apr 2018 15:42:37 -0700 (PDT) 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=yVd1fav2PFmIPoPApPmBdYX5VkmcZ/lsc1NXAuRRRfY=; b=f5G3dbPxu1Mgeak3B1sgHSiFPHhgZ+AeSkyVuiGzEVv7LkEN9beOLQqZSFM2OCaN+f PsOQL+mwNX/ysH1Zc4WB1SDSN03z4Kz/21M1rYA8sx+PVTMFANn5Be8EHAsy3iLZEIVr OvPJrpnwTboihRUDTij3bPvegeZ5mX/cyu5/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=yVd1fav2PFmIPoPApPmBdYX5VkmcZ/lsc1NXAuRRRfY=; b=IFkbU0bSUVsLumgdr3wIjtfQ8HZx55KtkWTrE3FLDKLPtHyJGO3ZZSrXdYqDXwcd+q Pc0cZGf7c8pAGYigGLaxJtJMFwM3fjNvDzXas6EgDdeBeaeI8BhPrAhnBZjrDC2XjsUE dhIjI14zUCgeXa+Xjjx3IVe9BDQQY/joAPujaQnAtl7mJvh12/Ni5RDk3mDJooJPpVhE hDEprWentykcFZn45l0GIoFSh3GOzLiH70nqufxs0fze3N7z6ykU55d65kLGN1iYbYlH TuFWYd1mALhNUj3NbVyClByk5kN9tDdunzo5LmjdhAucyYXFIZPCh8ef3SlQUxbeBJLq 2Utg== X-Gm-Message-State: AElRT7E2K4/nYvNlXbDAdeKqVvu+N38Q05fliejO7gpKnfy8aOTEUTVs rFDNE6htEg/Xp+7+uex98mXUcelHWO0= X-Received: by 10.80.152.227 with SMTP id j90mr14266005edb.89.1522708956609; Mon, 02 Apr 2018 15:42:36 -0700 (PDT) Received: from localhost.localdomain ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id s8sm842086edk.76.2018.04.02.15.42.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Apr 2018 15:42:36 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de, fabio.estevam@nxp.com, sbabic@denx.de Date: Mon, 2 Apr 2018 23:42:16 +0100 Message-Id: <1522708936-7603-18-git-send-email-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> References: <1522708936-7603-1-git-send-email-bryan.odonoghue@linaro.org> Cc: breno.lima@nxp.com, rui.silva@linaro.org, paul.liu@linaro.org Subject: [U-Boot] [PATCH v2 17/17] warp7: Add support for automated secure boot.scr verification X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This patch adds support for verifying a signed boot.scr. With this in place it's possible for run-time Linux to update boot.scr to set different variables such as switching between different boot partitions, pointing to different kernels etc and for u-boot to verify these changes via the HAB prior to executing the commands contained in boot.scr. Signed-off-by: Bryan O'Donoghue --- include/configs/warp7.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/configs/warp7.h b/include/configs/warp7.h index fe9b7d5..f340bff 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -53,6 +53,14 @@ "root=PARTUUID=${uuid} rootwait rw\0" \ "ivt_offset=" __stringify(BOOTROM_IVT_HDR_OFFSET)"\0"\ "warp7_auth_or_fail=hab_auth_img_or_fail ${hab_ivt_addr} ${filesize} 0;\0" \ + "do_bootscript_hab=" \ + "if test ${hab_enabled} -eq 1; then " \ + "setexpr hab_ivt_addr ${loadaddr} - ${ivt_offset}; " \ + "setenv script ${script_signed}; " \ + "load mmc ${mmcdev}:${mmcpart} ${hab_ivt_addr} ${script}; " \ + "run warp7_auth_or_fail; " \ + "run bootscript; "\ + "fi;\0" \ "loadbootscript=" \ "load mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \ "bootscript=echo Running bootscript from mmc ...; " \ @@ -79,6 +87,7 @@ #define CONFIG_BOOTCOMMAND \ "mmc dev ${mmcdev};" \ "mmc dev ${mmcdev}; if mmc rescan; then " \ + "run do_bootscript_hab;" \ "if run loadbootscript; then " \ "run bootscript; " \ "else " \