ANDROID: KVM: arm64: s2mpu: Initialize MPTs to PROT_RW

Change the permissions that MPTs are initialized with from PROT_NONE to
PROT_RW. No functional change intended as the generic IOMMU code
sets permissions for the entire address space later. This will allow to
optimize boot time by only unmapping pages not available to host.

Bug: 190463801
Bug: 218012133
Signed-off-by: David Brazdil <dbrazdil@google.com>
Change-Id: Ic29ec690a84cde22a2ce8fe33e7127711c6f0f3e
This commit is contained in:
David Brazdil
2022-04-06 16:42:36 +01:00
parent a946ac5ff5
commit 174ac5b7c5

View File

@@ -466,7 +466,7 @@ static int s2mpu_init(void *data, size_t size)
host_mpt.fmpt[gb] = (struct fmpt){
.smpt = smpt,
.gran_1g = true,
.prot = MPT_PROT_NONE,
.prot = MPT_PROT_RW,
};
}