Page MenuHomeFreeBSD

buf: Relax an assertion in BUF_UNLOCK
ClosedPublic

Authored by markj on Feb 21 2026, 4:51 PM.
Tags
None
Referenced Files
F153423046: D55418.id172390.diff
Tue, Apr 21, 2:19 AM
Unknown Object (File)
Sun, Apr 12, 7:23 PM
Unknown Object (File)
Sat, Apr 11, 10:45 PM
Unknown Object (File)
Sat, Apr 11, 6:37 PM
Unknown Object (File)
Tue, Apr 7, 3:31 PM
Unknown Object (File)
Mon, Apr 6, 12:53 PM
Unknown Object (File)
Wed, Apr 1, 1:36 AM
Unknown Object (File)
Sat, Mar 28, 2:44 PM
Subscribers

Details

Summary

The BUF_UNLOCK macro asserts that B_REMFREE is not set, as it is up to
the lock owner to complete the dequeue from the free list before
releasing the lock. However, if the thread has acquired the lock
multiple times, then releasing the recursive lock should be ok. Modify
the assertion to reflect this.

This was triggered by an out-of-tree filesystem.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 70854
Build 67737: arc lint + arc unit