powerpc/init: Do not advertise radix during client-architecture-support
authorAlexey Kardashevskiy <aik@ozlabs.ru>
Tue, 9 Jan 2018 05:45:20 +0000 (16:45 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 27 Mar 2018 12:44:55 +0000 (23:44 +1100)
Currently the pseries kernel advertises radix MMU support even if
the actual support is disabled via the CONFIG_PPC_RADIX_MMU option.

This adds a check for CONFIG_PPC_RADIX_MMU to avoid advertising radix
to the hypervisor.

Suggested-by: Paul Mackerras <paulus@ozlabs.org>
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/prom_init.c

index d22c41c26bb309f7e5319994dab91c60eff3e14f..8ca3f4c915e37cbb512e820c4baed1b3832116b4 100644 (file)
@@ -1111,7 +1111,8 @@ static void __init prom_check_platform_support(void)
                }
        }
 
-       if (supported.radix_mmu && supported.radix_gtse) {
+       if (supported.radix_mmu && supported.radix_gtse &&
+           IS_ENABLED(CONFIG_PPC_RADIX_MMU)) {
                /* Radix preferred - but we require GTSE for now */
                prom_debug("Asking for radix with GTSE\n");
                ibm_architecture_vec.vec5.mmu = OV5_FEAT(OV5_MMU_RADIX);