loader: Drop argv[] argument in grub_initrd_load()

In the case of an error grub_initrd_load() uses argv[] to print the
filename that caused the error. It is also possible to obtain the
filename from the file handles and there is no need to duplicate that
information in argv[], so let's drop it.

Signed-off-by: Nikita Ermakov <arei@altlinux.org>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
Nikita Ermakov authored and Daniel Kiper committed 2022-08-19 23:55:49 +02:00
1 parent 8df6e1c067
commit 5730424cb9
11 files changed
+12 -13

No files matched your search

+1 -1
View File
@@ -413,7 +413,7 @@ grub_cmd_initrd (grub_command_t cmd __attribute__ ((unused)),
grub_dprintf ("loader", "Loading initrd at vaddr 0x%lx, paddr 0x%lx, size 0x%lx\n",
addr, paddr, size);
if (grub_initrd_load (&initrd_ctx, argv, (void *) addr))
if (grub_initrd_load (&initrd_ctx, (void *) addr))
goto fail;
initrd_addr = addr;