From patchwork Wed Mar 26 17:40:34 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Caleb Connolly X-Patchwork-Id: 876320 Delivered-To: patch@linaro.org Received: by 2002:a5d:5f4c:0:b0:38f:210b:807b with SMTP id cm12csp3301066wrb; Wed, 26 Mar 2025 10:41:02 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCUCvbs4MvL6G/CLQnCxhVFDwBhM132fZSlAt3Yc832x4hdtFqvN5p3DXpBlkZFTDDatxtTJow==@linaro.org X-Google-Smtp-Source: AGHT+IEphcEJgeoGlw/9Dlaquy0zVakqC7tCM0QWVKc7xEaigeFXYw0xJFMi7n7NT7+Tyr4GB7O6 X-Received: by 2002:a05:6122:2a55:b0:520:6773:e5ea with SMTP id 71dfb90a1353d-52600a56224mr791556e0c.7.1743010862254; Wed, 26 Mar 2025 10:41:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1743010862; cv=none; d=google.com; s=arc-20240605; b=lO3p2rwE+NLNPgM/o7uNn6W6yPbvCToKew7uWArGXSXELTqEQRxz+OoRF5/ltOfIVq RpRzCnMkqLQsjRo5uqj4vM7opaFfeMamJ8ox73qG3Wf3mGEuV/ZUEp2qqE0ebiCNpPEH OUE6OyZpWIctakzC/SAfc2YPjw/hTywEJloSYqyRt4l9M7lCiPqWGn9UrUJld8XqKGI0 gBYZo2OPy6woPojUMQ3O247oDyciZ8Zah6I98yJRtyqodKilbUxlzGPdoalZVNKwMaKu cFX/sginztE/SGMnuoCt/d0AjaQuV1UYXaqm2XIexE+eKqYfknjmFBNCM1UenP7XPcEX lWcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:cc:to:in-reply-to:references :message-id:content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=RmqA50PCDppqH6GiGKSG3+l+ZThH5KEwpsHaK/l2KQM=; fh=C9WxYFyLAtxCh/j+b9QUILDzba2c5s95xJmEy7wIhfA=; b=kznAKSfejs4zus9ZDqOnfpTMaIUTBld4umrJ6dCfVSjrACoYaOtmL0Gx0WnM+jtSDc VCgWjj3DbrhaOHixGe2rqWSo+R2x0aH4iJ0WcafaWNktjF8vF9cdJa5mhNPw3lX0TxSi GLWhHHQayGEGQJsU+GFV3Qsi21C0Tm9nvnNgoUpvMad3PNdod9kby9g/lHx+hA+DPtvF 1/X0vE49ezXUTQ8axkfvObe6Qf8k6gL7q76n02Mg/2MrT0A9/vV/57ok+qjxqqpLUcNK /HDHbF4KAFpkYmTezn4GAKOvCD62q/z7xMJfYs2OPkopLCaK+Qe/7pq5UzSncOMUlAo+ lPkA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=l7RtNyOq; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id 71dfb90a1353d-525a739e106si3097673e0c.68.2025.03.26.10.41.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:41:02 -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=l7RtNyOq; 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; dara=neutral header.i=@linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8531C81DB4; Wed, 26 Mar 2025 18:40:51 +0100 (CET) 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="l7RtNyOq"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4FA3181CFD; Wed, 26 Mar 2025 18:40:50 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x42e.google.com (mail-wr1-x42e.google.com [IPv6:2a00:1450:4864:20::42e]) (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 D56D481951 for ; Wed, 26 Mar 2025 18:40:47 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=caleb.connolly@linaro.org Received: by mail-wr1-x42e.google.com with SMTP id ffacd0b85a97d-3912baafc58so30995f8f.1 for ; Wed, 26 Mar 2025 10:40:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1743010847; x=1743615647; darn=lists.denx.de; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=RmqA50PCDppqH6GiGKSG3+l+ZThH5KEwpsHaK/l2KQM=; b=l7RtNyOq3+K2ssMkwSDjv2nUreWq3fffPmK5TBOllz8rgwJ6WuE3C3VkWNA4r27FpI HM0Cl3whYzaWxAsL4bzxopOde095XYPPwPMgsjB+CJYiCx3PNZuWsi/CaRQQ/yS0Txqk B4kmjwPqH3tC1Cymv5VtOjKlj6MCki2Dh9UGzYVJfCGJvqDtxZxKLQv4ued5v0H1by9z nqfh+LvzMHgfmP66Rjfz0XsHaYKYCIY7nRmda4gE9V55Thr/qcEg/UbM431Dixmxcy85 0ZhJ1wq5DQjsqDXgCLNUIe3iVR0DKmDLILmvWmOMnS/sqcSlmJ51+T1Wnzj/+A+Jgva4 4r1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743010847; x=1743615647; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=RmqA50PCDppqH6GiGKSG3+l+ZThH5KEwpsHaK/l2KQM=; b=albWMkcpKsrqPWv2qZIrtS3VWPBUQZQidQAeunGGkqlc/T7UwKn8ggU9y5v6wOR18+ hCsuo1uTyOfEpg2R5vtpe4wa5D91qpW9FRMJI4qy/WvfwIOWfOkhNT3W4XWWoETfS2D6 WCwq9A333ZzFB4r7omKAu9b4ln4WYtJSHvPUqaVXJPYWEHjbtGIz+PPGa3Sc7woELMOM 7+EvLaalf1HIZXnKjT2Bjx7ndguwMjQnCk53cinqoXfVoo7Id1ltwXqdGV01OvtVGayZ EwsiKZMQrJeywyMv4S+Vt4LL/jCsaHUtzzyXFLaZWRo6KqKndQZfvtjIgPX1Kza4qTwo 4mvw== X-Gm-Message-State: AOJu0YzbbB2qqYZefizWCqLDUQZ4IRlzuiXcdsEdqlVjaPy+oGZiJI37 mO0r0x6IFy31Y/aGobhZmBtdgqkgDecrOJcnxjx+jt3tzZU9mV2Cbs8H69KNwuY= X-Gm-Gg: ASbGncsW5S4Ma3BnauDG9v7t2SXy5uMOHKiFoHFRJnyNPkdrx2s10w7csjNcZWI6rZ2 nxGDPEgiYwrscAbekGMHp1dJcoY7UpN/G2M4qka9aCRw/wBGGFTxkZokSC2gRGnHEObIAnuK2C6 Q+duflbBW6W6tu9DGuZzn3Yzm40Wpe7Au3Xmi5H36VzC1V1SGPmaUA7qLonStxKobo6hiPeittS W+MDDM9qhlJa4l2oO0Ll+nrmpvY8vd7DCI1kizgJsQ0ymILb+4nbkRpPlU5oFzjtCF8vYKNuYbv sTYbkqp+sHgTMufBOCUAfPT54kZ9YtDQoxZzSzjz4wKzDJyUbyodNyus1OjIKChXlEaBfUaS9es IEYxyVpMPQxu4 X-Received: by 2002:a05:6000:1fa1:b0:391:3406:b4e2 with SMTP id ffacd0b85a97d-39ad17979e2mr245855f8f.49.1743010847187; Wed, 26 Mar 2025 10:40:47 -0700 (PDT) Received: from toyger.tail248178.ts.net (i5E863BED.versanet.de. [94.134.59.237]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3997f9957d9sm17397321f8f.9.2025.03.26.10.40.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:40:46 -0700 (PDT) From: Caleb Connolly Date: Wed, 26 Mar 2025 18:40:34 +0100 Subject: [PATCH 1/4] mach-snapdragon: track boot source MIME-Version: 1.0 Message-Id: <20250326-b4-qcom-capsule-update-improvements-v1-1-afe2e3696675@linaro.org> References: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> In-Reply-To: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> To: Lukasz Majewski , Mattijs Korpershoek , Tom Rini , Caleb Connolly , Neil Armstrong , Sumit Garg Cc: u-boot@lists.denx.de, u-boot-qcom@groups.io X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=3143; i=caleb.connolly@linaro.org; h=from:subject:message-id; bh=9/IPLkaPm9HY3mq3N3ogOIhYVqL1ygq2C0t1I6Hslso=; b=owEBbQKS/ZANAwAKAQWDMSsZX2S2AcsmYgBn5DwbJ7jRYBL0lCUT9jZRImfJukNXMDsXipTlc tVOfqx4w3eJAjMEAAEKAB0WIQS2UaFGPGq+0GkMVc0FgzErGV9ktgUCZ+Q8GwAKCRAFgzErGV9k toXgD/9C5ycwn/GOzmQGe5faV0JBiDQyDfPhh9ZrOjhfj+JNUbs06iq2n4wHKWzchc8HStKdCiA ybg8nVciSAEMi8Khi3zqM1UKdkpb6eabqpU03uCOOnj/lRtstPnXNDYdT+Pv/6liGX2hj/O4CFZ SxpS4ytBSnVUwFEv4y+0LzA71gmNwtHc7S711UIBVHrUq9VRS8AeX8lNh3H+3TnXNmUIy8mmXPQ BuJ/+0XW1yq9YOCLRnxx+eKmHyd+FzCug+OyOLngEO44YlL8FeBtBtgc+RXKlrcgpvMBAhrs0z+ 8FhG7p9Ozn9IPurQ7R1CAQjpmIpUvmVYsTBQ2MoEPC6emNq7ObYY35XOzAGbm++YMomGNKbX9Fr sqfcum4O7Q/jX+4ahIQuQul3Qk9PryWTE8XQDpK82i1zkpYze78reQk9K+jV7ecS6bqRgW+K3/L aBwjBQcabJf1WxUX3dBGKZZeFwRoS19X2Xf2s+//muNfuE3LjhIE7pwNZVVNaLtdaCYGTAYd75h 0nK+mJkIQEn5CN1r+Mas2QUHjxP9G6Gp4e4bdnoVWzhNrvlikUezYRWzRkjJ8kXA5tJD4A7YY+D +5LsUgMPoz8Kmmz3aFVvbnP1FaiLcRa0xZv7M4vrnOifDQwEOI1VXLAJlm61rFaAQ22ClAmjt2T zV4InzU55IrwCNg== X-Developer-Key: i=caleb.connolly@linaro.org; a=openpgp; fpr=83B24DA7FE145076BC38BB250CD904EB673A7C47 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.103.8 at phobos.denx.de X-Virus-Status: Clean Keep track of whether we were loaded via ABL or if U-Boot is running as a first-stage bootloader. For now we set this based on if we have a valid external FDT or not, since it isn't possible to chainload U-Boot from ABL without there being an external FDT. This will be used to inform the capsule update logic which partition U-Boot is flashed to. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/board.c | 25 +++++++++++++++++++++++++ arch/arm/mach-snapdragon/qcom-priv.h | 14 ++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/arch/arm/mach-snapdragon/board.c b/arch/arm/mach-snapdragon/board.c index deae4d323789eab75d5fe735159b4cd820c02c45..245a963f5321bda3030d3809e1b108f280b3c2b5 100644 --- a/arch/arm/mach-snapdragon/board.c +++ b/arch/arm/mach-snapdragon/board.c @@ -36,8 +36,10 @@ #include "qcom-priv.h" DECLARE_GLOBAL_DATA_PTR; +enum qcom_boot_source qcom_boot_source __section(".data") = 0; + static struct mm_region rbx_mem_map[CONFIG_NR_DRAM_BANKS + 2] = { { 0 } }; struct mm_region *mem_map = rbx_mem_map; @@ -237,8 +239,14 @@ int board_fdt_blob_setup(void **fdtp) if (ret < 0) panic("No valid memory ranges found!\n"); + /* If we have an external FDT, it can only have come from the Android bootloader. */ + if (external_valid) + qcom_boot_source = QCOM_BOOT_SOURCE_ANDROID; + else + qcom_boot_source = QCOM_BOOT_SOURCE_XBL; + debug("ram_base = %#011lx, ram_size = %#011llx\n", gd->ram_base, gd->ram_size); if (internal_valid) { @@ -472,8 +480,24 @@ static void configure_env(void) qcom_set_serialno(); } +void qcom_show_boot_source(void) +{ + const char *name = "UNKNOWN"; + + switch (qcom_boot_source) { + case QCOM_BOOT_SOURCE_ANDROID: + name = "ABL"; + break; + case QCOM_BOOT_SOURCE_XBL: + name = "XBL"; + break; + } + + log_info("U-Boot loaded from %s\n", name); +} + void __weak qcom_late_init(void) { } @@ -515,8 +539,9 @@ int board_late_init(void) configure_env(); qcom_late_init(); + qcom_show_boot_source(); /* Configure the dfu_string for capsule updates */ qcom_configure_capsule_updates(); return 0; diff --git a/arch/arm/mach-snapdragon/qcom-priv.h b/arch/arm/mach-snapdragon/qcom-priv.h index 74d39197b89f4e769299b06214c26ee829ecdce0..e5eb4cfbc2b752de799b1407ede69683c81474c1 100644 --- a/arch/arm/mach-snapdragon/qcom-priv.h +++ b/arch/arm/mach-snapdragon/qcom-priv.h @@ -2,8 +2,22 @@ #ifndef __QCOM_PRIV_H__ #define __QCOM_PRIV_H__ +/** + * enum qcom_boot_source - Track where we got loaded from. + * Used for capsule update logic. + * + * @QCOM_BOOT_SOURCE_ANDROID: chainloaded (typically from ABL) + * @QCOM_BOOT_SOURCE_XBL: flashed to the XBL or UEFI partition + */ +enum qcom_boot_source { + QCOM_BOOT_SOURCE_ANDROID = 1, + QCOM_BOOT_SOURCE_XBL, +}; + +extern enum qcom_boot_source qcom_boot_source; + #if IS_ENABLED(CONFIG_EFI_HAVE_CAPSULE_SUPPORT) void qcom_configure_capsule_updates(void); #else void qcom_configure_capsule_updates(void) {} From patchwork Wed Mar 26 17:40:35 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Caleb Connolly X-Patchwork-Id: 876321 Delivered-To: patch@linaro.org Received: by 2002:a5d:5f4c:0:b0:38f:210b:807b with SMTP id cm12csp3301141wrb; Wed, 26 Mar 2025 10:41:12 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCX7x3sKkE1l9WPJH8mx3J6N+8oAikEzTwb1jOGRlcg6RxLzkavE4F052HWMaj6FwP4Lj0lxAQ==@linaro.org X-Google-Smtp-Source: AGHT+IHURWNvLKnxIb5G3DiH/xoFoJ+tj4PBNTsY/HdSwpg4lwh7qPSFdnkRu2K8Tp6vf4wHtZ/d X-Received: by 2002:a67:e716:0:b0:4c1:9cb2:8389 with SMTP id ada2fe7eead31-4c586efe52dmr1314766137.2.1743010872631; Wed, 26 Mar 2025 10:41:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1743010872; cv=none; d=google.com; s=arc-20240605; b=C2nFFT9sV5HVcocFBZIKGC1JxnGt1xy3AuY2NvWBGedCI++k2/W2Vzva18ZIEqz1Ft 2+osclDazwquMmEMdyq0wez1AItgRjoFC2UgnrDK85LDLirrvSacV2F6smlJRf3+vfI8 s8SeaHAtoD+38TpXOoTcidPEKQjfO0MZlwanUxRurGhSrMTENvDu26+UnTBXSzplQlgr vY0+RMEnyYbiaM1C/FMK/oqzgEFBNCamXS1pvKG8+0P8CV3CPjtPiYbRUPQ51DguORHc tWPlY0Jng9X/mCFuQN1HMY3kSrVFh0ACIm8C3GOyAeLN+uc28KgilbQVxDdGS/WoXwXj 4B7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:cc:to:in-reply-to:references :message-id:content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=ikSL2AAWUyJTbVR3jVZtuurYvhIfIe7xlH7DI1JMgb0=; fh=C9WxYFyLAtxCh/j+b9QUILDzba2c5s95xJmEy7wIhfA=; b=DQstCNjNzDJnbTt5AtIstafZrT6EMa65WuRwmPONqJDh7ivIaQDRNX8aNEu/XjE8H1 unzbsP6DgdvX08PWqsEN6mi5uipBVHOO1+IKx0cUr1dkY8iLh1VaqmptAJhJHcnny++g ujxIUcEpbfvQxJUs+NrSftmqSKKJHbqlsZJcgcmZ96kUP+k9ixGMxR9HDi4aNW3F25ln 2DHtdmNyvzOFCxGAEOx/GCKlBpaVCLOuNo/mQtS0A5RbNfsdjufPHoQmyK/uRRPMRxyg z4W3dBrAUT+Dgjp0zRtxgWeY8lS/2TIaM0NQsvrvsYvPPANC1KHzRMtl0AqdD1mPAOrL jrhQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SIeKdj40; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id ada2fe7eead31-4c50bec455bsi2909941137.331.2025.03.26.10.41.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:41:12 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SIeKdj40; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D4FEF81CFD; Wed, 26 Mar 2025 18:40:53 +0100 (CET) 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="SIeKdj40"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id BEC1581DCD; Wed, 26 Mar 2025 18:40:51 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) (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 710F08070C for ; Wed, 26 Mar 2025 18:40:49 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=caleb.connolly@linaro.org Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-43cef035a3bso1030255e9.1 for ; Wed, 26 Mar 2025 10:40:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1743010849; x=1743615649; darn=lists.denx.de; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=ikSL2AAWUyJTbVR3jVZtuurYvhIfIe7xlH7DI1JMgb0=; b=SIeKdj404+kza9fQ0ozGculmhgun3lNrRxMXsRJ34ZUS0vlVJqQyieTDTwupqpBGA6 M0CsfijJqn+GRDPhJ7tmTC5NpD49gqoVewMbctMEoPzf5+ZJlnfqgjgUrSXm5Ryq57Ds JscZX5wDpDxCEhu/VOOJbD6qdrEEJL09a4/+O51KzZM/FDp8TVuEjz/Ok1TdVzDwsRr/ CnrTVXpXDgR5EzmaHVT4avR/Ui0Zy/OWwjuTJ76Sfn4ouAFj9wrBuEq2e8iYxwjfrL09 3dqkY1FKTgdN6bZS8G7hxwYjjrU50n5qhUnzoNumCv+6NU8DVSOCqBt5ig2QVw6kTKie 9BFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743010849; x=1743615649; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ikSL2AAWUyJTbVR3jVZtuurYvhIfIe7xlH7DI1JMgb0=; b=lN4tyo9oLFS6exhhxNNiVLHm0z/o/d8AcWst459Wi5kasbwv02rPxj4yLgkHPfgwD9 KXTjuw8gTZ3KRRMYfQOZgtcJNUzT8SP8gXtW7fGHE9Law9HNmT+yZfDUge9P8B+tCwn+ 00QG6bMyNYNlwnX1rEVLsZoex4P01nTxbG8jWZTlkDCLjKY3tn4qs/Klg5lr7Xau5aUJ J6YQjJtCaQ0Wng4+Qlu1JQtV4nK7SBpTGghNgySq7h4lAdW9LiWEf6V8ghh6s/u5vxUD Yq5WwgSPowCSAG4dvlVVGebcG5jaeMFw0TMV4aeZkMen5p03CvbSeIGOlBoohUNl9kPa tu/w== X-Gm-Message-State: AOJu0Yye46RZVYRMCZlW18+6A//VybQ1CUsroYtcw7SQg+5di7NbfNig IkRxViGpyHzQ9Dm5vIIx1hbyhjSTS0LTVrSD1s3ahC0J8/MjZGKVD1+QPd/TlSM= X-Gm-Gg: ASbGncs2BOmUBMOrQmH0lslWb1pE7iW0PFaXBOrDsmwFU5HT6QNFigf8+FdQCOQigyz iuYn/spPBKxf0ShoRPJkHQ+GUIB84D6+jcW6DZRqdsoLWdTX1XyO7fODQd2wZjVWnni2U+r19KL K4ZMUBnKnlSqFajze66HtCmE4Lg0/m1yOU12F7ApQbSFjlRgup2UqqPfeiPwWalws/nY8dyNu/I 6yZiyUN44n9Aa6xPKCQ77+DbrhQK3mRYZGO0y+QyJc706xhe7lU8kIXiNAeuYaM4lMohgbIS5Ft dOM/BGoUaMkuobYHcEVdE4YYrTw7bFtBql5BN7zJ/7/VXdPgN6YFrcJ4FwDeo3+pM9gXPW3EkOZ qiuAJ8mZr5djo X-Received: by 2002:a05:600c:4f94:b0:43c:eea9:f45d with SMTP id 5b1f17b1804b1-43d850fd6aemr3635095e9.18.1743010848755; Wed, 26 Mar 2025 10:40:48 -0700 (PDT) Received: from toyger.tail248178.ts.net (i5E863BED.versanet.de. [94.134.59.237]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3997f9957d9sm17397321f8f.9.2025.03.26.10.40.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:40:47 -0700 (PDT) From: Caleb Connolly Date: Wed, 26 Mar 2025 18:40:35 +0100 Subject: [PATCH 2/4] mach-snapdragon: CapsuleUpdate: support all boot methods MIME-Version: 1.0 Message-Id: <20250326-b4-qcom-capsule-update-improvements-v1-2-afe2e3696675@linaro.org> References: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> In-Reply-To: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> To: Lukasz Majewski , Mattijs Korpershoek , Tom Rini , Caleb Connolly , Neil Armstrong , Sumit Garg Cc: u-boot@lists.denx.de, u-boot-qcom@groups.io X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=11118; i=caleb.connolly@linaro.org; h=from:subject:message-id; bh=25UcTZsX0d7vrPgsCaRXzdbGe525CzEDJNtuEx8Pw4s=; b=owEBbQKS/ZANAwAKAQWDMSsZX2S2AcsmYgBn5DwbJ2jGe1ZyoltuUfj4c/f6wTvJjrQjgRU/6 jY0RQkDu8OJAjMEAAEKAB0WIQS2UaFGPGq+0GkMVc0FgzErGV9ktgUCZ+Q8GwAKCRAFgzErGV9k tkWoD/9+IhtYF8f7fxWDdGn6W1clCtwl5C+m/LnuHHEXLa6HiXAy2Uu/xQ5MywrSD/tBl8R6dfT HOq2JSGzimRJiXP1TuBAuVjlshoLgFKJCiZRqljSWFEZ3WQCCfs0LfB9UW9zbp+PEalGg1q3fp/ dsaGsfUu+gK4YUWBsFrqMmPIF7UHgU3X50F8/JCQRNJM3Ybn+pvIr6aMb8XsHenUUmwO3LBeOE9 2CD3f/1xj56+7TfKS1PiBxYXJeRiOjxu9aM45tnGx49lHvk0wsF0nVNPH8dTlTokcyIfBl7xsfu od3cZzA2U271CksvpfQrn0ZMwfmuZk17ikGfCDjJM/qPdSsthai31cIQ2twnAz1OpGGDRoGz7ra f7A+DDm2ywXWGFz7li12xb5ceHl9sdiQ04ZukFUE7XLq6HWF8uoF9h4wMFCNVS6luJgScr2x5mI RzC5cSYDpvpKIO7MBHdEiMroEFQf38/8J6MLeRflrGJmSXmotDXZBrZtz7bTF3uLR41b/bLEf1G geobndTKBMzhAQN872xhwdVdcHgteCEI3328oDt8wk/S/ifnDX9/vuSIHgG3cPf1EtcfQrt3qN/ rHSCLl9oWbSjO3FWyGU63Um9/IMH5X6Ewm9uvb4LQO/nT9/v3jGyaeJG61PU92Z67PlhNhlJdWh AywVTxIQoJg/v1g== X-Developer-Key: i=caleb.connolly@linaro.org; a=openpgp; fpr=83B24DA7FE145076BC38BB250CD904EB673A7C47 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.103.8 at phobos.denx.de X-Virus-Status: Clean Expand capsule update support to correctly identify which partition U-Boot is flashed to (between xbl, uefi, and boot including A/B variants). Use qcom_boot_source to determine if we were chainloaded from ABL, meaning U-Boot is on the boot partition, otherwise we assume uefi if it's available, finally leaving the xbl partition. Set a different fw_name based on the target partition to prevent GUID collisions, since a board may support U-Boot flashed to boot or XBL we need to differentiate them since the U-Boot binary must be built differently. Signed-off-by: Caleb Connolly Reviewed-by: Neil Armstrong --- arch/arm/mach-snapdragon/capsule_update.c | 256 +++++++++++++++++++++++------- 1 file changed, 203 insertions(+), 53 deletions(-) diff --git a/arch/arm/mach-snapdragon/capsule_update.c b/arch/arm/mach-snapdragon/capsule_update.c index bf75a9a1b24c714792bae3712b83b96353b1df8f..eedfc40004c06aa6271c685aaca32ccab8f5c491 100644 --- a/arch/arm/mach-snapdragon/capsule_update.c +++ b/arch/arm/mach-snapdragon/capsule_update.c @@ -19,24 +19,21 @@ #include "qcom-priv.h" /* - * NOTE: for now this implementation only supports the rb3gen2. Supporting other - * boards that boot in different ways (e.g. chainloaded from ABL) will require - * additional complexity to properly create the dfu string and fw_images array. - */ - -/* - * To handle different variants like chainloaded U-Boot here we'll need to - * build the fw_images array dynamically at runtime. It looks like - * mach-rockchip is a good example for how to do this. - * Detecting which image types a board uses is TBD, hence for now we only - * support the one new board that runs U-Boot as its primary bootloader. + * To handle different variants like chainloaded U-Boot here we need to + * build the fw_images array dynamically at runtime. These are the possible + * implementations: + * + * - Devices with U-Boot on the uefi_a/b partition + * - Devices with U-Boot on the boot (a/b) partition + * - Devices with U-Boot on the xbl (a/b) partition + * + * Which partition actually has U-Boot on it is determined based on the + * qcom_boot_source variable and additional logic in find_target_partition(). */ struct efi_fw_image fw_images[] = { { - /* U-Boot flashed to the uefi_X partition (e.g. rb3gen2) */ - .fw_name = u"UBOOT_UEFI_PARTITION", .image_index = 1, }, }; @@ -46,8 +43,14 @@ struct efi_capsule_update_info update_info = { .num_images = ARRAY_SIZE(fw_images), .images = fw_images, }; +enum target_part_type { + TARGET_PART_UEFI = 1, + TARGET_PART_XBL, + TARGET_PART_BOOT, +}; + /* LSB first */ struct part_slot_status { u16: 2; u16 active : 1; @@ -56,37 +59,182 @@ struct part_slot_status { u16 unbootable : 1; u16 tries_remaining : 4; }; -static int find_boot_partition(const char *partname, struct blk_desc *blk_dev, char *name) +enum ab_slot { + SLOT_NONE, + SLOT_A, + SLOT_B, +}; + +static enum ab_slot get_part_slot(const char *partname) +{ + int len = strlen(partname); + + if (partname[len - 2] != '_') + return SLOT_NONE; + if (partname[len - 1] == 'a') + return SLOT_A; + if (partname[len - 1] == 'b') + return SLOT_B; + + return SLOT_NONE; +} + +/* + * Determine which partition U-Boot is flashed to based on the boot source (ABL/XBL), + * the slot status, and prioritising the uefi partition over xbl if found. + */ +static int find_target_partition(int *devnum, enum uclass_id *uclass, + enum target_part_type *target_part_type) { int ret; - int partnum; + int partnum, uefi_partnum = -1, xbl_partnum = -1; struct disk_partition info; struct part_slot_status *slot_status; + struct udevice *dev = NULL; + struct blk_desc *desc = NULL, *xbl_desc = NULL; + uchar ptn_name[32] = { 0 }; - for (partnum = 1;; partnum++) { - ret = part_get_info(blk_dev, partnum, &info); - if (ret) - return ret; + uclass_foreach_dev_probe(UCLASS_BLK, dev) { + if (device_get_uclass_id(dev) != UCLASS_BLK) + continue; - slot_status = (struct part_slot_status *)&info.type_flags; - log_io("%16s: Active: %1d, Successful: %1d, Unbootable: %1d, Tries left: %1d\n", - info.name, slot_status->active, - slot_status->successful, slot_status->unbootable, - slot_status->tries_remaining); - /* - * FIXME: eventually we'll want to find the active/inactive variant of the partition - * but on the rb3gen2 these values might all be 0 - */ - if (!strncmp(info.name, partname, strlen(partname))) { - log_debug("Found active %s partition: '%s'!\n", partname, info.name); - strlcpy(name, info.name, sizeof(info.name)); - return partnum; + desc = dev_get_uclass_plat(dev); + if (!desc || desc->part_type == PART_TYPE_UNKNOWN) + continue; + for (partnum = 1;; partnum++) { + ret = part_get_info(desc, partnum, &info); + if (ret) + break; + + slot_status = (struct part_slot_status *)&info.type_flags; + + /* + * Qualcomm Linux devices have a "uefi" partition, it's A/B but the + * flags might not be set so we assume the A partition unless the B + * partition is active. + */ + if (!strncmp(info.name, "uefi", strlen("uefi"))) { + /* + * If U-Boot was chainloaded somehow we can't be flashed to + * the uefi partition + */ + if (qcom_boot_source != QCOM_BOOT_SOURCE_XBL) + continue; + + *target_part_type = TARGET_PART_UEFI; + /* + * Found an active UEFI partition, this is where U-Boot is + * flashed. + */ + if (slot_status->active) + goto found; + + /* Prefer A slot if it's not marked active */ + if (get_part_slot(info.name) == SLOT_A) { + /* + * If we found the A slot after the B slot (both + * inactive) then we assume U-Boot is on the A slot. + */ + if (uefi_partnum >= 0) + goto found; + + /* Didn't find the B slot yet */ + uefi_partnum = partnum; + strlcpy(ptn_name, info.name, 32); + } else { + /* + * Found inactive B slot after inactive A slot, return + * the A slot + */ + if (uefi_partnum >= 0) { + partnum = uefi_partnum; + goto found; + } + + /* + * Didn't find the A slot yet. Record that we found the + * B slot + */ + uefi_partnum = partnum; + strlcpy(ptn_name, info.name, 32); + } + /* xbl and aboot are effectively the same */ + } else if ((!strncmp(info.name, "xbl", strlen("xbl")) && + strlen(info.name) == 5) || + !strncmp(info.name, "aboot", strlen("aboot"))) { + /* + * If U-Boot was booted via ABL, we can't be flashed to the + * XBL partition + */ + if (qcom_boot_source != QCOM_BOOT_SOURCE_XBL) + continue; + + /* + * ignore xbl partition if we have uefi partitions, U-Boot will + * always be on the UEFI partition in this case. + */ + if (*target_part_type == TARGET_PART_UEFI) + continue; + + /* Either non-A/B or find the active XBL partition */ + if (slot_status->active || !get_part_slot(info.name)) { + /* + * No quick return since we might find a uefi partition + * later + */ + xbl_partnum = partnum; + *target_part_type = TARGET_PART_XBL; + xbl_desc = desc; + strlcpy(ptn_name, info.name, 32); + } + + /* + * No fast return since we might also have a uefi partition which + * will take priority. + */ + } else if (!strncmp(info.name, "boot", strlen("boot"))) { + /* We can only be flashed to boot if we were chainloaded */ + if (qcom_boot_source != QCOM_BOOT_SOURCE_ANDROID) + continue; + + /* + * Either non-A/B or find the active partition. We can return + * immediately here since we've narrowed it down to a single option + */ + if (slot_status->active || !get_part_slot(info.name)) { + *target_part_type = TARGET_PART_BOOT; + goto found; + } + } } } + /* + * Now we've exhausted all options, if we didn't find a uefi partition + * then we are indeed flashed to the xbl partition. + */ + if (*target_part_type == TARGET_PART_XBL) { + partnum = xbl_partnum; + desc = xbl_desc; + goto found; + } + + /* Found no candidate partitions */ return -1; + +found: + if (desc) { + *devnum = desc->devnum; + *uclass = desc->uclass_id; + } + + /* info won't match for XBL hence the copy. */ + log_info("Capsule update target: %s (disk %d:%d)\n", + *target_part_type == TARGET_PART_BOOT ? info.name : ptn_name, + *devnum, partnum); + return partnum; } /** * qcom_configure_capsule_updates() - Configure the DFU string for capsule updates @@ -100,14 +248,12 @@ static int find_boot_partition(const char *partname, struct blk_desc *blk_dev, c * in the GPT partition vendor attribute bits. */ void qcom_configure_capsule_updates(void) { - struct blk_desc *desc; int ret = 0, partnum = -1, devnum; static char dfu_string[32] = { 0 }; - char name[32]; /* GPT partition name */ - char *partname = "uefi_a"; - struct udevice *dev = NULL; + enum target_part_type target_part_type = 0; + enum uclass_id dev_uclass; if (IS_ENABLED(CONFIG_SCSI)) { /* Scan for SCSI devices */ ret = scsi_scan(false); @@ -116,38 +262,42 @@ void qcom_configure_capsule_updates(void) return; } } - uclass_foreach_dev_probe(UCLASS_BLK, dev) { - if (device_get_uclass_id(dev) != UCLASS_BLK) - continue; - - desc = dev_get_uclass_plat(dev); - if (!desc || desc->part_type == PART_TYPE_UNKNOWN) - continue; - devnum = desc->devnum; - partnum = find_boot_partition(partname, desc, - name); - if (partnum >= 0) - break; - } - + partnum = find_target_partition(&devnum, &dev_uclass, &target_part_type); if (partnum < 0) { log_err("Failed to find boot partition\n"); return; } - switch (desc->uclass_id) { + /* + * Set the fw_name based on the partition type. This causes the GUID to be different + * so we will never accidentally flash a U-Boot image intended for XBL to the boot + * partition. + */ + switch (target_part_type) { + case TARGET_PART_UEFI: + fw_images[0].fw_name = u"UBOOT_UEFI_PARTITION"; + break; + case TARGET_PART_XBL: + fw_images[0].fw_name = u"UBOOT_XBL_PARTITION"; + break; + case TARGET_PART_BOOT: + fw_images[0].fw_name = u"UBOOT_BOOT_PARTITION"; + break; + } + + switch (dev_uclass) { case UCLASS_SCSI: snprintf(dfu_string, 32, "scsi %d=u-boot.bin part %d", devnum, partnum); break; case UCLASS_MMC: snprintf(dfu_string, 32, "mmc 0=u-boot.bin part %d %d", devnum, partnum); break; default: - debug("Unsupported storage uclass: %d\n", desc->uclass_id); + debug("Unsupported storage uclass: %d\n", dev_uclass); return; } - log_debug("boot partition is %s, DFU string: '%s'\n", name, dfu_string); + log_debug("DFU string: '%s'\n", dfu_string); update_info.dfu_string = dfu_string; } From patchwork Wed Mar 26 17:40:36 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Caleb Connolly X-Patchwork-Id: 876322 Delivered-To: patch@linaro.org Received: by 2002:a5d:5f4c:0:b0:38f:210b:807b with SMTP id cm12csp3301201wrb; Wed, 26 Mar 2025 10:41:21 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWfCtv6x3m4oA/bbE/dYCr3XjWnqOhR8l6Y/s2oWukkT1qGFzEpq7H7uIA7cylHSM5d5fxNcQ==@linaro.org X-Google-Smtp-Source: AGHT+IFw0H764S9gRttgCzsXxZUYQm8VALDTy2TJSku/axpCVs7882Ozp4vfUugmtXy34AhcZAI9 X-Received: by 2002:a05:6122:21a6:b0:516:1ab2:9955 with SMTP id 71dfb90a1353d-52600a1b257mr731106e0c.6.1743010881153; Wed, 26 Mar 2025 10:41:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1743010881; cv=none; d=google.com; s=arc-20240605; b=k6+pZc7UB40qMWdRUREZJwobbYsbcdgoJo1c132AXVVb84rzUdYQ4p56BglQEhW1yC 29YuUFYJEh+mQmWweOis7JcreEkKmRxqW47c7ivFS5QLh37mCNjXCHfJsyY5qO7aW72a MaxM3MGssJN4Rwp2Ib5jaZ09Zo7raIq+yH+J+NAJmCORsAXH0pAgGxVDZJnMLtANJrIv FZevkO+2MJyxErkIxzmKcWnphNPELx0mPv7XJxAHdlfq33Ljg3aE2yCzlJhZWm3t3DHu y48qR1Op+nV/LQE3kfsksU790uXA/pWmdQB0/YdmLmNVloMojrinNwvdKUVBBaFEpKgy /iOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:cc:to:in-reply-to:references :message-id:content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=HhIJRlbTOGLmXyF1Y1ZqzIUvJOx0pvDrHVji5qLs4To=; fh=C9WxYFyLAtxCh/j+b9QUILDzba2c5s95xJmEy7wIhfA=; b=WuLr5w6vHO6eRlz3i3yKLEo+KTAcZ7JK/6lycdwQFYk6h/cZ36pYMZ67XiQ32cms3m pI9sWrYPoc1p0zX8Y/owYGFsR/TE0vjYgSCuEbKVkFcy1vt0BKcY5H8POX6gyea8tA0F CjCcmgs5el8Ez0vW2h/cdHcVrmmL47be5vJndKDsTVSL9SGXif1PjUVnjUER77soOQsa PzJR6OGs7dzXTT/cl/0F140oKwS3T6dtYcGBxfzRP0lUvpZIP9t0mKnCVKOT+p94EpYr bIagHDFnwCdrWrL1YPi35cL/iTUfgjx3ZRjpDwkgdIp4tdmXUMqNwzOuvjB3fQibrxlb S8FA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VfJPC+gk; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id 71dfb90a1353d-525a736bc23si2904597e0c.37.2025.03.26.10.41.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:41:21 -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=VfJPC+gk; 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; dara=neutral header.i=@linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3027281DED; Wed, 26 Mar 2025 18:40:54 +0100 (CET) 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="VfJPC+gk"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id E496181B4B; Wed, 26 Mar 2025 18:40:52 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) (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 E062D81B4B for ; Wed, 26 Mar 2025 18:40:50 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=caleb.connolly@linaro.org Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-43d2d952eb1so989535e9.1 for ; Wed, 26 Mar 2025 10:40:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1743010850; x=1743615650; darn=lists.denx.de; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=HhIJRlbTOGLmXyF1Y1ZqzIUvJOx0pvDrHVji5qLs4To=; b=VfJPC+gk8WANmgWQWPHeMzWtcZtEOWQcWqHNu2mtE6axh8fCKhRivY20o2xUtBtyhv 2ihPlkHtR1mvutmo0gbJ4qDv2dcNC9sTOi6dKYqVhNkvNoYuF+xHVEzn0VWmhmYjoeP5 +RxZeGs+8zCvpv+vlM9pAJiGkvztKAMSC8MaaJzjrt8LO0mNovipwAFMufo/Qceq8bL1 aj821DSSDLQCkcRxT8Vxp9YhvTSeIX6ArI/kQ4py7IDDZiNdJTNNUo8fjTuYrsoVAUv6 l6dDyklukZL3wfU9Lm85mVeJ5Bo5mW5TogJEP2nQVrwsg/sqbH9fyB+f8LMmNMGsGydb GzbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743010850; x=1743615650; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HhIJRlbTOGLmXyF1Y1ZqzIUvJOx0pvDrHVji5qLs4To=; b=cxa11U5STyTEn2wX4qOu7p0pRc1pwCd8+iGTKJ2UilK+VDlvGSbvmemKl3+2AYTmKZ Q5vdrNSgp2uq9NAJzRcrXZhUGfS5+s1TG51+l4x9pkmogDD258U6MTDMEcD2HB37AVXM fi+ZPvaUH9MTFAq0A0y1GhIzubQSsVt9CjiGUXip8bKt1pGwR9Vx1anMhlMYSfq8Eng4 LvGkNc7JpcrrHnnOwGY6HctbfpddfUZ6Sh6Uza8QcPjQ8ajO2PQIBODT88fOdxWO6AwR ataVITthtJ3QpC6wLee/FFVl3VGxPLfrhlhujCx7s43Ol1z5Rr+DrsT5Sd7AU0/h2Nxv h3oA== X-Gm-Message-State: AOJu0Yxm9S/PV/cxua9xdaYGXOlQduXvYLcBhphWLFhQK5JI3/aV6GgC hBbtwHZK6s5r2wunRh/ZCpq5UnAGlrB5eYasL5F40q4Zn/TjNpW/IgQRQ38uVds= X-Gm-Gg: ASbGncto5ZiB+MDbLITgVIifUMA7nWCVzxpvXehKf6kSXXl2OW1Jhy3kE2yfpYy2We3 tcBm7Fli1PwB3nsZ2iE0mKKNdgh/Ib3DjGnDDu8xKY/Lw9pPDATiUJ5UywuLjfZ836BRqMoa0mR sf/cr6xZy47dCyCdJgsL/qWsCtspAjVlVsbu8j6U2xRKxHn3FRBWhmmQwikon5ULod9hUaEfBNc yddT80P6Pwtj8G1ttZi1eiocvMoNH0BYCWf9Uzon7cpyCPbyqSIaumTxloKJ4di7fAvdBigeVBB spFOWRrRHAgeNlk/PQUpmEpEsB4fSMsAI1Pgq/X2o5TGZeGIS/iz88TlmU8wAvBVr+exTg9yVKw VAjfiJt67hnxh X-Received: by 2002:a05:6000:1889:b0:391:39ea:7866 with SMTP id ffacd0b85a97d-39ad174b468mr278951f8f.19.1743010850312; Wed, 26 Mar 2025 10:40:50 -0700 (PDT) Received: from toyger.tail248178.ts.net (i5E863BED.versanet.de. [94.134.59.237]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3997f9957d9sm17397321f8f.9.2025.03.26.10.40.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:40:49 -0700 (PDT) From: Caleb Connolly Date: Wed, 26 Mar 2025 18:40:36 +0100 Subject: [PATCH 3/4] dfu: scsi: don't call scsi_scan() MIME-Version: 1.0 Message-Id: <20250326-b4-qcom-capsule-update-improvements-v1-3-afe2e3696675@linaro.org> References: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> In-Reply-To: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> To: Lukasz Majewski , Mattijs Korpershoek , Tom Rini , Caleb Connolly , Neil Armstrong , Sumit Garg Cc: u-boot@lists.denx.de, u-boot-qcom@groups.io X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1052; i=caleb.connolly@linaro.org; h=from:subject:message-id; bh=XIOsPmy+vaBNCalESw2xbHebuoIH51ML6j82hKWz0Zg=; b=owEBbQKS/ZANAwAKAQWDMSsZX2S2AcsmYgBn5DwbnJux9kmPLtyJNzAyY8/1qMk53cOipJKl+ ZtwO1B9u+aJAjMEAAEKAB0WIQS2UaFGPGq+0GkMVc0FgzErGV9ktgUCZ+Q8GwAKCRAFgzErGV9k thnZD/9J0Q7pzkZI1ZISnCSrtvl/AIUzUgaZPbSJpxEEsWrUsXDvgUYyDE+MUypjchz6WJyQ+Bd cbsn/Syue/6z7du/rNH+CYXrZHMpMfNC+gCscckjmmiSnVCY6A2Wu0OM3Psz4c9VfkKmxIj4hRj 7M/ow7DKXz4APeKjnwPzEmmBNGKx79mMN7rsJtthuWwEUv5LM0tQydXLyymieT1NisFcGMkmi6K sBEGzMyxJXac9m63qMySp2Vgw7+i+l75YMK3TGUd+QQmmsQS0QuJUl6H9+gjiIttd9JhUEy0ag8 oPKRG0/3nqlIeWoW+BSArdODPwQOPm9aSNRYsCDvx2ZAsh8SRaXfFf8qbHRp4NPtUpSJ85j5wOF w523xt/Q3nCqIPbnlRTbIzh+n4vGRse50w6chPTpU/TRK11q7M9yufRnzHXJoQt+kkMG3lySg0E 8K3lYzHGyHIFlobYpj9Y/1O87moGKk5kfl9QCjWtb1IfqibirgVJbTZ8OdfIGv7YpO+Bf93FaLh SjR0+s8GR1LqeW4DrFFIBaUAFAvJkoCKg0ZrkTlUKc+9nEygm4o9noAjW1UoX0+BgeOlFsF7MPb AWBGfwL8cgW5YjzsiJcMAGiR0FFpoczZ9py1FgkVAmKO94wk+phrVS9xkafMxlSrSoE/3HsCPvX tsDNGeQ/Px0ohPg== X-Developer-Key: i=caleb.connolly@linaro.org; a=openpgp; fpr=83B24DA7FE145076BC38BB250CD904EB673A7C47 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.103.8 at phobos.denx.de X-Virus-Status: Clean Calling scsi_scan() results in all the block devices (and EFI block devices) being destroyed and re-created. This breaks the EFI filesystem drivers during capsule update. Remove the call, since boards really should be calling scsi_scan() themselves during board_init(). Signed-off-by: Caleb Connolly Reviewed-by: Neil Armstrong Reviewed-by: Ilias Apalodimas --- drivers/dfu/dfu_scsi.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/dfu/dfu_scsi.c b/drivers/dfu/dfu_scsi.c index 9f95194784c1de00458843276872b1d23d023444..a234548ae46dc2a6ae1ca5770accb58f43782239 100644 --- a/drivers/dfu/dfu_scsi.c +++ b/drivers/dfu/dfu_scsi.c @@ -341,13 +341,8 @@ int dfu_fill_entity_scsi(struct dfu_entity *dfu, char *devstr, char **argv, int if (*s) return -EINVAL; } - if (scsi_scan(false)) { - pr_err("Couldn't init scsi device.\n"); - return -ENODEV; - } - ret = find_scsi_device(dfu->data.scsi.lun, &scsi); if (ret < 0) { pr_err("Couldn't find scsi device no. %d.\n", dfu->data.scsi.lun); return -ENODEV; From patchwork Wed Mar 26 17:40:37 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Caleb Connolly X-Patchwork-Id: 876323 Delivered-To: patch@linaro.org Received: by 2002:a5d:5f4c:0:b0:38f:210b:807b with SMTP id cm12csp3301275wrb; Wed, 26 Mar 2025 10:41:30 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXetKxwQSQZJUcNeXUqQ8iYwbo754LXY5nLWn4/QDX6opOX+8QMZfqVX7HOLxJrwVy9PhWNzA==@linaro.org X-Google-Smtp-Source: AGHT+IESUEwlGEUiCozaY4gSco4d9kc4BkxwEwxhh2nKa9EtRUZ/y83/CZLWyGKlrZuEXs3XsMPi X-Received: by 2002:a05:6122:a04:b0:518:791a:3462 with SMTP id 71dfb90a1353d-52600a99b05mr756974e0c.9.1743010890134; Wed, 26 Mar 2025 10:41:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1743010890; cv=none; d=google.com; s=arc-20240605; b=T9oRCC1PEPBd8iJ2o+/aTOthAPwOhfTAYezwH2zFuhLGD7lmOhxhIpd+D9K0+IiOVr YkueLNXTCqDhco7tnRgYeYLCfVX2QbKOd9Qa/N0YzMi0cGSvcJ31Xb83+M3+yAkyosXU aq8uka0kDv8VsOqci8S4BSudPBupQPIWuFF4OkF+Gwc7NjJDLGxmEtOh7bhcZBDb+5eg To50FCFHFvuF02eZNtT/6XeCGekgQcX6tzP3Lz+v1rWPta9XsWFasBxkO73KlA40HTVu aMjPMdtGpdwGmlApaqJIKmhv0VTkgWNcjNRd2XWrpZCngNhcyFJ0OLHQD2ZyUuQgz+/U pLqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:cc:to:in-reply-to:references :message-id:content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=/M8+IwIFnueosg9Qbss0JZ6cxYxWUWZrlrSkwMiWNEk=; fh=C9WxYFyLAtxCh/j+b9QUILDzba2c5s95xJmEy7wIhfA=; b=Yv15V+BbdusXrK1e79tUCwUB4UNc4a1RLDp8Z1DNgu30MEgJDD1NNWR1gSOVPAiVsC wZAp3qNj95ReWa4f1lZ6WAOIkdE63em0r1t3h+eTV7HEi2BvL4kwFg+yd3smLr7Ao5Rj cwgi6pStdttqgLCYUzk/pd8jjYFwL/fzQ15JvifZb9JX0iGkq9fC74Yrm7ydwn9qmcTq 0+OsTCBsWAGzg3S1Ub2O2La9mK1qCTRSqwQAq0/PYgYZ/4EjAEhvmqlU8xsZiYCAwC4R t684iUFFI5jU+3uPp9GMrZmLrouFJAwF2TjvaiMPXjZu2WVgvLSf1A4Ey75q4SqCyxoH 6n0w==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aXlHLQx+; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id 71dfb90a1353d-525a76a26b5si3101890e0c.239.2025.03.26.10.41.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:41:30 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aXlHLQx+; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 79E2081D4F; Wed, 26 Mar 2025 18:40:57 +0100 (CET) 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="aXlHLQx+"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 536AB81E0F; Wed, 26 Mar 2025 18:40:55 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) (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 68C6D8070C for ; Wed, 26 Mar 2025 18:40:52 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=caleb.connolly@linaro.org Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-43cf3192f3bso1303115e9.1 for ; Wed, 26 Mar 2025 10:40:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1743010852; x=1743615652; darn=lists.denx.de; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=/M8+IwIFnueosg9Qbss0JZ6cxYxWUWZrlrSkwMiWNEk=; b=aXlHLQx+OeHZbi/U0v+7quM1hM6tTThkRt/SM68FL0ixvtsUaGTpR6+n8quxf8cPsg vpEv+EUzsBUfoCwYwlNH+TrGccBJwrzvhS+LgcrJIBDGAf4LJmxOsIw5Gxax6rFouXjy gvzyTqNxsJL/xSOq50UA/pM2kdQL24GxScimTMILzDxUupqD5NQJYF2EbUwPiX4Aegd+ 4rFY5Vr8UAUZCT6Ums46tulxlJIeXXljMq/5EjwUt/acXvTeH6givMQnMlZmWZBUcJuo WCr7RtcN0IQhF8Y3vqfOO5hMOdbLRmvdKR0XxOqrsImRhg++Pr00FuCEllbpIe89KTDV +6yw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743010852; x=1743615652; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/M8+IwIFnueosg9Qbss0JZ6cxYxWUWZrlrSkwMiWNEk=; b=IUvqfMkQeo/OFLvlXwQ3Nq9A6B/f9ZBqjc6BunR4mr9wW8r5hXtikF6lkNdp1xsAxn Jw9vsBC6E8hPW7cRrQbGZpGUuMXYxQwc4BBjRmoD32qh8PLxyTVbjGAXcq6yZSMmRT6e +Iz6jswvqkMdD/yzQalZDF55KDh3wS7TC9gEMJ4et6YIGUb3pOvaG+Uhq1rpqDIk8eVv PM3VcWSkxN7SRymUkb/yIAwkz0eCPFqnXubejhsfuLuFX6E2lpXoXV7WGvj7BYTP8kLa oSr0dPuoOrYrHZcD161E4bpzw47tiK7eZzxvBvdsi5qvRR0zfu2R68tdBw2tiFqaU4Ql /RMQ== X-Gm-Message-State: AOJu0YynXbt8TZLvzo/S5khLh9/MD1vetbstQVi4uIcbxhLLMTOTwsgD kdt7R89YA9k2sj1pF1VCsKJo5qbXai3A8YaCT8tFr266lzYu3aINh7gcf059rHo= X-Gm-Gg: ASbGnctqreFThipJV5Uv0Dzj9qx6hIDaXN3hbNVmlfIguoOaUbx0nQLI8TFLsP48UPw Q6YIF0XoEK7UsbsnanhVJz1zJtUsAdBFyPS+fPn4MQLi3QKhJ9f3r9jRdGrikxYPww1r3yhgn6m Fl87I16c8fLGjuOm8Abr6yfgCt3BKEjMyHgoPa4peOh/LCLa+w+7ndcyPkG4R9UgWKDVMUuhEFM FoTrVZBfY7An5z/FgckiXHVZRPX/3GJgsc8u90/h6kp47Sk3TKfz+V18YhSDbYwcBsXHFx9yYfk A/ZfVveDrGbuwT02Z2Q2zQxFIdJq1TTKnQtzJ1QXzwk4ovhgyi5iLmz0hrM8r+2cs9RbL+IkcAD HFmMPXqva/s/f X-Received: by 2002:a05:600c:3ba1:b0:43c:ef55:f1e8 with SMTP id 5b1f17b1804b1-43d84fb5ffdmr3067505e9.13.1743010851799; Wed, 26 Mar 2025 10:40:51 -0700 (PDT) Received: from toyger.tail248178.ts.net (i5E863BED.versanet.de. [94.134.59.237]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3997f9957d9sm17397321f8f.9.2025.03.26.10.40.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Mar 2025 10:40:50 -0700 (PDT) From: Caleb Connolly Date: Wed, 26 Mar 2025 18:40:37 +0100 Subject: [PATCH 4/4] qcom_defconfig: enable capsule update support MIME-Version: 1.0 Message-Id: <20250326-b4-qcom-capsule-update-improvements-v1-4-afe2e3696675@linaro.org> References: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> In-Reply-To: <20250326-b4-qcom-capsule-update-improvements-v1-0-afe2e3696675@linaro.org> To: Lukasz Majewski , Mattijs Korpershoek , Tom Rini , Caleb Connolly , Neil Armstrong , Sumit Garg Cc: u-boot@lists.denx.de, u-boot-qcom@groups.io X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1543; i=caleb.connolly@linaro.org; h=from:subject:message-id; bh=iiab1HPuYzTXM++3qjgPKtZihNh3fLq1nY5j9vhpGPA=; b=owEBbQKS/ZANAwAKAQWDMSsZX2S2AcsmYgBn5DwcOMLthsyuhyHfx84dwWWuU2LWLI+1UM+Tl HDdE6HBndGJAjMEAAEKAB0WIQS2UaFGPGq+0GkMVc0FgzErGV9ktgUCZ+Q8HAAKCRAFgzErGV9k tki6D/0RhGyaH6QofOVC47F0FRXRWFm5LZdCDD2eFjLTiYY8cbJZ1DUASCQMmioMno7KD7l9tkd lu7eKv3OgOzdHNlg7vajpOE2lAnKzrM3HsCkKB7wWsC+SoLLZN2HVbbPbj1CCFZPhhxMdGUg5AD ox/WDqlOBSakdjLuVJ1Esdh/NEV5AMgBYdhBICxIbW+whN0FiyBf7FcOtX+Ws54VISMzarshqrG jc1tY3ax8GXDKz7Gwe/qXgKpwZy3imh6HQNF0XJl2f8vwkA3aI/Iuh5GS49DVjO1Qbp/iR7HI3C YlzoocECIFOzRIEedFA7EiYc+AeEY5L4DpYQw42qqR5EAqE8DpDdMIP6pBrk74W849lpy5pAWVe KXrEmc4zGJz0ERg4RPCV/F0q37ogG9Iu8ViWdmORKEzEJn4Oav+NFy3NpbkSlbSHTHTA0sc9ml9 DuiCBGXnR/3dVy1Bk2NPDchcZWOtD2ddBysyCxoikqu53rJSgbEW8H0GjQoBSilBy/m45H9fxbg iBq+6ScVBG9oSK80UTZknnzW8Wp/EqIYtc8KTCmG6wuwJsvNvt1h1aCtrXO6mUAUqTS1xxSwHAS i1puxy/HIbleC8BcRXuASrScAo4Z5uEnAZbG7QZmPZQSU+jB0DyzLEIOAtLsh7vtQmtTNxtKxDR +A+wjo/yLXI4uWQ== X-Developer-Key: i=caleb.connolly@linaro.org; a=openpgp; fpr=83B24DA7FE145076BC38BB250CD904EB673A7C47 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.103.8 at phobos.denx.de X-Virus-Status: Clean We can now correctly identify which partition U-Boot is flashed to between uefi, xbl, and boot (including A/B support) so enable capsule update support for all boards. Signed-off-by: Caleb Connolly Reviewed-by: Ilias Apalodimas --- configs/qcm6490_defconfig | 6 ------ configs/qcom_defconfig | 3 +++ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/configs/qcm6490_defconfig b/configs/qcm6490_defconfig index ba26924da161b1c4b5378955185f314b05cb1006..5ddc5ab3ef8cfe8f9cc09eb573c1a8130b394b43 100644 --- a/configs/qcm6490_defconfig +++ b/configs/qcm6490_defconfig @@ -18,10 +18,4 @@ CONFIG_DEBUG_UART_CLOCK=14745600 CONFIG_TEXT_BASE=0x9fc00000 CONFIG_REMAKE_ELF=y CONFIG_DEFAULT_DEVICE_TREE="qcom/qcs6490-rb3gen2" - -# Enable capsule updates -CONFIG_EFI_RUNTIME_UPDATE_CAPSULE=y -CONFIG_EFI_CAPSULE_ON_DISK=y -CONFIG_EFI_IGNORE_OSINDICATIONS=y -CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y diff --git a/configs/qcom_defconfig b/configs/qcom_defconfig index ba4d38d100e053e3708ee2623bf3530787b6b94f..d69185f3c2f0452e6757b785a023cf612bfa3839 100644 --- a/configs/qcom_defconfig +++ b/configs/qcom_defconfig @@ -5,8 +5,11 @@ CONFIG_SYS_INIT_SP_BSS_OFFSET=1572864 CONFIG_ARCH_SNAPDRAGON=y CONFIG_NR_DRAM_BANKS=24 CONFIG_DEFAULT_DEVICE_TREE="qcom/sdm845-db845c" CONFIG_SYS_LOAD_ADDR=0xA0000000 +CONFIG_EFI_RUNTIME_UPDATE_CAPSULE=y +CONFIG_EFI_CAPSULE_ON_DISK=y +CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y CONFIG_BUTTON_CMD=y CONFIG_FIT=y CONFIG_FIT_VERBOSE=y CONFIG_BOOTSTD_FULL=y