Skip to content

Commit 1bc5434

Browse files
committed
parisc: Fix inconsistent indenting in setup_cmdline()
Fix warning reported by 0-DAY CI Kernel Test Service: arch/parisc/kernel/setup.c:64 setup_cmdline() warn: inconsistent indenting Reported-by: kernel test robot <[email protected]> Signed-off-by: Helge Deller <[email protected]>
1 parent 830b3c6 commit 1bc5434

File tree

1 file changed

+12
-14
lines changed

1 file changed

+12
-14
lines changed

arch/parisc/kernel/setup.c

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,15 @@ void __init setup_cmdline(char **cmdline_p)
5050
extern unsigned int boot_args[];
5151
char *p;
5252

53-
/* Collect stuff passed in from the boot loader */
53+
*cmdline_p = command_line;
5454

5555
/* boot_args[0] is free-mem start, boot_args[1] is ptr to command line */
56-
if (boot_args[0] < 64) {
57-
/* called from hpux boot loader */
58-
boot_command_line[0] = '\0';
59-
} else {
60-
strscpy(boot_command_line, (char *)__va(boot_args[1]),
61-
COMMAND_LINE_SIZE);
56+
if (boot_args[0] < 64)
57+
return; /* return if called from hpux boot loader */
58+
59+
/* Collect stuff passed in from the boot loader */
60+
strscpy(boot_command_line, (char *)__va(boot_args[1]),
61+
COMMAND_LINE_SIZE);
6262

6363
/* autodetect console type (if not done by palo yet) */
6464
p = boot_command_line;
@@ -75,16 +75,14 @@ void __init setup_cmdline(char **cmdline_p)
7575
strlcat(p, " earlycon=pdc", COMMAND_LINE_SIZE);
7676

7777
#ifdef CONFIG_BLK_DEV_INITRD
78-
if (boot_args[2] != 0) /* did palo pass us a ramdisk? */
79-
{
80-
initrd_start = (unsigned long)__va(boot_args[2]);
81-
initrd_end = (unsigned long)__va(boot_args[3]);
82-
}
83-
#endif
78+
/* did palo pass us a ramdisk? */
79+
if (boot_args[2] != 0) {
80+
initrd_start = (unsigned long)__va(boot_args[2]);
81+
initrd_end = (unsigned long)__va(boot_args[3]);
8482
}
83+
#endif
8584

8685
strscpy(command_line, boot_command_line, COMMAND_LINE_SIZE);
87-
*cmdline_p = command_line;
8886
}
8987

9088
#ifdef CONFIG_PA11

0 commit comments

Comments
 (0)