Page MenuHomeFreeBSD

umtx: Do not make an exiting thread the owner of a PI mutex
ClosedPublic

Authored by markj on Jul 24 2026, 10:35 PM.
Tags
None
Referenced Files
F167972729: D58447.diff
Tue, Aug 25, 5:04 PM
Unknown Object (File)
Tue, Aug 18, 1:43 PM
Unknown Object (File)
Tue, Aug 18, 12:13 AM
Unknown Object (File)
Thu, Aug 13, 9:16 PM
Unknown Object (File)
Mon, Aug 10, 10:00 AM
Unknown Object (File)
Sun, Aug 9, 7:14 AM
Unknown Object (File)
Sat, Aug 8, 8:28 PM
Unknown Object (File)
Sat, Aug 8, 5:43 PM
Subscribers

Details

Summary

Otherwise an assertion in umtx_thread_alloc()
(TAILQ_EMPTY(&uq->uq_pi_contested)) is violated.

This use of TDB_EXIT is hacky and I don't really like it, but I cannot
see another way to check for an exiting thread without adding some more
overhead to kern_thr_exit().

Fixes: 2a339d9e3dc1
Reported by: Maik Muench of Secfault Security

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable