Page MenuHomeFreeBSD

bhyve: Register new kevents synchronously.
ClosedPublic

Authored by jhb on May 27 2021, 1:24 PM.
Tags
None
Referenced Files
F120700502: D30502.id89999.diff
Fri, Jun 20, 8:04 AM
Unknown Object (File)
Wed, Jun 18, 2:42 AM
Unknown Object (File)
Tue, Jun 17, 5:53 AM
Unknown Object (File)
Sat, Jun 14, 6:58 AM
Unknown Object (File)
Wed, Jun 11, 6:09 PM
Unknown Object (File)
Tue, Jun 3, 9:12 PM
Unknown Object (File)
May 20 2025, 5:14 AM
Unknown Object (File)
May 19 2025, 6:05 AM

Details

Summary

Change mevent_add*() to synchronously add the new kevent. This
permits reporting event registration failures to the caller and avoids
failing the registration of other, unrelated events queued up in the
same batch.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 39506
Build 36395: arc lint + arc unit

Event Timeline

jhb requested review of this revision.May 27 2021, 1:24 PM
markj added a subscriber: markj.
markj added inline comments.
usr.sbin/bhyve/mevent.c
465

Perhaps assert that no error occurred, or cast the return value away.

This revision is now accepted and ready to land.Jun 2 2021, 3:58 PM
usr.sbin/bhyve/mevent.c
465

bhyve is pretty consistent about assuming no errors from mutexes, condvars, and once and not using either void casts or assertions of that (e.g. there's a once in block_if.c), so I think this is consistent with the rest of bhyve.

This revision was automatically updated to reflect the committed changes.