linux/arch/powerpc/kvm
Suren Baghdasaryan 60081bf19b mm: lock vma explicitly before doing vm_flags_reset and vm_flags_reset_once
Implicit vma locking inside vm_flags_reset() and vm_flags_reset_once() is
not obvious and makes it hard to understand where vma locking is happening.
Also in some cases (like in dup_userfaultfd()) vma should be locked earlier
than vma_flags modification. To make locking more visible, change these
functions to assert that the vma write lock is taken and explicitly lock
the vma beforehand. Fix userfaultfd functions which should lock the vma
earlier.

Link: https://lkml.kernel.org/r/20230804152724.3090321-5-surenb@google.com
Suggested-by: Linus Torvalds <torvalds@linuxfoundation.org>
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Cc: Jann Horn <jannh@google.com>
Cc: Liam R. Howlett <Liam.Howlett@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2023-08-21 13:37:46 -07:00
..
book3s_32_mmu_host.c
book3s_32_mmu.c
book3s_32_sr.S
book3s_64_entry.S powerpc/64: provide a helper macro to load r2 with the kernel TOC 2022-09-28 19:22:12 +10:00
book3s_64_mmu_host.c
book3s_64_mmu_hv.c s390: 2023-05-01 12:06:20 -07:00
book3s_64_mmu_radix.c powerpc: kvmppc_unmap_free_pmd() pte_offset_kernel() 2023-06-19 16:19:08 -07:00
book3s_64_mmu.c
book3s_64_slb.S
book3s_64_vio.c KVM: PPC: Standardize on "int" return types in the powerpc KVM code 2023-03-16 10:18:05 -04:00
book3s_emulate.c
book3s_exports.c
book3s_hv_builtin.c powerpc: Mark writes registering ipi to host cpu through kvm and polling 2023-06-21 15:13:57 +10:00
book3s_hv_hmi.c
book3s_hv_interrupts.S powerpc: Fix objtool unannotated intra-function call warnings 2022-11-15 20:11:47 +11:00
book3s_hv_nested.c KVM: PPC: Book3S HV: Set SRR1[PREFIX] bit on injected interrupts 2023-04-03 14:54:44 +10:00
book3s_hv_p9_entry.c
book3s_hv_p9_perf.c
book3s_hv_ras.c
book3s_hv_rm_mmu.c mm: remove unused savedwrite infrastructure 2022-11-30 15:58:49 -08:00
book3s_hv_rm_xics.c
book3s_hv_rmhandlers.S powerpc: add CFUNC assembly label annotation 2023-04-20 12:54:24 +10:00
book3s_hv_tm_builtin.c
book3s_hv_tm.c
book3s_hv_uvmem.c mm: lock vma explicitly before doing vm_flags_reset and vm_flags_reset_once 2023-08-21 13:37:46 -07:00
book3s_hv.c s390: 2023-05-01 12:06:20 -07:00
book3s_hv.h
book3s_interrupts.S
book3s_mmu_hpte.c
book3s_paired_singles.c KVM: PPC: Make kvmppc_get_last_inst() produce a ppc_inst_t 2023-04-03 15:45:41 +10:00
book3s_pr_papr.c KVM: remove KVM_REQ_UNHALT 2022-09-26 12:37:21 -04:00
book3s_pr.c s390: 2023-05-01 12:06:20 -07:00
book3s_rmhandlers.S KVM: PPC: Enable prefixed instructions for HV KVM and disable for PR KVM 2023-04-03 15:45:59 +10:00
book3s_rtas.c
book3s_segment.S
book3s_xics.c
book3s_xics.h
book3s_xive_native.c mm: replace vma->vm_flags direct modifications with modifier calls 2023-02-09 16:51:39 -08:00
book3s_xive.c Merge branch 'topic/ppc-kvm' into next 2022-11-30 20:42:22 +11:00
book3s_xive.h powerpc/xive: remove unused parameter 2022-11-24 23:12:18 +11:00
book3s.c KVM: PPC: Fetch prefixed instructions from the guest 2023-04-03 15:45:50 +10:00
book3s.h
booke_emulate.c
booke_interrupts.S
booke.c KVM: PPC: Fetch prefixed instructions from the guest 2023-04-03 15:45:50 +10:00
booke.h KVM: PPC: BookE: Fix W=1 warnings 2023-04-03 14:54:20 +10:00
bookehv_interrupts.S KVM: PPC: Fetch prefixed instructions from the guest 2023-04-03 15:45:50 +10:00
e500_emulate.c
e500_mmu_host.c KVM: PPC: Fetch prefixed instructions from the guest 2023-04-03 15:45:50 +10:00
e500_mmu_host.h
e500_mmu.c
e500.c KVM: Drop kvm_arch_check_processor_compat() hook 2022-12-29 15:41:28 -05:00
e500.h powerpc: Remove CONFIG_PPC_BOOK3E_MMU 2022-09-26 23:00:14 +10:00
e500mc.c KVM: PPC: booke: Mark three local functions "static" 2023-03-22 22:45:41 +11:00
emulate_loadstore.c KVM: PPC: Fetch prefixed instructions from the guest 2023-04-03 15:45:50 +10:00
emulate.c KVM: PPC: Fetch prefixed instructions from the guest 2023-04-03 15:45:50 +10:00
fpu.S powerpc/32: Fix objtool unannotated intra-function call warnings 2022-11-18 19:00:06 +11:00
Kconfig kvm: Remove "select SRCU" 2023-04-05 13:47:42 +00:00
Makefile
mpic.c
powerpc.c s390: 2023-05-01 12:06:20 -07:00
timing.c
timing.h
tm.S powerpc/64: provide a helper macro to load r2 with the kernel TOC 2022-09-28 19:22:12 +10:00
trace_book3s.h
trace_booke.h
trace_hv.h
trace_pr.h
trace.h