mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 06:44:00 -04:00
s390/boot: Uncouple virtual and physical kernel offsets
This is a preparatory rework to allow uncoupling virtual and physical addresses spaces. Currently __kaslr_offset is the kernel offset in both physical memory on boot and in virtual memory after DAT mode is enabled. Uncouple these offsets and rename the physical address space variant to __kaslr_offset_phys while keep the name __kaslr_offset for the offset in virtual address space. Do not use __kaslr_offset_phys after DAT mode is enabled just yet, but still make it a persistent boot variable for later use. Use __kaslr_offset and __kaslr_offset_phys offsets in proper contexts and alter handle_relocs() function to distinguish between the two. Acked-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
This commit is contained in:
@@ -180,12 +180,14 @@ int arch_make_page_accessible(struct page *page);
|
||||
|
||||
struct vm_layout {
|
||||
unsigned long kaslr_offset;
|
||||
unsigned long kaslr_offset_phys;
|
||||
unsigned long identity_size;
|
||||
};
|
||||
|
||||
extern struct vm_layout vm_layout;
|
||||
|
||||
#define __kaslr_offset vm_layout.kaslr_offset
|
||||
#define __kaslr_offset_phys vm_layout.kaslr_offset_phys
|
||||
#define ident_map_size vm_layout.identity_size
|
||||
|
||||
static inline unsigned long kaslr_offset(void)
|
||||
|
||||
Reference in New Issue
Block a user