app/aboot: print the complete cmd line being passed to kernel
Cmd line options that lk adds are not printed. Updated code
to print the complete cmd line.
Change-Id: I605fda626a6ff3d2b1def3c3434323de66cdf19d
diff --git a/app/aboot/aboot.c b/app/aboot/aboot.c
index 7c8f78b..10aac46 100644
--- a/app/aboot/aboot.c
+++ b/app/aboot/aboot.c
@@ -136,6 +136,7 @@
int cmdline_len = 0;
int have_cmdline = 0;
int pause_at_bootup = 0;
+ unsigned char *cmdline_final = NULL;
/* CORE */
*ptr++ = 2;
@@ -215,6 +216,8 @@
*ptr++ = (n / 4) + 2;
*ptr++ = 0x54410009;
dst = (char *)ptr;
+ /* Save start ptr for debug print */
+ cmdline_final = (char *)ptr;
if (have_cmdline) {
src = cmdline;
while ((*dst++ = *src++));
@@ -288,8 +291,8 @@
dprintf(INFO, "booting linux @ %p, ramdisk @ %p (%d)\n",
kernel, ramdisk, ramdisk_size);
- if (cmdline)
- dprintf(INFO, "cmdline: %s\n", cmdline);
+ if (cmdline_final)
+ dprintf(INFO, "cmdline: %s\n", cmdline_final);
enter_critical_section();
/* do any platform specific cleanup before kernel entry */