HomeFreeBSD

kqueue: drain kqueue taskqueue if syscall tickled it

Description

kqueue: drain kqueue taskqueue if syscall tickled it

Otherwise return from the syscall and next syscall, which could be
kevent(2) on the kqueue that should be notified, races with the kqueue
taskqueue thread, and potentially misses the wakeup. This is reliably
visible when kevent(2) only peeks into events using zeroed timeout.

PR: 258310
Reported by: arichardson, Jan Kokemüller <jan.kokemueller@gmail.com>
Reviewed by: arichardson, markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D31858

Details

Provenance
kibAuthored on Sep 6 2021, 11:43 AM
Reviewer
arichardson
Differential Revision
D31858: kqueue: drain kqueue taskqueue if syscall tickled it
Parents
rG936f4a42fa2a: lltable: do not require prefix lookup when checking lle allocation rules.
Branches
Unknown
Tags
Unknown