Page MenuHomeFreeBSD

vfs: add accessors to ->v_irflag
ClosedPublic

Authored by mjg on Dec 28 2020, 3:28 AM.

Details

Summary

The v_irflag field is mostly accessed in an unlocked manner, but no measures were taken to prevent compiler mischief. While here this adds assertions as to state of the field.

Diff Detail

Repository
R10 FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

mjg requested review of this revision.Dec 28 2020, 3:28 AM
mjg created this revision.
sys/kern/vfs_subr.c
1824

This is an artifact from coccinelle. Will patch later.

sys/fs/nullfs/null_subr.c
272–273

May be add vn_irflag_set_unlocked() that does VI_LOCK/set/VI_UNLOCK.

sys/sys/vnode.h
990

!= 0

sys/ufs/ufs/ufs_vnops.c
288

This should be _set_cond.

  • better assert
  • more accessors
  • rebase
This revision is now accepted and ready to land.Jan 1 2021, 1:39 PM
This revision was automatically updated to reflect the committed changes.