HomeFreeBSD

mtx: rename MTX_CONTESTED to MTX_WAITERS

Description

mtx: rename MTX_CONTESTED to MTX_WAITERS

Using the word "contested" for the case where there are threads blocked
on the lock is misleading at best (the lock is already contested if it
is being held by one thread and wanted by another). It also diverges
from naming used in other primitives (which refer to them as "waiters").

Rename it for some consistency.

There were uses of the flag outside of mutex code itself.

This is an abuse of the interface. The netgraph thing looks suspicious
at best, the sctp thing is fundamentally wrong. Fixing those up is left
as an exercise for the reader.

While here touch up stale commentary.

Sponsored by: Rubicon Communications, LLC ("Netgate")

Details

Provenance
mjgAuthored on Oct 6 2025, 2:00 AM
Parents
rG4dc4a512e065: zfs: install missing openzfs-2.4 files in /usr/share/zfs/compatibility.d
Branches
Unknown
Tags
Unknown