Thread (40 messages) 40 messages, 4 authors, 6d ago

Re: [PATCH v3 01/14] KVM: Allow architectures to disallow pre-fault

From: "Lorenzo Stoakes (ARM)" <ljs@kernel.org>
Date: 2026-09-22 18:52:49
Also in: kvm, kvmarm, linux-doc, linux-kselftest, lkml

On Tue, Sep 22, 2026 at 11:40:29AM -0700, Sean Christopherson wrote:
quoted
quoted
But look at it from an x86 perspective.  Pretty much everyone will look at this
and expect:

  bool kvm_arch_vcpu_allow_pre_fault_memory(struct kvm_vcpu *vcpu)
  {
	return vcpu->kvm->arch.pre_fault_allowed;
  }
I'm not sure I really get your point here at all? :)

Why would it matter what people who are too lazy to go check the implementation
assume about an arch hook?
Because I don't hate the people that contribute to KVM, and want to make it as
easy as possible for them to not make mistakes?
Haha well I think I misunderstood you here, I see the point that you might
assume some state like this rather than an explicit conditional, and the inline
comment suggested by Oliver makes things a bit clearer.

--
Cheers, Lorenzo
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help