From patchwork Fri Apr 16 23:39:31 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masami Hiramatsu X-Patchwork-Id: 422686 Delivered-To: patch@linaro.org Received: by 2002:a17:906:6d12:0:0:0:0 with SMTP id m18csp846402ejr; Fri, 16 Apr 2021 16:40:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw+fEGR+QHmZ4Yd4OEqSJrQypyHtrg//dwCRAGAf9spGyzA+/Xfp8224rnGym9t9bhtuZZj X-Received: by 2002:a05:6402:3506:: with SMTP id b6mr13291337edd.175.1618616426357; Fri, 16 Apr 2021 16:40:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618616426; cv=none; d=google.com; s=arc-20160816; b=j05GwAhpV/G96KehA0bIYBMYw+AhUvlqnVmxJpI05A0PtSTsdQejCx8PGXdHyykmlk ErZxK9wi7KRn5soQ1RbVrMNNVTujdweUWDb7EG++bXBSKX+9JY8CaoJQfh0Vj/w/aPCy TJfadJcDv7VJKKE4xrCus4sWIgbhHwS8ghAcR7OxLy7GRBZ330np+wJC6ZugztU1cjZn LFJo/3eB4Ol4p7ZaNHvKVv552oTjYrIlAXXRf3fuBp+aSFdfmZtl0UsuwVjxicEh5yA0 m3B0LB+BOcxBf3QAjprGJ7L+I7wpMiXm6P6lt/lOXn1LxH8q92u3xCZerWwNekaeiopM 0ZSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:user-agent:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=g9Y3JNbtAlGNmNK7lwv3MeU/b3jatG3+/QH8pXuAJQQ=; b=H3YUKZ3vuXCAsPjFSxS5ZOV72UYOfKsXJ/VK9rG4HKtGful/61F5MjsmgLTvQIevko /bfmQ10urtAnv82KAUKccwxkcmZ9ekhh5Z9pezL/FuTJlB3cZrPl/VFIdi5fsQvLNGaO dU0qLjeaY8MIzCc7UWh//lO3yUUaS4uyLhrd+rGFJ4b63RnziPo6//psW7CvhzHRYSS6 p9UJCIdyllkGoE/yTbbzqQM0CIi+TzjWMPY3Zf8eIFM6kaYbXSpfoYtUtjLPxS/vcvEv ECcXmPioP0KsL8rWSDy2o4RdsWbQG5MFdq/up1Iez+Ucql2LYo0Xg468r0ynD42Eq4n7 Tzog== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="jGGwDX/d"; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id f9si6052179ejx.297.2021.04.16.16.40.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Apr 2021 16:40:26 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="jGGwDX/d"; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 7E51382932; Sat, 17 Apr 2021 01:40:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="jGGwDX/d"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id BC6FE824AD; Sat, 17 Apr 2021 01:39:50 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-pg1-x52f.google.com (mail-pg1-x52f.google.com [IPv6:2607:f8b0:4864:20::52f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 1551782015 for ; Sat, 17 Apr 2021 01:39:38 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=masami.hiramatsu@linaro.org Received: by mail-pg1-x52f.google.com with SMTP id z16so20196909pga.1 for ; Fri, 16 Apr 2021 16:39: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 :user-agent:mime-version:content-transfer-encoding; bh=g9Y3JNbtAlGNmNK7lwv3MeU/b3jatG3+/QH8pXuAJQQ=; b=jGGwDX/dyu7uvIQC+jQ1Xlji8GyZhbzWGk3rFH0Xs+EG2ZN7c8lSVUhnHNQerxHk8I GFZVnBKdLHhVyL2g52/62HXxo6nlZneLbeJabc4QdlD7osiQEZRYH5Q58tcJIZBPCAL1 49hL4Z7/BnWRbhHeR3ZUyqTR4HBozJew80zF8Yi8OXB3py65wxRA00QYuW/ICwpWMKYm 5pgC0Jw9fby1yvD0B5K44Kd6zQgMGJmFAquOV7Kpj8gNdHLnY6onidEIQmupCHAvvqI6 QCEMw5+0B/YE2U+D/6xIwLvcZP74p76Dyp8eSjWL9U0xcyK5RmZM8PDbjmIXewO+9dCx BWPg== 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:user-agent:mime-version:content-transfer-encoding; bh=g9Y3JNbtAlGNmNK7lwv3MeU/b3jatG3+/QH8pXuAJQQ=; b=Nv84TLDplAWqyIO/NQYsXAI73L8Yz/86fhZZrRJhPXod9jpTA4LElo9eGVjlnjaurT kMj9YlRLEs/u+wPSAzP2n1ZqJhWz6a4+ELz3Eaok5IWj0yQpiSm+WRDLTVELuLC099d6 CeErK4VKZX13ZuA6CGPrfVZsra5WQ7e271uT5MxW2Vfzg2lPVfNPkC5Rkms8Rh2ZdoMb 9b45A3oz0iSoVSlLfYL4uKTVR131qppA0C9EZOB4qd2O/s4C5d3Dpr0G5NclqKUKopKs 1iRM20xJ6FhMg+HO/rOkhgOto9Y8hpSNhwT0FPF42VDHIQM0HVm/kbOuDdokiw2wTp/a loBQ== X-Gm-Message-State: AOAM533YmyuD9kPE5CK7qvngRUSci8Q/PhXCPKmzO5rQgWNtoIsMlOfN /YegXoJBKpqJEz7fT1wdLZ6WUA== X-Received: by 2002:aa7:8e52:0:b029:23e:5c6e:61f8 with SMTP id d18-20020aa78e520000b029023e5c6e61f8mr10056556pfr.16.1618616376498; Fri, 16 Apr 2021 16:39:36 -0700 (PDT) Received: from localhost.localdomain (NE2965lan1.rev.em-net.ne.jp. [210.141.244.193]) by smtp.gmail.com with ESMTPSA id f6sm6679247pgd.61.2021.04.16.16.39.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Apr 2021 16:39:36 -0700 (PDT) From: Masami Hiramatsu To: Peng Fan , Simon Glass , Tom Rini , Heinrich Schuchardt , Alexander Graf , Jagan Teki , Vignesh R , Joe Hershberger , Ramon Fried , Sughosh Ganu Cc: Masami Hiramatsu , Jassi Brar , Ilias Apalodimas , Masahisa Kojima , Takahiro Akashi , Tim Harvey , Bin Meng , u-boot@lists.denx.de Subject: [PATCH v2 13/13] configs: synquacer: Enable EFI capsule update support Date: Sat, 17 Apr 2021 08:39:31 +0900 Message-Id: <161861637084.298230.5043068311379698230.stgit@localhost> X-Mailer: git-send-email 2.25.1 In-Reply-To: <161861622792.298230.15803163505976731363.stgit@localhost> References: <161861622792.298230.15803163505976731363.stgit@localhost> User-Agent: StGit/0.19 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.102.4 at phobos.denx.de X-Virus-Status: Clean Enable EFI capsule update support. With the EFI capsule update, you can update U-Boot, TF-A and OP-TEE. TF-A and OP-TEE are usually combined as a FIP binary, but if the binary is bigger than 480KB, you have to modify FIP header, split the OP-TEE and stores the OP-TEE binary in the different place. This configuration supports both cases. Signed-off-by: Masami Hiramatsu --- configs/synquacer_developerbox_defconfig | 15 +++++++++++++++ include/configs/synquacer.h | 6 ++++++ 2 files changed, 21 insertions(+) diff --git a/configs/synquacer_developerbox_defconfig b/configs/synquacer_developerbox_defconfig index c0d6fa49c0..a0bbbfdd0f 100644 --- a/configs/synquacer_developerbox_defconfig +++ b/configs/synquacer_developerbox_defconfig @@ -91,3 +91,18 @@ CONFIG_DM_USB=y CONFIG_USB_XHCI_HCD=y CONFIG_USB_XHCI_PCI=y CONFIG_USB_STORAGE=y +CONFIG_EFI_RUNTIME_UPDATE_CAPSULE=y +CONFIG_EFI_CAPSULE_ON_DISK=y +CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y +CONFIG_EFI_CAPSULE_FIRMWARE_FIT=y +CONFIG_CMD_EFIDEBUG=y +CONFIG_CMD_DFU=y +CONFIG_DFU_TFTP=y +CONFIG_DFU_MTD=y +CONFIG_DFU_RAM=y +CONFIG_DFU_SF=y +CONFIG_DFU_SF_PART=y +CONFIG_FIT=y +CONFIG_OF_LIBFDT=y +CONFIG_CMD_NVEDIT_EFI=y +CONFIG_CMD_ERASEENV=y diff --git a/include/configs/synquacer.h b/include/configs/synquacer.h index b2dd6d0f0f..5eeb16ce1c 100644 --- a/include/configs/synquacer.h +++ b/include/configs/synquacer.h @@ -58,6 +58,11 @@ /* Since U-Boot 64bit PCIe support is limited, disable 64bit MMIO support */ /* #define CONFIG_SYS_PCI_64BIT 1 */ +#define DEFAULT_DFU_ALT_INFO "dfu_alt_info='" \ + "mtd nor1=u-boot.bin raw 200000 100000;" \ + "fip.bin raw 180000 78000;" \ + "optee.bin raw 500000 100000'\0" + /* Distro boot settings */ #ifndef CONFIG_SPL_BUILD #ifdef CONFIG_CMD_USB @@ -101,6 +106,7 @@ "ramdisk_addr_r=0xa0000000\0" \ "scriptaddr=0x88000000\0" \ "pxefile_addr_r=0x88100000\0" \ + DEFAULT_DFU_ALT_INFO \ BOOTENV #endif /* __CONFIG_H */