From patchwork Wed Aug 20 11:23:22 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 66 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755689064; bh=m8DlLqe/iyfD3wp42KwqdG0DxXLpXITVS0Mxb8fC/fs=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=ULTpJrrLPAP9QLAvcpJtgsKaUERGqpEoTvOE33664O/h/90+lpaAC3WuOcbTRqGUo pBJjmklyHNxC86D2t10tNu1ci8+ZLR/pE+KWi9HxwIzFJr6AmafgXfZ6lLdI/pQVl7 H01MSN2n8/OKhvuDv4wwc5B6r4MBH68yUXKqiLgaUD6KiA6DU3fZi05OGv5XY1uEDY Hd18PGSjBmYh4a3Ni3g7eNVGHi+LijkChvBuCGqfb2Wq7RR8/ZklsbU4iI5H8ntOoE 8gRD8e3paiWQd6St2Kx6q70Ogi3AwP9S/KfDq2xNlWm4PeiIs3TbdjU08vrmlAT0Ht nmrEp+KNahxqA== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id B00FA67680 for ; Wed, 20 Aug 2025 05:24:24 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id niRgGaW6j9Bq for ; Wed, 20 Aug 2025 05:24:24 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755689060; bh=m8DlLqe/iyfD3wp42KwqdG0DxXLpXITVS0Mxb8fC/fs=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=R1BkTOhkBDKl//nTaf5kuurQJAuT3KJbt5ISU6ZPhfU8S/E3Gj/sxCEph1EuOyB+t 6ak8AwKFKcIDzkLU71aMxn7UujM0gVpFyOCh4TNIkwByfqQNPERUCQHOaT87hcnzy3 xa+0D0H5O2dJQyvp3SqgL6QApx/d8nJ8vXO3hKsyHRz7zpbFlAhLuU45M9NMWvQ4jW y+EuX2hevQgxRShmDBJhjrNl49DJgt8PFWjdjcopUZx+iQ7DCD/xfRq1CgLjYD6H7s 1SBYyQxnvCuMDfdL7EdHz6hzP7KoPpwmM8hsFFahBsqKFeZqWodnKaiP2r1Re8RmCv +gjm4oudY92kw== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id C66ED674B4 for ; Wed, 20 Aug 2025 05:24:20 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755689058; bh=BO3kcWejZsS5MlrOfQb6frqsrwQu7d4+yuxoyEZk3ws=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=JJgVNYxN0Rz5wAjpbDcL86okiEZGOGcufTbtDuzenvaKzflewStw4wEOj6+0B4IYb R1dRcJ8D0k3UVcIzgfC/4H3b7hxwr+EQ2/n0pZkN2N6DnvisNuK1zlX9AQRWLvk+3Q O2O2HU/kIS3IcXPwbzfCCa/7DXYmL/YRMubrS6YHzm7SgXDa2/AQXnHyPYMCfc96cJ 7iAz7ZRtOoMZnDVaxMXnx5M8FaOt+Ucrxr0pF9Vl+7glF2Ft+aCqp3bn9vY3twXzIT tvW0ObopJJVhW5Q+lKlJrxSqgieXjEh6FYv+9z2vqZmuseudpYar7e000ZRkFjcuEW JZZWv7Jyan9mg== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id BACCA67692; Wed, 20 Aug 2025 05:24:18 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id kI5VnucqNBdT; Wed, 20 Aug 2025 05:24:18 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755689053; bh=VT0fZRKhY1MVrfSyJU42TG6wzOXcWcYiiM+L82X8Ybg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pUeOy1f9jqZ0D5APE7ivGYuftStkOB9xkVIDMbg2uexAq27aiNERcHgxav8rp5erS Y8z5RtesXjielL7CePg5H9QObOSm5jmUx+TCjRIh63X6EAQQgpe5pYwtXcV9YA8mWD aQkhywhqAV7MgJNRUKLeB+pqqxjPWNUpD6F19DFtdETAWORq8MChKIuQP55CtLyxI8 jW3STO0ReqltzbQEYKl/iKOFLCS2EYO8wOvm4x+cCyuoFdnuje6XqdDQiDRndxc/XQ NPO3tT0hNxI4iRDKT6bpFBkZVEI0xoaYoD69e48niI6UU9ZIdkGZ0lACuSFbMMenKV 77NsbheWfT3AA== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 3927D674B4; Wed, 20 Aug 2025 05:24:13 -0600 (MDT) From: Simon Glass To: U-Boot Concept Date: Wed, 20 Aug 2025 05:23:22 -0600 Message-ID: <20250820112340.147082-11-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250820112340.147082-1-sjg@u-boot.org> References: <20250820112340.147082-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: 2FAZQ2A7B5RDE4CQ7WWHRE2TBXCW6SXN X-Message-ID-Hash: 2FAZQ2A7B5RDE4CQ7WWHRE2TBXCW6SXN X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Heinrich Schuchardt , Simon Glass X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH v2 10/18] efi: Move FDT and global-variable GUIDs to common files List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass The global-variable GUID is already set in the common device_path.c file but its declaration is only in the efi_loader header. Move it and also move over the FDT GUIDs. Signed-off-by: Simon Glass --- (no changes since v1) include/efi.h | 3 +++ include/efi_loader.h | 3 --- lib/efi/device_path.c | 2 ++ lib/efi_loader/efi_boottime.c | 2 -- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/efi.h b/include/efi.h index 742c40bfd8c..ed22ff9a5a4 100644 --- a/include/efi.h +++ b/include/efi.h @@ -152,6 +152,9 @@ typedef struct efi_object *efi_handle_t; (c) & 0xff, ((c) >> 8) & 0xff, \ (d0), (d1), (d2), (d3), (d4), (d5), (d6), (d7) } } +extern const efi_guid_t efi_global_variable_guid; +extern const efi_guid_t efi_guid_fdt; + /* Generic EFI table header */ struct efi_table_hdr { u64 signature; diff --git a/include/efi_loader.h b/include/efi_loader.h index b57196da8da..c4d9c4f1c7c 100644 --- a/include/efi_loader.h +++ b/include/efi_loader.h @@ -317,7 +317,6 @@ extern const efi_guid_t efi_guid_host_dev; extern const efi_guid_t efi_block_io_guid; /* GUID of the EFI_SIMPLE_NETWORK_PROTOCOL */ extern const efi_guid_t efi_net_guid; -extern const efi_guid_t efi_global_variable_guid; extern const efi_guid_t efi_guid_console_control; extern const efi_guid_t efi_guid_device_path; /* GUID of the EFI system partition */ @@ -336,8 +335,6 @@ extern const efi_guid_t efi_guid_event_group_ready_to_boot; extern const efi_guid_t efi_guid_event_group_reset_system; /* event group return to efibootmgr */ extern const efi_guid_t efi_guid_event_group_return_to_efibootmgr; -/* GUID of the device tree table */ -extern const efi_guid_t efi_guid_fdt; extern const efi_guid_t efi_guid_loaded_image; extern const efi_guid_t efi_guid_loaded_image_device_path; extern const efi_guid_t efi_guid_device_path_to_text_protocol; diff --git a/lib/efi/device_path.c b/lib/efi/device_path.c index fb6653b23a3..db5a686ccb2 100644 --- a/lib/efi/device_path.c +++ b/lib/efi/device_path.c @@ -32,6 +32,8 @@ const efi_guid_t efi_simple_file_system_protocol_guid = EFI_SIMPLE_FILE_SYSTEM_PROTOCOL_GUID; const efi_guid_t efi_file_info_guid = EFI_FILE_INFO_GUID; const efi_guid_t efi_u_boot_guid = U_BOOT_GUID; +/* GUID of the device tree table */ +const efi_guid_t efi_guid_fdt = EFI_FDT_GUID; /* template EFI_DP_END node: */ const struct efi_device_path EFI_DP_END = { diff --git a/lib/efi_loader/efi_boottime.c b/lib/efi_loader/efi_boottime.c index 8ba42ec4544..0f9a654ca03 100644 --- a/lib/efi_loader/efi_boottime.c +++ b/lib/efi_loader/efi_boottime.c @@ -68,8 +68,6 @@ efi_status_t efi_uninstall_protocol /* 1 if inside U-Boot code, 0 if inside EFI payload code */ static int entry_count = 1; static int nesting_level; -/* GUID of the device tree table */ -const efi_guid_t efi_guid_fdt = EFI_FDT_GUID; /* GUID of the EFI_DRIVER_BINDING_PROTOCOL */ const efi_guid_t efi_guid_driver_binding_protocol = EFI_DRIVER_BINDING_PROTOCOL_GUID;