Thread (18 messages) 18 messages, 3 authors, 2021-09-22

Re: [PATCH 1/5] KVM: rseq: Update rseq when processing NOTIFY_RESUME on xfer to KVM guest

From: Sean Christopherson <seanjc@google.com>
Date: 2021-09-07 14:38:39
Also in: kvm, linux-arm-kernel, linux-kselftest, linux-mips, linux-s390, lkml

On Mon, Sep 06, 2021, Paolo Bonzini wrote:
On 20/08/21 20:51, Mathieu Desnoyers wrote:
quoted
quoted
Ah, or is it the case that rseq_cs is non-NULL if and only if userspace is in an
rseq critical section, and because syscalls in critical sections are illegal, by
definition clearing rseq_cs is a nop unless userspace is misbehaving.
Not quite, as I described above. But we want it to stay set so the CONFIG_DEBUG_RSEQ
code executed when returning from ioctl to userspace will be able to validate that
it is not nested within a rseq critical section.
quoted
If that's true, what about explicitly checking that at NOTIFY_RESUME?  Or is it
not worth the extra code to detect an error that will likely be caught anyways?
The error will indeed already be caught on return from ioctl to userspace, so I
don't see any added value in duplicating this check.
Sean, can you send a v2 (even for this patch only would be okay)?
Made it all the way to v3 while you were out :-)

https://lkml.kernel.org/r/20210901203030.1292304-1-seanjc@google.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help