Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2216027/?format=api
{ "id": 2216027, "url": "http://patchwork.ozlabs.org/api/patches/2216027/?format=api", "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20260325165431.1027591-4-sjg@chromium.org/", "project": { "id": 18, "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api", "name": "U-Boot", "link_name": "uboot", "list_id": "u-boot.lists.denx.de", "list_email": "u-boot@lists.denx.de", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260325165431.1027591-4-sjg@chromium.org>", "list_archive_url": null, "date": "2026-03-25T16:54:12", "name": "[03/13] boot: Tidy up setting of the OS arch on host builds", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "ceae88fc077b88ac8d356abbf65bc2d9864539af", "submitter": { "id": 6170, "url": "http://patchwork.ozlabs.org/api/people/6170/?format=api", "name": "Simon Glass", "email": "sjg@chromium.org" }, "delegate": { "id": 3651, "url": "http://patchwork.ozlabs.org/api/users/3651/?format=api", "username": "trini", "first_name": "Tom", "last_name": "Rini", "email": "trini@ti.com" }, "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20260325165431.1027591-4-sjg@chromium.org/mbox/", "series": [ { "id": 497475, "url": "http://patchwork.ozlabs.org/api/series/497475/?format=api", "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=497475", "date": "2026-03-25T16:54:09", "name": "boot: Make fit_image_load() easier to maintain", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/497475/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2216027/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2216027/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<u-boot-bounces@lists.denx.de>", "X-Original-To": "incoming@patchwork.ozlabs.org", "Delivered-To": "patchwork-incoming@legolas.ozlabs.org", "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256\n header.s=google header.b=HoHFEnRU;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de\n (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de;\n envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org)", "phobos.denx.de;\n dmarc=pass (p=none dis=none) header.from=chromium.org", "phobos.denx.de;\n spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de", "phobos.denx.de;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=chromium.org header.i=@chromium.org\n header.b=\"HoHFEnRU\";\n\tdkim-atps=neutral", "phobos.denx.de;\n dmarc=pass (p=none dis=none) header.from=chromium.org", "phobos.denx.de;\n spf=pass smtp.mailfrom=sjg@chromium.org" ], "Received": [ "from phobos.denx.de (phobos.denx.de\n [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fgtMj6LWVz1y1K\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 26 Mar 2026 03:56:01 +1100 (AEDT)", "from h2850616.stratoserver.net (localhost [IPv6:::1])\n\tby phobos.denx.de (Postfix) with ESMTP id 7B71683FAF;\n\tWed, 25 Mar 2026 17:55:44 +0100 (CET)", "by phobos.denx.de (Postfix, from userid 109)\n id 14E7783FA7; Wed, 25 Mar 2026 17:55:41 +0100 (CET)", "from mail-oi1-x233.google.com (mail-oi1-x233.google.com\n [IPv6:2607:f8b0:4864:20::233])\n (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits))\n (No client certificate requested)\n by phobos.denx.de (Postfix) with ESMTPS id 2968D83DA7\n for <u-boot@lists.denx.de>; Wed, 25 Mar 2026 17:55:38 +0100 (CET)", "by mail-oi1-x233.google.com with SMTP id\n 5614622812f47-4670676ba03so3896b6e.1\n for <u-boot@lists.denx.de>; Wed, 25 Mar 2026 09:55:38 -0700 (PDT)", "from chromium.org ([73.34.74.121]) by smtp.gmail.com with ESMTPSA id\n 5614622812f47-46a7099df08sm30481b6e.15.2026.03.25.09.55.33\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Wed, 25 Mar 2026 09:55:35 -0700 (PDT)" ], "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,DKIMWL_WL_HIGH,\n DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,\n RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS autolearn=ham\n autolearn_force=no version=3.4.2", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=chromium.org; s=google; t=1774457736; x=1775062536; darn=lists.denx.de;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=3yWK6QnTYyx0w4CUHe2N6NQim35RSGM+xbaUhc0YDpw=;\n b=HoHFEnRUOfJPtswzwxQOnzqJYiEMNCiO619WC7Gr4p+AK6mzSoZknPrzHuE19z4CR/\n Q1gywAngCvmP+yDGJy/gssxoPh92ns/wJ/5uifK+vQIRxgvZwbTU+P9XEnsAzVfAe+Yc\n wKPMKvbtaltIFsh9zvOTBcNXQ9pyRxA/4XHJo=", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1774457736; x=1775062536;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=3yW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808:5245:b0:466:f57b:2aca with SMTP id\n 5614622812f47-46a5c78457amr1934271b6e.50.1774457735995;\n Wed, 25 Mar 2026 09:55:35 -0700 (PDT)", "From": "Simon Glass <sjg@chromium.org>", "To": "u-boot@lists.denx.de", "Cc": "Simon Glass <sjg@chromium.org>,\n James Hilliard <james.hilliard1@gmail.com>,\n Jonas Karlman <jonas@kwiboo.se>,\n Marek Vasut <marek.vasut+renesas@mailbox.org>,\n Mayuresh Chitale <mchitale@ventanamicro.com>,\n Neil Armstrong <neil.armstrong@linaro.org>,\n Quentin Schulz <quentin.schulz@cherry.de>,\n Shiji Yang <yangshiji66@outlook.com>, Tom Rini <trini@konsulko.com>,\n Wolfgang Wallner <wolfgang.wallner@at.abb.com>", "Subject": "[PATCH 03/13] boot: Tidy up setting of the OS arch on host builds", "Date": "Wed, 25 Mar 2026 10:54:12 -0600", "Message-ID": "<20260325165431.1027591-4-sjg@chromium.org>", "X-Mailer": "git-send-email 2.43.0", "In-Reply-To": "<20260325165431.1027591-1-sjg@chromium.org>", "References": "<20260325165431.1027591-1-sjg@chromium.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-BeenThere": "u-boot@lists.denx.de", "X-Mailman-Version": "2.1.39", "Precedence": "list", "List-Id": "U-Boot discussion <u-boot.lists.denx.de>", "List-Unsubscribe": "<https://lists.denx.de/options/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=unsubscribe>", "List-Archive": "<https://lists.denx.de/pipermail/u-boot/>", "List-Post": "<mailto:u-boot@lists.denx.de>", "List-Help": "<mailto:u-boot-request@lists.denx.de?subject=help>", "List-Subscribe": "<https://lists.denx.de/listinfo/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=subscribe>", "Errors-To": "u-boot-bounces@lists.denx.de", "Sender": "\"U-Boot\" <u-boot-bounces@lists.denx.de>", "X-Virus-Scanned": "clamav-milter 0.103.8 at phobos.denx.de", "X-Virus-Status": "Clean" }, "content": "This field is not present in host builds. Create an inline function to\nhandle this complexity, so we can drop the #ifdef in the C file.\n\nSigned-off-by: Simon Glass <sjg@chromium.org>\n---\n\n boot/image-fit.c | 10 ++--------\n include/image.h | 7 +++++++\n 2 files changed, 9 insertions(+), 8 deletions(-)", "diff": "diff --git a/boot/image-fit.c b/boot/image-fit.c\nindex f8772f64cb3..5680cc8b496 100644\n--- a/boot/image-fit.c\n+++ b/boot/image-fit.c\n@@ -2193,7 +2193,7 @@ int fit_image_load(struct bootm_headers *images, ulong addr,\n \tsize_t size;\n \tint type_ok, os_ok;\n \tulong load, load_end, data, len;\n-\tuint8_t os, comp;\n+\tuint8_t os, comp, os_arch;\n \tconst char *prop_name;\n \n \tfit = map_sysmem(addr, 0);\n@@ -2218,14 +2218,8 @@ int fit_image_load(struct bootm_headers *images, ulong addr,\n \t\t}\n \t}\n \n-#ifndef USE_HOSTCC\n-\t{\n-\tuint8_t os_arch;\n-\n \tfit_image_get_arch(fit, noffset, &os_arch);\n-\timages->os.arch = os_arch;\n-\t}\n-#endif\n+\timages_set_arch(images, os_arch);\n \n \tbootstage_mark(bootstage_id + BOOTSTAGE_SUB_CHECK_ALL);\n \ttype_ok = fit_image_check_type(fit, noffset, image_type) ||\ndiff --git a/include/image.h b/include/image.h\nindex 34efac6056d..5e11dc92559 100644\n--- a/include/image.h\n+++ b/include/image.h\n@@ -418,6 +418,13 @@ struct bootm_headers {\n \n extern struct bootm_headers images;\n \n+static inline void images_set_arch(struct bootm_headers *images, int os_arch)\n+{\n+#ifndef USE_HOSTCC\n+\timages->os.arch = os_arch;\n+#endif\n+}\n+\n /*\n * Some systems (for example LWMON) have very short watchdog periods;\n * we must make sure to split long operations like memmove() or\n", "prefixes": [ "03/13" ] }