diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index 738bae4a5958109456c1107540705c83c82bb106..bba7ef30d74e3750c2086c1fabe507d1b35aad4b 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt @@ -929,6 +929,9 @@ bytes respectively. Such letter suffixes can also be entirely omitted. disable= [IPV6] See Documentation/networking/ipv6.txt. + disable_radix [PPC] + Disable RADIX MMU mode on POWER9 + disable_cpu_apicid= [X86,APIC,SMP] Format: The number of initial APIC ID for the diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c index 48434be99a075969a7208b21aa7cbf22d7bd94d9..7a01113d525c6937da8a933ab7a728208c4c9638 100644 --- a/arch/powerpc/kernel/prom.c +++ b/arch/powerpc/kernel/prom.c @@ -646,6 +646,14 @@ static void __init early_reserve_mem(void) #endif } +static bool disable_radix; +static int __init parse_disable_radix(char *p) +{ + disable_radix = true; + return 0; +} +early_param("disable_radix", parse_disable_radix); + void __init early_init_devtree(void *params) { phys_addr_t limit; @@ -735,6 +743,11 @@ void __init early_init_devtree(void *params) */ spinning_secondaries = boot_cpu_count - 1; #endif + /* + * now fixup radix MMU mode based on kernel command line + */ + if (disable_radix) + cur_cpu_spec->mmu_features &= ~MMU_FTR_RADIX; #ifdef CONFIG_PPC_POWERNV /* Scan and build the list of machine check recoverable ranges */