diff options
author | Alexander Gordeev <agordeev@linux.ibm.com> | 2023-08-10 21:40:19 +0200 |
---|---|---|
committer | Alexander Gordeev <agordeev@linux.ibm.com> | 2024-04-17 13:38:00 +0200 |
commit | 7de0446f0b26589fa80e384d8edaa2c279583652 (patch) | |
tree | 14c8bfcee990544bf0f3d1a2884933dd9cfbb428 /arch/s390/include/asm/page.h | |
parent | s390/boot: Uncouple virtual and physical kernel offsets (diff) | |
download | linux-7de0446f0b26589fa80e384d8edaa2c279583652.tar.xz linux-7de0446f0b26589fa80e384d8edaa2c279583652.zip |
s390/boot: Make identity mapping base address explicit
This is a preparatory rework to allow uncoupling virtual
and physical addresses spaces.
Currently the identity mapping base address is implicit
and is always set to zero. Make it explicit by putting
into __identity_base persistent boot variable and use it
in proper context - which is the value of PAGE_OFFSET.
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
Diffstat (limited to 'arch/s390/include/asm/page.h')
-rw-r--r-- | arch/s390/include/asm/page.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/s390/include/asm/page.h b/arch/s390/include/asm/page.h index e2137b6ec2ed..95403750d25a 100644 --- a/arch/s390/include/asm/page.h +++ b/arch/s390/include/asm/page.h @@ -181,6 +181,7 @@ int arch_make_page_accessible(struct page *page); struct vm_layout { unsigned long kaslr_offset; unsigned long kaslr_offset_phys; + unsigned long identity_base; unsigned long identity_size; }; @@ -188,6 +189,7 @@ extern struct vm_layout vm_layout; #define __kaslr_offset vm_layout.kaslr_offset #define __kaslr_offset_phys vm_layout.kaslr_offset_phys +#define __identity_base vm_layout.identity_base #define ident_map_size vm_layout.identity_size static inline unsigned long kaslr_offset(void) @@ -203,8 +205,8 @@ static inline int kaslr_enabled(void) return 0; } -#define __PAGE_OFFSET 0x0UL -#define PAGE_OFFSET 0x0UL +#define __PAGE_OFFSET __identity_base +#define PAGE_OFFSET __PAGE_OFFSET #define __pa_nodebug(x) ((unsigned long)(x)) |