[PATCH resend v3] riscv: Allow to downgrade paging mode from the command line

Conor Dooley conor.dooley at microchip.com
Mon Jan 23 06:10:39 PST 2023


On Mon, Jan 23, 2023 at 11:51:35AM +0100, Alexandre Ghiti wrote:
> Add 2 early command line parameters that allow to downgrade satp mode
> (using the same naming as x86):
> - "no5lvl": use a 4-level page table (down from sv57 to sv48)
> - "no4lvl": use a 3-level page table (down from sv57/sv48 to sv39)
> 
> Note that going through the device tree to get the kernel command line
> works with ACPI too since the efi stub creates a device tree anyway with
> the command line.
> 
> Also, as those params are treated very early in the boot process and we
> use standard device tree functions that may be kasan instrumented, we
> only enable them for !KASAN configurations.
> 
> Reviewed-by: Björn Töpel <bjorn at kernel.org>
> Signed-off-by: Alexandre Ghiti <alexghiti at rivosinc.com>
> ---
> 
> v3:
> - Massage commit log to make no4lvl clearer, as asked by Conor
> - Add a note to kernel-parameters.txt regarding the impossibility to use
>   those parameters when KASAN is enabled, as suggested by Conor

For the improved descriptions & commit message:
Reviewed-by: Conor Dooley <conor.dooley at microchip.com>

Apologies for complaining about the missing changelog earlier!

Conor.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-riscv/attachments/20230123/4f5330fb/attachment.sig>


More information about the linux-riscv mailing list