Lines Matching refs:mutex

23 Mutexes are represented by 'struct mutex', defined in include/linux/mutex.h
24 and implemented in kernel/locking/mutex.c. These locks use an atomic variable
34 When acquiring a mutex, there are three possible paths that can be
46 soon. The mutex spinners are queued up using MCS lock so that only
47 one spinner can compete for the mutex.
58 waiting to spin on mutex owner, only to go directly to slowpath upon
75 The mutex subsystem checks and enforces the following rules:
77 - Only one task can hold the mutex at a time.
78 - Only the owner can unlock the mutex.
81 - A mutex must only be initialized via the API (see below).
82 - A task may not exit with a mutex held.
89 In addition, the mutex debugging code also implements a number of other
104 Statically define the mutex:
107 Dynamically initialize the mutex:
108 mutex_init(mutex);
110 Acquire the mutex, uninterruptible:
111 void mutex_lock(struct mutex *lock);
112 void mutex_lock_nested(struct mutex *lock, unsigned int subclass);
113 int mutex_trylock(struct mutex *lock);
115 Acquire the mutex, interruptible:
116 int mutex_lock_interruptible_nested(struct mutex *lock,
118 int mutex_lock_interruptible(struct mutex *lock);
120 Acquire the mutex, interruptible, if dec to 0:
121 int atomic_dec_and_mutex_lock(atomic_t *cnt, struct mutex *lock);
123 Unlock the mutex:
124 void mutex_unlock(struct mutex *lock);
126 Test if the mutex is taken:
127 int mutex_is_locked(struct mutex *lock);
132 Unlike its original design and purpose, 'struct mutex' is among the largest