Lines Matching refs:wq

90  * @wq: the waitqueue to test for waiters
121 static inline int swait_active(struct swait_queue_head *wq)
123 return !list_empty(&wq->task_list);
128 * @wq: the waitqueue to test for waiters
130 * Returns true if @wq has waiting processes
134 static inline bool swq_has_sleeper(struct swait_queue_head *wq)
144 return swait_active(wq);
158 #define ___swait_event(wq, condition, state, ret, cmd) \
166 long __int = prepare_to_swait_event(&wq, &__wait, state);\
178 finish_swait(&wq, &__wait); \
182 #define __swait_event(wq, condition) \
183 (void)___swait_event(wq, condition, TASK_UNINTERRUPTIBLE, 0, \
186 #define swait_event_exclusive(wq, condition) \
190 __swait_event(wq, condition); \
193 #define __swait_event_timeout(wq, condition, timeout) \
194 ___swait_event(wq, ___wait_cond_timeout(condition), \
198 #define swait_event_timeout_exclusive(wq, condition, timeout) \
202 __ret = __swait_event_timeout(wq, condition, timeout); \
206 #define __swait_event_interruptible(wq, condition) \
207 ___swait_event(wq, condition, TASK_INTERRUPTIBLE, 0, \
210 #define swait_event_interruptible_exclusive(wq, condition) \
214 __ret = __swait_event_interruptible(wq, condition); \
218 #define __swait_event_interruptible_timeout(wq, condition, timeout) \
219 ___swait_event(wq, ___wait_cond_timeout(condition), \
223 #define swait_event_interruptible_timeout_exclusive(wq, condition, timeout)\
227 __ret = __swait_event_interruptible_timeout(wq, \
232 #define __swait_event_idle(wq, condition) \
233 (void)___swait_event(wq, condition, TASK_IDLE, 0, schedule())
237 * @wq: the waitqueue to wait on
241 * true. The @condition is checked each time the waitqueue @wq is woken up.
247 #define swait_event_idle_exclusive(wq, condition) \
251 __swait_event_idle(wq, condition); \
254 #define __swait_event_idle_timeout(wq, condition, timeout) \
255 ___swait_event(wq, ___wait_cond_timeout(condition), \
261 * @wq: the waitqueue to wait on
266 * true. The @condition is checked each time the waitqueue @wq is woken up.
278 #define swait_event_idle_timeout_exclusive(wq, condition, timeout) \
282 __ret = __swait_event_idle_timeout(wq, \