aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/kvm/x86/nested_exceptions_test.c
diff options
context:
space:
mode:
authorBrian Geffon <[email protected]>2025-02-26 16:23:41 +0000
committerAndrew Morton <[email protected]>2025-03-06 05:36:18 +0000
commit34b82f33cf3f03bc39e9a205a913d790e1520ade (patch)
tree39da404285db9b2751977f39f699843b14727f94 /tools/testing/selftests/kvm/x86/nested_exceptions_test.c
parentmm: don't skip arch_sync_kernel_mappings() in error paths (diff)
downloadkernel-34b82f33cf3f03bc39e9a205a913d790e1520ade.tar.gz
kernel-34b82f33cf3f03bc39e9a205a913d790e1520ade.zip
mm: fix finish_fault() handling for large folios
When handling faults for anon shmem finish_fault() will attempt to install ptes for the entire folio. Unfortunately if it encounters a single non-pte_none entry in that range it will bail, even if the pte that triggered the fault is still pte_none. When this situation happens the fault will be retried endlessly never making forward progress. This patch fixes this behavior and if it detects that a pte in the range is not pte_none it will fall back to setting a single pte. [[email protected]: tweak whitespace] Link: https://lkml.kernel.org/r/[email protected] Link: https://lkml.kernel.org/r/[email protected] Fixes: 43e027e41423 ("mm: memory: extend finish_fault() to support large folio") Signed-off-by: Brian Geffon <[email protected]> Suggested-by: Baolin Wang <[email protected]> Reported-by: Marek Maslanka <[email protected]> Cc: Hugh Dickins <[email protected]> Cc: David Hildenbrand <[email protected]> Cc: Hugh Dickens <[email protected]> Cc: Kefeng Wang <[email protected]> Cc: Matthew Wilcow (Oracle) <[email protected]> Cc: Suren Baghdasaryan <[email protected]> Cc: Zi Yan <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'tools/testing/selftests/kvm/x86/nested_exceptions_test.c')
0 files changed, 0 insertions, 0 deletions