Lines Matching defs:opts

278 __mtx_lock_flags(volatile uintptr_t *c, int opts, const char *file, int line)
294 WITNESS_CHECKORDER(&m->lock_object, (opts & ~MTX_RECURSE) |
300 _mtx_lock_sleep(m, v, opts, file, line);
304 LOCK_LOG_LOCK("LOCK", &m->lock_object, opts, m->mtx_recurse, file,
306 WITNESS_LOCK(&m->lock_object, (opts & ~MTX_RECURSE) | LOP_EXCLUSIVE,
312 __mtx_unlock_flags(volatile uintptr_t *c, int opts, const char *file, int line)
323 WITNESS_UNLOCK(&m->lock_object, opts | LOP_EXCLUSIVE, file, line);
324 LOCK_LOG_LOCK("UNLOCK", &m->lock_object, opts, m->mtx_recurse, file,
329 __mtx_unlock_sleep(c, (uintptr_t)curthread, opts, file, line);
331 __mtx_unlock(m, curthread, opts, file, line);
337 __mtx_lock_spin_flags(volatile uintptr_t *c, int opts, const char *file,
354 (opts & MTX_RECURSE) != 0,
357 opts &= ~MTX_RECURSE;
358 WITNESS_CHECKORDER(&m->lock_object, opts | LOP_NEWORDER | LOP_EXCLUSIVE,
365 _mtx_lock_spin(m, v, opts, file, line);
370 __mtx_lock_spin(m, curthread, opts, file, line);
372 LOCK_LOG_LOCK("LOCK", &m->lock_object, opts, m->mtx_recurse, file,
374 WITNESS_LOCK(&m->lock_object, opts | LOP_EXCLUSIVE, file, line);
378 __mtx_trylock_spin_flags(volatile uintptr_t *c, int opts, const char *file,
393 KASSERT((opts & MTX_RECURSE) == 0,
396 if (__mtx_trylock_spin(m, curthread, opts, file, line)) {
397 LOCK_LOG_TRY("LOCK", &m->lock_object, opts, 1, file, line);
398 WITNESS_LOCK(&m->lock_object, opts | LOP_EXCLUSIVE, file, line);
401 LOCK_LOG_TRY("LOCK", &m->lock_object, opts, 0, file, line);
406 __mtx_unlock_spin_flags(volatile uintptr_t *c, int opts, const char *file,
418 WITNESS_UNLOCK(&m->lock_object, opts | LOP_EXCLUSIVE, file, line);
419 LOCK_LOG_LOCK("UNLOCK", &m->lock_object, opts, m->mtx_recurse, file,
432 _mtx_trylock_flags_int(struct mtx *m, int opts LOCK_FILE_LINE_ARG_DEF)
467 (opts & MTX_RECURSE) != 0)) {
477 opts &= ~MTX_RECURSE;
479 LOCK_LOG_TRY("LOCK", &m->lock_object, opts, rval, file, line);
481 WITNESS_LOCK(&m->lock_object, opts | LOP_EXCLUSIVE | LOP_TRYLOCK,
493 _mtx_trylock_flags_(volatile uintptr_t *c, int opts, const char *file, int line)
498 return (_mtx_trylock_flags_int(m, opts LOCK_FILE_LINE_ARG));
509 __mtx_lock_sleep(volatile uintptr_t *c, uintptr_t v, int opts, const char *file,
563 (opts & MTX_RECURSE) != 0,
567 opts &= ~MTX_RECURSE;
571 if (LOCK_LOG_TEST(&m->lock_object, opts))
576 opts &= ~MTX_RECURSE;
590 if (LOCK_LOG_TEST(&m->lock_object, opts))
723 _mtx_lock_spin_cookie(volatile uintptr_t *c, uintptr_t v, int opts,
772 if (LOCK_LOG_TEST(&m->lock_object, opts))
803 if (LOCK_LOG_TEST(&m->lock_object, opts))
825 thread_lock_validate(struct mtx *m, int opts, const char *file, int line)
837 opts | LOP_NEWORDER | LOP_EXCLUSIVE, file, line, NULL);
840 #define thread_lock_validate(m, opts, file, line) do { } while (0)
846 _thread_lock(struct thread *td, int opts, const char *file, int line)
875 thread_lock_flags_(td, opts, file, line);
883 thread_lock_flags_(struct thread *td, int opts, const char *file, int line)
931 thread_lock_validate(m, opts, file, line);
962 LOCK_LOG_LOCK("LOCK", &m->lock_object, opts, m->mtx_recurse, file,
964 WITNESS_LOCK(&m->lock_object, opts | LOP_EXCLUSIVE, file, line);
1035 __mtx_unlock_sleep(volatile uintptr_t *c, uintptr_t v, int opts,
1058 if (LOCK_LOG_TEST(&m->lock_object, opts))
1077 if (LOCK_LOG_TEST(&m->lock_object, opts))
1149 * `opts' with options contained in `opts' and name `name.' The optional
1154 _mtx_init(volatile uintptr_t *c, const char *name, const char *type, int opts)
1162 MPASS((opts & ~(MTX_SPIN | MTX_QUIET | MTX_RECURSE |
1169 if (opts & MTX_SPIN)
1174 if (opts & MTX_QUIET)
1176 if (opts & MTX_RECURSE)
1178 if ((opts & MTX_NOWITNESS) == 0)
1180 if (opts & MTX_DUPOK)
1182 if (opts & MTX_NOPROFILE)
1184 if (opts & MTX_NEW)