s390/smp: sort out physical vs virtual CPU0 lowcore pointer
authorAlexander Gordeev <agordeev@linux.ibm.com>
Wed, 30 Mar 2022 17:50:16 +0000 (19:50 +0200)
committerHeiko Carstens <hca@linux.ibm.com>
Mon, 25 Apr 2022 11:54:13 +0000 (13:54 +0200)
SPX instruction called from set_prefix() expects physical
address of the lowcore to be installed, but instead the
virtual address is passed.

Note: this does not fix a bug currently, since virtual and
physical addresses are identical.

Reviewed-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
arch/s390/kernel/setup.c

index d860ac3..8d91ecc 100644 (file)
@@ -494,7 +494,7 @@ static void __init setup_lowcore_dat_off(void)
        lc->return_mcck_lpswe = gen_lpswe(__LC_RETURN_MCCK_PSW);
        lc->preempt_count = PREEMPT_DISABLED;
 
-       set_prefix((u32)(unsigned long) lc);
+       set_prefix(__pa(lc));
        lowcore_ptr[0] = lc;
 }