WSL2-Linux-Kernel/drivers/firmware/efi
Palmer Dabbelt 0c34e79e52
RISC-V: Introduce sv48 support without relocatable kernel
This patchset allows to have a single kernel for sv39 and sv48 without
being relocatable.

The idea comes from Arnd Bergmann who suggested to do the same as x86,
that is mapping the kernel to the end of the address space, which allows
the kernel to be linked at the same address for both sv39 and sv48 and
then does not require to be relocated at runtime.

This implements sv48 support at runtime. The kernel will try to boot
with 4-level page table and will fallback to 3-level if the HW does not
support it. Folding the 4th level into a 3-level page table has almost
no cost at runtime.

Note that kasan region had to be moved to the end of the address space
since its location must be known at compile-time and then be valid for
both sv39 and sv48 (and sv57 that is coming).

* riscv-sv48-v3:
  riscv: Explicit comment about user virtual address space size
  riscv: Use pgtable_l4_enabled to output mmu_type in cpuinfo
  riscv: Implement sv48 support
  asm-generic: Prepare for riscv use of pud_alloc_one and pud_free
  riscv: Allow to dynamically define VA_BITS
  riscv: Introduce functions to switch pt_ops
  riscv: Split early kasan mapping to prepare sv48 introduction
  riscv: Move KASAN mapping next to the kernel mapping
  riscv: Get rid of MAXPHYSMEM configs

Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
2022-01-19 19:37:44 -08:00
..
libstub RISC-V: Introduce sv48 support without relocatable kernel 2022-01-19 19:37:44 -08:00
test efi/efi_test: read RuntimeServicesSupported 2020-12-09 08:37:27 +01:00
Kconfig EFI updates collected by Ard Biesheuvel: 2020-12-24 12:40:07 -08:00
Makefile drivers/firmware: move x86 Generic System Framebuffers support 2021-07-21 12:04:56 +02:00
apple-properties.c efi/apple-properties: Handle device properties with software node API 2021-05-22 14:06:59 +02:00
arm-runtime.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
capsule-loader.c efi/capsule-loader: Drop superfluous assignment 2020-02-23 21:58:31 +01:00
capsule.c efi: capsule: clean scatter-gather entries from the D-cache 2020-12-09 08:37:27 +01:00
cper-arm.c efi: Replace GPL license boilerplate with SPDX headers 2019-02-04 08:27:25 +01:00
cper-x86.c x86/mce, cper: Pass x86 CPER through the MCA handling chain 2020-11-21 12:05:41 +01:00
cper.c efi/cper: use stack buffer for error record decoding 2021-10-05 13:05:59 +02:00
dev-path-parser.c ACPI: utils: Fix reference counting in for_each_acpi_dev_match() 2021-07-19 16:22:01 +02:00
earlycon.c efi/earlycon: Fix early printk for wider fonts 2020-05-12 12:29:45 +02:00
efi-bgrt.c efi/bgrt: Accept BGRT tables with a version of 0 2020-02-22 23:37:37 +01:00
efi-init.c efi: apply memblock cap after memblock_add() 2021-12-22 09:28:26 -04:00
efi-pstore.c efi: pstore: move workqueue handling out of efivars 2020-09-29 19:40:57 +02:00
efi.c efi: Allow efi=runtime 2021-09-28 22:44:15 +02:00
efibc.c efi: efibc: check for efivars write capability 2020-09-15 18:22:47 +03:00
efivars.c efi: use default_groups in kobj_type 2022-01-06 21:19:05 +01:00
embedded-firmware.c crypto: sha - split sha.h into sha1.h and sha2.h 2020-11-20 14:45:33 +11:00
esrt.c efi: use default_groups in kobj_type 2022-01-06 21:19:05 +01:00
fake_mem.c efi: Fix handling of multiple efi_fake_mem= entries 2020-01-20 08:14:29 +01:00
fake_mem.h x86/efi: Add efi_fake_mem support for EFI_MEMORY_SP 2019-11-07 15:44:23 +01:00
fdtparams.c efi/fdt: fix panic when no valid fdt found 2021-05-22 14:03:42 +02:00
memattr.c efi: Allow EFI_MEMORY_XP and EFI_MEMORY_RO both to be cleared 2021-05-22 14:05:13 +02:00
memmap.c memblock: rename memblock_free to memblock_phys_free 2021-11-06 13:30:41 -07:00
mokvar-table.c efi/mokvar: Reserve the table only if it is in boot services data 2021-07-20 09:28:09 +02:00
rci2-table.c efi: Don't attempt to map RCI2 config table if it doesn't exist 2019-12-10 12:13:02 +01:00
reboot.c efi: Use EFI ResetSystem only when available 2020-02-23 21:59:42 +01:00
riscv-runtime.c RISC-V: Add EFI runtime services 2020-10-02 14:31:28 -07:00
runtime-map.c efi: use default_groups in kobj_type 2022-01-06 21:19:05 +01:00
runtime-wrappers.c efi: Change down_interruptible() in virt_efi_reset_system() to down_trylock() 2021-10-05 13:07:01 +02:00
sysfb_efi.c efi: sysfb_efi: fix build when EFI is not set 2021-07-27 11:52:51 +02:00
tpm.c efi/tpm: Differentiate missing and invalid final event log table. 2021-07-16 18:04:55 +02:00
vars.c efivars: respect EFI_UNSUPPORTED return from firmware 2021-03-17 09:40:24 +01:00
x86_fake_mem.c efi/fake_mem: arrange for a resource entry per efi_fake_mem instance 2020-10-13 18:38:27 -07:00