The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=5629b5cf79934e0b94ddbbd93b7756f74fe4050a
commit 5629b5cf79934e0b94ddbbd93b7756f74fe4050a Author: Dimitry Andric <[email protected]> AuthorDate: 2025-12-25 18:02:27 +0000 Commit: Dimitry Andric <[email protected]> CommitDate: 2025-12-25 18:02:40 +0000 cuse(3): annotate cuse_init() to suppress thread safety analysis This avoids warnings from clang 21, similar to: /usr/src/lib/libcuse/cuse_lib.c:111:14: error: writing variable 'h_cuse' requires holding mutex 'm_cuse' exclusively [-Werror,-Wthread-safety-analysis] 111 | TAILQ_INIT(&h_cuse); | ^ /usr/src/lib/libcuse/cuse_lib.c:111:14: error: writing variable 'h_cuse' requires holding mutex 'm_cuse' exclusively [-Werror,-Wthread-safety-analysis] /usr/src/lib/libcuse/cuse_lib.c:112:14: error: writing variable 'h_cuse_entered' requires holding mutex 'm_cuse' exclusively [-Werror,-Wthread-safety-analysis] 112 | TAILQ_INIT(&h_cuse_entered); | ^ /usr/src/lib/libcuse/cuse_lib.c:112:14: error: writing variable 'h_cuse_entered' requires holding mutex 'm_cuse' exclusively [-Werror,-Wthread-safety-analysis] MFC after: 3 days --- lib/libcuse/cuse_lib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libcuse/cuse_lib.c b/lib/libcuse/cuse_lib.c index 3f040d0eeeda..48c72258106d 100644 --- a/lib/libcuse/cuse_lib.c +++ b/lib/libcuse/cuse_lib.c @@ -93,7 +93,7 @@ static struct cuse_vm_allocation a_cuse[CUSE_ALLOC_UNIT_MAX] pthread_mutex_unlock(&m_cuse) int -cuse_init(void) +cuse_init(void) __no_lock_analysis { pthread_mutexattr_t attr;
