[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v3] loader/i386/linux.c Correct wrong initrd address for debug

From: Jeremy Szu
Subject: [PATCH v3] loader/i386/linux.c Correct wrong initrd address for debug
Date: Tue, 21 Feb 2023 07:42:51 +0800

The 'addr' is used to request the memory with specific ranges but the
real loadable address come from the relocator.
Thus, print the final retrieved addresses (virtual and physical) for

v2: append SOB

v3: fix wrong code base

Signed-off-by: Jeremy Szu <>
 grub-core/loader/i386/linux.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/grub-core/loader/i386/linux.c b/grub-core/loader/i386/linux.c
index 10a367629..cbe975318 100644
--- a/grub-core/loader/i386/linux.c
+++ b/grub-core/loader/i386/linux.c
@@ -1123,8 +1123,8 @@ grub_cmd_initrd (grub_command_t cmd __attribute__ 
   if (grub_initrd_load (&initrd_ctx, initrd_mem))
     goto fail;
-  grub_dprintf ("linux", "Initrd, addr=0x%x, size=0x%x\n",
-               (unsigned) addr, (unsigned) size);
+  grub_dprintf ("linux", "Initrd (%p) at 0x%" PRIxGRUB_ADDR ", size=0x%x\n",
+               initrd_mem, initrd_mem_target, (unsigned) size);
   linux_params.ramdisk_image = initrd_mem_target;
   linux_params.ramdisk_size = size;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]