Skip to content

Commit

Permalink
cmdline: display kernel cmdline after it is parsed
Browse files Browse the repository at this point in the history
Signed-off-by: Pawel Wieczorkiewicz <[email protected]>
  • Loading branch information
wipawel committed Jan 25, 2022
1 parent 985ec8e commit 3320f50
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 1 addition & 4 deletions common/kernel.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,7 @@ static void __noreturn echo_loop(void) {
}

void kernel_main(void) {
printk("\nKTF - Kernel Test Framework!\n\n");

if (kernel_cmdline)
printk("Command line: %s\n", kernel_cmdline);
printk("\nKTF - Kernel Test Framework!\n");

zap_boot_mappings();
if (opt_debug) {
Expand Down
2 changes: 2 additions & 0 deletions common/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,8 @@ void __noreturn __text_init kernel_start(uint32_t multiboot_magic,

/* Parse commandline parameters */
cmdline_parse(kernel_cmdline);
if (!string_empty(kernel_cmdline))
printk("Command line: %s\n", kernel_cmdline);

/* Initialize console early */
init_console();
Expand Down

0 comments on commit 3320f50

Please sign in to comment.