summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2023-05-30 14:14:11 +0200
committerHelge Deller <deller@gmx.de>2023-05-30 14:14:11 +0200
commit8fdb86a63ba572f90941a09da396b77f1efe4a87 (patch)
treec0d15604b9c6a9253456670a34691b3c295855ae
parentbc76f1206e3bde230450e7a6fd04f88ee15687d0 (diff)
downloadpalo-8fdb86a63ba572f90941a09da396b77f1efe4a87.tar.gz
ipl: Fix debug option and initialize ok variable
The debug option lost the commandline, and initialize the "ok" variable to fix ramddisk loading. Signed-off-by: Helge Deller <deller@gmx.de>
-rw-r--r--ipl/ipl.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/ipl/ipl.c b/ipl/ipl.c
index f6fe251..bea8ed9 100644
--- a/ipl/ipl.c
+++ b/ipl/ipl.c
@@ -443,15 +443,18 @@ interact(int *ok)
/* turn on firmware manufacturing mode on C8000 workstation */
if (numbuf[0] == 'm') { /* hidden option! */
const char *model = get_machine_model();
+ join(commandline, argc, argv, ok);
if (strncmp(model, "9000/785/C8000", 14) == 0) {
*(unsigned char *)0xfffffff0f04300a0 = 0x4d;
pdc_do_reset();
}
printf("unknown machine - can not enable manufacturing mode\n");
+ continue;
}
if (numbuf[0] == 'd') /* hidden option! */
{
+ join(commandline, argc, argv, ok);
Debug = !Debug;
printf("Debug mode is now %s\n", Debug ? "on":"off");
if (Debug)
@@ -693,9 +696,14 @@ iplmain(int is_interactive, char *initialstackptr, int started_wide)
/* If we have any failures after this, be sure we're interactive
* for the re-start */
interactive = 1;
+ ok = 1;
+ if (Debug) printf("commandline %s\n", commandline);
strcpy(commandline,
parse(commandline, &kern_part, kern_name, &rd_part, rd_name));
+ if (Debug) printf("commandline %s\n", commandline);
+ if (Debug) printf("kernel %s part %d\n", kern_name, kern_part);
+ if (Debug) printf("rd %s part %d\n", rd_name, rd_part);
sprintf(kern_fullname, "%d%s", kern_part, kern_name);
chk_strcat(commandline, " palo_kernel=", CMDLINELEN, &ok);