mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [Question Consultation] KVM: x86: No lock protection was applied in handle_ept_misconfig of kernel 5.10?
@ 2025-07-09  6:32 zoudongjie (A)
  2025-07-09 12:42 ` Sean Christopherson
  0 siblings, 1 reply; 2+ messages in thread
From: zoudongjie (A) @ 2025-07-09  6:32 UTC (permalink / raw)
  To: seanjc, pbonzini, tglx, mingo, bp, dave.hansen, x86, hpa, kvm,
	linux-kernel
  Cc: Chenzhendong (alex), luolongmin, Mujinsheng (DxJanesir),
	chenjianfei (D), Fangyi (Eric), lishan (E),
	Renxuming, suxiaodong, caijunjie (A), zoudongjie (A)

Hi all,

I noticed that in handle_ept_misconfig(), kvm_io_bus_write() is called. And within kvm_io_bus_write(), BUS is obtained
through srcu_dereference(). During this process, kvm->slots_lock is not acquired, nor is srcu_read_lock() called for 
protection. If another process is synchronizing BUS at the same time, synchronize_srcu_expedited() cannot safely reclaim
space(it cannot protect srcu_dereference() outside the critical section?), how can we ensure that BUS obtained by
kvm_io_bus_write() is the latest?

Thanks,
Junjie Cai

Reported by: Junjie Cai <caijunjie15@h-partners.com>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-07-09 12:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-07-09  6:32 [Question Consultation] KVM: x86: No lock protection was applied in handle_ept_misconfig of kernel 5.10? zoudongjie (A)
2025-07-09 12:42 ` Sean Christopherson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®