diff options
author | Alexander Egorenkov <egorenar@linux.ibm.com> | 2021-06-15 16:05:09 +0200 |
---|---|---|
committer | Heiko Carstens <hca@linux.ibm.com> | 2021-07-27 09:39:16 +0200 |
commit | 7accd1f8649643caac8061cea24720b229a57417 (patch) | |
tree | cd5f1d2d03c69e50c92f404391c5d0e8bd9a3cd8 /arch/s390/boot | |
parent | 6a24d4666f4308e7e7f00bbe7e047dae5499a13d (diff) | |
download | linux-7accd1f8649643caac8061cea24720b229a57417.tar.gz |
s390/boot: make _diag308_reset_dma() position-independent
As a preparation for moving the .dma.data section from the decompressor to
the decompressed kernel, the .dma.data section must be made relocatable
by replacing absolute memory addressing with relative one. This is required
in order to be able to relocate the DMA section to a memory address <= 2G
as required by the hardware architecture. The DMA section must be
relocated in case the decompressed kernel was loaded to an address >= 2G
which can occur if KASAN is enabled. By making the whole DMA section
position-independent we avoid applying relocations to it whenever it is
moved to a different address, which becomes possible as soon as it becomes
a part of the decompressed kernel.
Signed-off-by: Alexander Egorenkov <egorenar@linux.ibm.com>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Diffstat (limited to 'arch/s390/boot')
-rw-r--r-- | arch/s390/boot/text_dma.S | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/s390/boot/text_dma.S b/arch/s390/boot/text_dma.S index 5ff5fee02801..65e037ab7df5 100644 --- a/arch/s390/boot/text_dma.S +++ b/arch/s390/boot/text_dma.S @@ -127,6 +127,8 @@ restart_part2: larl %r4,.Lprefix # Restore prefix register spx 0(%r4) larl %r4,.Lcontinue_psw # Restore PSW flags + larl %r2,.Lcontinue + stg %r2,8(%r4) lpswe 0(%r4) .Lcontinue: BR_EX_DMA_r14 @@ -139,7 +141,7 @@ ENDPROC(_diag308_reset_dma) .align 8 .Lcontinue_psw: - .quad 0,.Lcontinue + .quad 0,0 .align 8 .Lctlreg0: |