]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
efi_loader: rename struct efi_initrd_dp to efi_lo_dp_prefix
authorHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Mon, 10 Jun 2024 08:00:01 +0000 (10:00 +0200)
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Mon, 10 Jun 2024 09:43:37 +0000 (11:43 +0200)
As we now also store device-tree device-paths in load options rename
struct efi_initrd_dp to efi_lo_dp_prefix.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
cmd/eficonfig.c
cmd/efidebug.c
include/efi_load_initrd.h
lib/efi_loader/efi_load_initrd.c
lib/efi_loader/initrddump.c

index 6108b4243ac43d55fcb77dcaa718c132b20d6ea2..bea09e4ecc7620f0caac55fc22955bb0afda5a72 100644 (file)
@@ -1401,7 +1401,7 @@ static efi_status_t eficonfig_edit_boot_option(u16 *varname, struct eficonfig_bo
        struct efi_device_path *initrd_device_dp = NULL;
        struct efi_device_path *fdt_device_dp = NULL;
 
-       const struct efi_initrd_dp initrd_prefix = {
+       const struct efi_lo_dp_prefix initrd_prefix = {
                .vendor = {
                        {
                        DEVICE_PATH_TYPE_MEDIA_DEVICE,
@@ -1417,7 +1417,7 @@ static efi_status_t eficonfig_edit_boot_option(u16 *varname, struct eficonfig_bo
                }
        };
 
-       const struct efi_initrd_dp fdt_prefix = {
+       const struct efi_lo_dp_prefix fdt_prefix = {
                .vendor = {
                        {
                        DEVICE_PATH_TYPE_MEDIA_DEVICE,
index 083059106fd2c9f2dddec074c7e095d01f19c879..1a191eb999414ab15029e23ba16c74f7d8e1cdb8 100644 (file)
@@ -684,7 +684,7 @@ struct efi_device_path *create_lo_dp_part(const char *dev, const char *part,
        struct efi_device_path *dp = NULL;
        const struct efi_device_path *dp_prefix;
        efi_status_t ret;
-       const struct efi_initrd_dp fdt_dp = {
+       const struct efi_lo_dp_prefix fdt_dp = {
                .vendor = {
                        {
                        DEVICE_PATH_TYPE_MEDIA_DEVICE,
@@ -699,7 +699,7 @@ struct efi_device_path *create_lo_dp_part(const char *dev, const char *part,
                        sizeof(fdt_dp.end),
                }
        };
-       const struct efi_initrd_dp initrd_dp = {
+       const struct efi_lo_dp_prefix initrd_dp = {
                .vendor = {
                        {
                        DEVICE_PATH_TYPE_MEDIA_DEVICE,
index be5d5a7acbe07db110e20cd5eeeec5272080942b..9feafb18c8686fa574e4adbe419004d9fd27952f 100644 (file)
                 0xac, 0x74, 0xca, 0x55, 0x52, 0x31, 0xcc, 0x68)
 extern const efi_guid_t efi_lf2_initrd_guid;
 
-struct efi_initrd_dp {
+/**
+ * struct efi_lo_dp_prefix - separator device path used in load options
+ *
+ * We use vendor media device nodes in UEFI load options to separate
+ * the binary, initrd, and fdt device-paths. This structure contains
+ * the vendor media device node and an end node.
+ *
+ * @vendor:    vendor media device node
+ * @end:       end node
+ */
+struct efi_lo_dp_prefix {
        struct efi_device_path_vendor vendor;
        struct efi_device_path end;
 } __packed;
index d91135436c42920a4c854efa5a6b758f7ad53f2c..23508431c833e7b7d7b7ae1c61d94d5a8c53f9f6 100644 (file)
@@ -24,7 +24,7 @@ static const struct efi_load_file_protocol efi_lf2_protocol = {
  * Device path defined by Linux to identify the handle providing the
  * EFI_LOAD_FILE2_PROTOCOL used for loading the initial ramdisk.
  */
-static const struct efi_initrd_dp dp_lf2_handle = {
+static const struct efi_lo_dp_prefix dp_lf2_handle = {
        .vendor = {
                {
                   DEVICE_PATH_TYPE_MEDIA_DEVICE,
index 0004b6b042b477555eb13bd54c1e80ab9a7aee42..615119043d1561bde4cb33837de24928de8503f1 100644 (file)
@@ -33,7 +33,7 @@ static bool nocolor;
  * Device path defined by Linux to identify the handle providing the
  * EFI_LOAD_FILE2_PROTOCOL used for loading the initial ramdisk.
  */
-static const struct efi_initrd_dp initrd_dp = {
+static const struct efi_lo_dp_prefix initrd_dp = {
        .vendor = {
                {
                   DEVICE_PATH_TYPE_MEDIA_DEVICE,