diff options
| author | Fuad Tabba <fuad.tabba@linux.dev> | 2026-07-17 14:03:15 +0100 |
|---|---|---|
| committer | Oliver Upton <oupton@kernel.org> | 2026-07-31 00:11:57 -0700 |
| commit | c243222701690da30c010d6b98545684f5d78b15 (patch) | |
| tree | 48b3b0694691cfea9c519bcdbcf3c77ab7257bfd /include/linux/timerqueue.h | |
| parent | 1feb9f6af895c1ec0caed269108d6ffa1f9a31c4 (diff) | |
KVM: arm64: Don't WARN on pKVM stage-2 map failures
pkvm_pgtable_stage2_map() wraps the __pkvm_host_share_guest() and
__pkvm_host_donate_guest() return in WARN_ON(), but those hypercalls
fail for reasons that are not EL1 invariant violations: -EINVAL for a
pfn that is not memblock RAM (check_range_allowed_memory() rejects a
device page mapped into a non-protected guest) and -ENOMEM under
memcache pressure. Both are reachable from a guest fault, so the WARN
splats on host input.
Return the error without warning. The unshare and write-protect WARNs
stay, since a failure there does signal a broken EL1 invariant.
Fixes: 3669ddd8fa8b5 ("KVM: arm64: Add a range to pkvm_mappings")
Signed-off-by: Fuad Tabba <fuad.tabba@linux.dev>
Reviewed-by: Bradley Morgan <include@grrlz.net>
Tested-by: Bradley Morgan <include@grrlz.net> # On pixel 7, Android 17 CP2A.260705.006
Test: Bradley Morgan <include@grrlz.net> # On QEMU arm64 host
Link: https://patch.msgid.link/20260717130317.1953574-6-fuad.tabba@linux.dev
Signed-off-by: Oliver Upton <oupton@kernel.org>
Diffstat (limited to 'include/linux/timerqueue.h')
0 files changed, 0 insertions, 0 deletions
