Page MenuHomeFreeBSD

vfs: manage mnt_writeopcount with atomics
ClosedPublic

Authored by mjg on Sep 9 2019, 12:07 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Oct 6, 2:25 AM
Unknown Object (File)
Sep 12 2025, 12:31 AM
Unknown Object (File)
Sep 7 2025, 1:14 AM
Unknown Object (File)
Sep 2 2025, 11:09 AM
Unknown Object (File)
Aug 31 2025, 3:46 AM
Unknown Object (File)
Aug 24 2025, 5:26 PM
Unknown Object (File)
Aug 14 2025, 11:06 PM
Unknown Object (File)
Aug 14 2025, 10:37 PM
Subscribers

Details

Summary

This requires a small hack in SU code which disables suspension "by hand". I did not think it's worthwhile making it use a generic routine.

Tested by pho

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

  • rebase on top of the custom barrier
kib added inline comments.
sys/kern/vfs_vnops.c
1638 ↗(On Diff #62110)

I think you can write
if (__predict_true(!mplocked && (flags & V_XSLEEP) == 0) && vfs_op_thread_enter(mp)) {
and remove that ugly slowpath label.

This revision is now accepted and ready to land.Sep 14 2019, 9:35 PM
  • remove the slowpath label
This revision now requires review to proceed.Sep 14 2019, 10:28 PM
This revision is now accepted and ready to land.Sep 16 2019, 7:29 AM
jeff added inline comments.
sys/kern/vfs_vnops.c
1800–1802 ↗(On Diff #62130)

Since we do this twice it could just be part of a macro or inline.

This revision was automatically updated to reflect the committed changes.