milos-linux/arch/s390/kvm
Claudio Imbrenda 6ae67dcac7 KVM: s390: Fix possible reference leak in fault-in code
If kvm_s390_new_mmu_cache() fails, kvm_s390_faultin_gfn() returns
without releasing the faulted page.

Fix this by moving the allocation of the memory cache outside of the
loop. There is no reason to check at every iteration.

Opportunistically fix a comment.

Fixes: e907ae5301 ("KVM: s390: Add helper functions for fault handling")
Signed-off-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
Message-ID: <20260602142356.169458-10-imbrenda@linux.ibm.com>
2026-06-02 19:29:33 +02:00
..
dat.c KVM: s390: vsie: Fix unshadowing logic 2026-05-22 11:25:10 +02:00
dat.h KVM: s390: vsie: Fix unshadowing logic 2026-05-22 11:25:10 +02:00
diag.c KVM: s390: Switch to new gmap 2026-02-04 17:00:10 +01:00
faultin.c KVM: s390: Fix possible reference leak in fault-in code 2026-06-02 19:29:33 +02:00
faultin.h KVM: s390: Add helper functions for fault handling 2026-02-04 17:00:09 +01:00
gaccess.c KVM: s390: vsie: Fix rmap handling in _do_shadow_crste() 2026-06-02 16:46:41 +02:00
gaccess.h KVM: s390: Switch to new gmap 2026-02-04 17:00:10 +01:00
gmap.c KVM: s390: Fix _gmap_unmap_crste() 2026-06-02 16:46:41 +02:00
gmap.h KVM: s390: Fix _gmap_crstep_xchg_atomic() 2026-06-02 16:46:41 +02:00
guestdbg.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
intercept.c KVM: s390: Switch to new gmap 2026-02-04 17:00:10 +01:00
interrupt.c KVM: s390: pci: fix array indexing 2026-05-12 23:15:38 +02:00
Kconfig KVM: remove CONFIG_KVM_GENERIC_MMU_NOTIFIER 2026-02-28 15:31:35 +01:00
kvm-s390.c KVM: s390: Prevent memslots outside the ASCE range 2026-06-02 19:27:11 +02:00
kvm-s390.h KVM: s390: vsie: Accommodate ESA prefix pages 2026-04-02 15:37:01 +02:00
Makefile KVM: s390: Switch to new gmap 2026-02-04 17:00:10 +01:00
pci.c KVM: s390: pci: Fix aisb calculation 2026-04-27 11:14:45 +02:00
pci.h KVM: s390: Mark __kvm_s390_init() and its descendants as __init 2022-12-29 15:41:22 -05:00
priv.c KVM: s390: Fix guest / virtual address confusion in _essa_clear_cbrl() 2026-06-02 16:46:41 +02:00
pv.c KVM: s390: Lock pte when making page secure 2026-06-02 16:46:41 +02:00
sigp.c KVM: s390: Refactor kvm_is_error_gpa() into kvm_is_gpa_in_memslot() 2024-02-20 07:37:45 -08:00
trace-s390.h KVM: s390: Don't use %pK through tracepoints 2025-03-17 08:55:46 +00:00
trace.h
vsie.c - ESA nesting support 2026-04-13 19:01:15 +02:00