Lines Matching refs:mtx
267 struct mtx mtx; member
269 pthread_mutex_t mtx;
286 mtx_init(&(sc)->mtx, "BHND NVRAM store lock", NULL, MTX_DEF)
287 #define BHND_NVSTORE_LOCK(sc) mtx_lock(&(sc)->mtx)
288 #define BHND_NVSTORE_UNLOCK(sc) mtx_unlock(&(sc)->mtx)
289 #define BHND_NVSTORE_LOCK_ASSERT(sc, what) mtx_assert(&(sc)->mtx, what)
290 #define BHND_NVSTORE_LOCK_DESTROY(sc) mtx_destroy(&(sc)->mtx)
295 int error = pthread_mutex_init(&(sc)->mtx, NULL); \
301 #define BHND_NVSTORE_LOCK(sc) pthread_mutex_lock(&(sc)->mtx)
302 #define BHND_NVSTORE_UNLOCK(sc) pthread_mutex_unlock(&(sc)->mtx)
303 #define BHND_NVSTORE_LOCK_DESTROY(sc) pthread_mutex_destroy(&(sc)->mtx)