s390/head: fix error message on unsupported hardware
authorSascha Silbe <silbe@linux.vnet.ibm.com>
Wed, 4 Nov 2015 12:32:08 +0000 (13:32 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Mon, 9 Nov 2015 08:10:47 +0000 (09:10 +0100)
commitc6eafbf9903c4283ba146098ad54240a24ffbeb1
treee31abaf9fcb4180ddcad0c01db7981ddfaf5ccdd
parentce5c2d2c256a4c8b523036537cd6be2d6af8f69d
s390/head: fix error message on unsupported hardware

startup calls the C function _sclp_print_early() if the machine we're
running on is not supported by the kernel. sclp.c is getting built
with -m64, so _sclp_print_early() expects the zSeries ELF ABI to be
used.

We previously called _sclp_print_early() using the S/390 ELF ABI, with
a stack frame size of 96 bytes and while being in 31-bit address
mode. This caused _sclp_wait_int() (called indirectly from
_sclp_print_early()) to jump to an undefined address. While
_sclp_wait_int() contained some code to deal with being called in
31-bit addressing mode, it didn't quite work. While fixing this is
possible, the code would still only work by chance and could break any
time.

Ensure compliance with the zSeries ELF ABI by switching to 64-bit
addressing mode early and using a minimum stack frame size of 160
bytes.

Signed-off-by: Sascha Silbe <silbe@linux.vnet.ibm.com>
Acked-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/kernel/head.S
This page took 0.031667 seconds and 5 git commands to generate.