diff options
-rw-r--r-- | arch/s390/kernel/early.c | 13 | ||||
-rw-r--r-- | arch/s390/kernel/head.S | 18 |
2 files changed, 13 insertions, 18 deletions
diff --git a/arch/s390/kernel/early.c b/arch/s390/kernel/early.c index 02e45861b55b..31d618a443af 100644 --- a/arch/s390/kernel/early.c +++ b/arch/s390/kernel/early.c | |||
@@ -405,8 +405,19 @@ static void __init append_to_cmdline(size_t (*ipl_data)(char *, size_t)) | |||
405 | 405 | ||
406 | static void __init setup_boot_command_line(void) | 406 | static void __init setup_boot_command_line(void) |
407 | { | 407 | { |
408 | int i; | ||
409 | |||
410 | /* convert arch command line to ascii */ | ||
411 | for (i = 0; i < ARCH_COMMAND_LINE_SIZE; i++) | ||
412 | if (COMMAND_LINE[i] & 0x80) | ||
413 | break; | ||
414 | if (i < ARCH_COMMAND_LINE_SIZE) | ||
415 | EBCASC(COMMAND_LINE, ARCH_COMMAND_LINE_SIZE); | ||
416 | COMMAND_LINE[ARCH_COMMAND_LINE_SIZE-1] = 0; | ||
417 | |||
408 | /* copy arch command line */ | 418 | /* copy arch command line */ |
409 | strlcpy(boot_command_line, COMMAND_LINE, ARCH_COMMAND_LINE_SIZE); | 419 | strlcpy(boot_command_line, strstrip(COMMAND_LINE), |
420 | ARCH_COMMAND_LINE_SIZE); | ||
410 | 421 | ||
411 | /* append IPL PARM data to the boot command line */ | 422 | /* append IPL PARM data to the boot command line */ |
412 | if (MACHINE_IS_VM) | 423 | if (MACHINE_IS_VM) |
diff --git a/arch/s390/kernel/head.S b/arch/s390/kernel/head.S index 9e4dc6084875..1fb59055c7ca 100644 --- a/arch/s390/kernel/head.S +++ b/arch/s390/kernel/head.S | |||
@@ -287,19 +287,7 @@ iplstart: | |||
287 | bz .Lagain1 # skip dateset trailer | 287 | bz .Lagain1 # skip dateset trailer |
288 | la %r5,0(%r4,%r2) | 288 | la %r5,0(%r4,%r2) |
289 | lr %r3,%r2 | 289 | lr %r3,%r2 |
290 | .Lidebc: | 290 | la %r3,COMMAND_LINE-PARMAREA(%r12) # load adr. of command line |
291 | tm 0(%r5),0x80 # high order bit set ? | ||
292 | bo .Ldocv # yes -> convert from EBCDIC | ||
293 | ahi %r5,-1 | ||
294 | bct %r3,.Lidebc | ||
295 | b .Lnocv | ||
296 | .Ldocv: | ||
297 | l %r3,.Lcvtab | ||
298 | tr 0(256,%r4),0(%r3) # convert parameters to ascii | ||
299 | tr 256(256,%r4),0(%r3) | ||
300 | tr 512(256,%r4),0(%r3) | ||
301 | tr 768(122,%r4),0(%r3) | ||
302 | .Lnocv: la %r3,COMMAND_LINE-PARMAREA(%r12) # load adr. of command line | ||
303 | mvc 0(256,%r3),0(%r4) | 291 | mvc 0(256,%r3),0(%r4) |
304 | mvc 256(256,%r3),256(%r4) | 292 | mvc 256(256,%r3),256(%r4) |
305 | mvc 512(256,%r3),512(%r4) | 293 | mvc 512(256,%r3),512(%r4) |
@@ -383,7 +371,6 @@ iplstart: | |||
383 | .Linitrd:.long _end + 0x400000 # default address of initrd | 371 | .Linitrd:.long _end + 0x400000 # default address of initrd |
384 | .Lparm: .long PARMAREA | 372 | .Lparm: .long PARMAREA |
385 | .Lstartup: .long startup | 373 | .Lstartup: .long startup |
386 | .Lcvtab:.long _ebcasc # ebcdic to ascii table | ||
387 | .Lreset:.byte 0xc3,0xc8,0xc1,0xd5,0xc7,0xc5,0x40,0xd9,0xc4,0xd9,0x40 | 374 | .Lreset:.byte 0xc3,0xc8,0xc1,0xd5,0xc7,0xc5,0x40,0xd9,0xc4,0xd9,0x40 |
388 | .byte 0xc1,0xd3,0xd3,0x40,0xd2,0xc5,0xc5,0xd7,0x40,0xd5,0xd6 | 375 | .byte 0xc1,0xd3,0xd3,0x40,0xd2,0xc5,0xc5,0xd7,0x40,0xd5,0xd6 |
389 | .byte 0xc8,0xd6,0xd3,0xc4 # "change rdr all keep nohold" | 376 | .byte 0xc8,0xd6,0xd3,0xc4 # "change rdr all keep nohold" |
@@ -416,13 +403,10 @@ start: | |||
416 | .sk8x8: | 403 | .sk8x8: |
417 | mvc 0(240,%r8),0(%r9) # copy iplparms into buffer | 404 | mvc 0(240,%r8),0(%r9) # copy iplparms into buffer |
418 | .gotr: | 405 | .gotr: |
419 | l %r10,.tbl # EBCDIC to ASCII table | ||
420 | tr 0(240,%r8),0(%r10) | ||
421 | slr %r0,%r0 | 406 | slr %r0,%r0 |
422 | st %r0,INITRD_SIZE+ARCH_OFFSET-PARMAREA(%r11) | 407 | st %r0,INITRD_SIZE+ARCH_OFFSET-PARMAREA(%r11) |
423 | st %r0,INITRD_START+ARCH_OFFSET-PARMAREA(%r11) | 408 | st %r0,INITRD_START+ARCH_OFFSET-PARMAREA(%r11) |
424 | j startup # continue with startup | 409 | j startup # continue with startup |
425 | .tbl: .long _ebcasc # translate table | ||
426 | .cmd: .long COMMAND_LINE # address of command line buffer | 410 | .cmd: .long COMMAND_LINE # address of command line buffer |
427 | .parm: .long PARMAREA | 411 | .parm: .long PARMAREA |
428 | .lowcase: | 412 | .lowcase: |