diff options
| author | Wei-Lin Chang <weilin.chang@arm.com> | 2026-09-24 10:49:51 +0100 |
|---|---|---|
| committer | Marc Zyngier <maz@kernel.org> | 2026-09-24 21:23:29 +0100 |
| commit | b1cc219eb21ab5f31fe4caa32be8057159e42db5 (patch) | |
| tree | 6efe4faf4c832eaf9d17134fc41d529a95b28083 /tools/perf/scripts/python/stackcollapse.py | |
| parent | 7d7199bdf77a3a6ed74d0037133f435a7febe97c (diff) | |
KVM: arm64: ptdump: Fix shadow ptdump sleep-in-atomic-context problem
Previously we exposed shadow page tables by creating a debugfs ptdump
file whenever a nested mmu instance gets bound to a new context, and
deleting the debugfs file whose context was getting unbound.
This turned out to be buggy, as the instance<->context binding process
is done with the mmu_lock held, and debugfs creation/deletion can sleep.
Change the approach and create a shadow ptdump file for each nested mmu
instead during kvm_vcpu_init_nested(), in a sleepable context. The files
will be named nested_mmu<index>, and reading it will return the nested
context's VTTBR, VTCR, and s2 enabled or not before dumping the shadow
page tables, given the nested mmu is valid.
Fixes: 19e15dc73f0f ("KVM: arm64: nv: Expose shadow page tables in debugfs")
Reported-by: Itaru Kitayama <itaru.kitayama@fujitsu.com>
Closes: https://lore.kernel.org/kvmarm/aiuF0KSvvv-ZozI1@sm-arm-grace07/
Tested-by: Itaru Kitayama <itaru.kitayama@fujitsu.com>
Signed-off-by: Wei-Lin Chang <weilin.chang@arm.com>
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20260924094951.727352-3-weilin.chang@arm.com
Signed-off-by: Marc Zyngier <maz@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
