[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 8/8] linux: Make load_file2_guid and device_path_guid static
From: |
Nikita Ermakov |
Subject: |
[PATCH 8/8] linux: Make load_file2_guid and device_path_guid static |
Date: |
Fri, 28 May 2021 16:04:57 +0300 |
The load_file2_guid and device_path_guid variables must be preserved
outside of the function scope.
Signed-off-by: Nikita Ermakov <arei@altlinux.org>
---
grub-core/loader/efi/linux.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/grub-core/loader/efi/linux.c b/grub-core/loader/efi/linux.c
index 7c71d0336..8fd8e54e1 100644
--- a/grub-core/loader/efi/linux.c
+++ b/grub-core/loader/efi/linux.c
@@ -51,6 +51,8 @@ static grub_addr_t initrd_end;
static struct grub_linux_initrd_context initrd_ctx = { 0, 0, 0 };
static grub_efi_handle_t initrd_lf2_handle;
static int initrd_use_loadfile2;
+static grub_efi_guid_t load_file2_guid = GRUB_EFI_LOAD_FILE2_PROTOCOL_GUID;
+static grub_efi_guid_t device_path_guid = GRUB_EFI_DEVICE_PATH_GUID;
grub_err_t
grub_arch_efi_linux_check_image (struct linux_arch_kernel_header * lh)
@@ -330,8 +332,6 @@ grub_cmd_initrd (grub_command_t cmd __attribute__
((unused)),
{
int initrd_size, initrd_pages;
void *initrd_mem = NULL;
- grub_efi_guid_t load_file2_guid = GRUB_EFI_LOAD_FILE2_PROTOCOL_GUID;
- grub_efi_guid_t device_path_guid = GRUB_EFI_DEVICE_PATH_GUID;
grub_efi_boot_services_t *b;
grub_efi_status_t status;
--
2.31.1
- [PATCH 0/8] Add LoadFile2 and riscv Linux loader, Nikita Ermakov, 2021/05/28
- [PATCH 1/8] loader/linux: permit NULL argument for argv[] in grub_initrd_load(), Nikita Ermakov, 2021/05/28
- [PATCH 2/8] efi: add definition of LoadFile2 protocol, Nikita Ermakov, 2021/05/28
- [PATCH 3/8] efi: implemented LoadFile2 initrd loading protocol for Linux, Nikita Ermakov, 2021/05/28
- [PATCH 4/8] linux: ignore FDT unless we need to modify it, Nikita Ermakov, 2021/05/28
- [PATCH 8/8] linux: Make load_file2_guid and device_path_guid static,
Nikita Ermakov <=
- [PATCH 6/8] RISC-V: Update image header, Nikita Ermakov, 2021/05/28
- [PATCH 5/8] loader: Move arm64 linux loader to common code, Nikita Ermakov, 2021/05/28
- [PATCH 7/8] RISC-V: Use common linux loader, Nikita Ermakov, 2021/05/28