Commit 4e27d44a authored by Vincent Donnefort's avatar Vincent Donnefort
Browse files

ANDROID: KVM: arm64: Fix MMIO guard alignment for guests



Currently pkvm_granule alignment is enforced for the start address of
the ioremap hook. This is a problem as this address doesn't have to be
aligned at all. At the same time, the size of the ioremap isn't verified
and we can simply overshoot the MMIO guard original request.

MMIO guard is solely here to indicate to the hypervisor where are the
MMIO regions. If we validate the RAM is aligned with the pkvm_granule,
we can safely overshoot the MMIO guard.

Bug: 381400679
Bug: 357781595
Fixes: 13c871ae ("ANDROID: KVM: arm64: Allow the pVM guest to boot with different granule")
Tested-by: default avatarMostafa Saleh <smostafa@google.com>
Change-Id: I0ae27c1626fab17a3b58a6004b6b4f31c23c61a3
Signed-off-by: default avatarVincent Donnefort <vdonnefort@google.com>
parent 3ea0fa42
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment