• Russell Currey's avatar
    powerpc/mm: Warn if W+X pages found on boot · 453d87f6
    Russell Currey authored
    Implement code to walk all pages and warn if any are found to be both
    writable and executable.  Depends on STRICT_KERNEL_RWX enabled, and is
    behind the DEBUG_WX config option.
    
    This only runs on boot and has no runtime performance implications.
    
    Very heavily influenced (and in some cases copied verbatim) from the
    ARM64 code written by Laura Abbott (thanks!), since our ptdump
    infrastructure is similar.
    Signed-off-by: default avatarRussell Currey <ruscur@russell.cc>
    [mpe: Fixup build error when disabled]
    Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
    453d87f6
pgtable_32.c 9.87 KB