From: Vladimir Murzin Date: Fri, 1 Dec 2017 09:19:11 +0000 (+0100) Subject: ARM: 8732/1: NOMMU: Allow userspace to access background MPU region X-Git-Tag: v5.15~9493^2^2~13 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7710cc691cfc5ad457173944d989875a6e79d238;p=platform%2Fkernel%2Flinux-starfive.git ARM: 8732/1: NOMMU: Allow userspace to access background MPU region Currently, with MPU enabled, we prohibit userspace access to anything except RAM. Benjamin, reported that because of that his userspace application cannot access framebuffer's memory he reserved in device tree. It turns out we have no option other than to allow userspace access memory covered by background region. Reported-by: Benjamin Gaignard Tested-by: Benjamin Gaignard Signed-off-by: Vladimir Murzin Signed-off-by: Russell King --- diff --git a/arch/arm/mm/pmsa-v7.c b/arch/arm/mm/pmsa-v7.c index 976df60..6509989 100644 --- a/arch/arm/mm/pmsa-v7.c +++ b/arch/arm/mm/pmsa-v7.c @@ -433,7 +433,7 @@ void __init mpu_setup(void) /* Background */ err |= mpu_setup_region(region++, 0, 32, - MPU_ACR_XN | MPU_RGN_STRONGLY_ORDERED | MPU_AP_PL1RW_PL0NA, + MPU_ACR_XN | MPU_RGN_STRONGLY_ORDERED | MPU_AP_PL1RW_PL0RW, 0, false); #ifdef CONFIG_XIP_KERNEL