Lines Matching defs:wait
25 #include <linux/wait.h>
157 /* Number of active wait queue attached to poll operations */
160 /* List containing poll wait queues */
243 * Wait queue item that will be linked to the target file wait
246 wait_queue_entry_t wait;
248 /* The wait queue head that linked the "wait" wait queue item */
345 return container_of(p, struct eppoll_entry, wait);
348 /* Get the "struct epitem" from a wait queue pointer */
351 return container_of(p, struct eppoll_entry, wait)->base;
526 * the use of wait queues used by epoll is done in a very controlled
541 * the waiters on its poll wait list (efd2). So it calls ep_poll_safewake()
611 remove_wait_queue(whead, &pwq->wait);
782 * Removes poll wait queue hooks.
931 static __poll_t ep_eventpoll_poll(struct file *file, poll_table *wait)
936 /* Insert inside our poll wait queue */
937 poll_wait(file, &ep->poll_wait, wait);
1195 * This is the callback that is passed to the wait queue wakeup
1207 * with several wait queues entries. Plural wakeup from different CPUs of a
1208 * single wait queue is serialized by wq.lock, but the case when multiple wait
1212 static int ep_poll_callback(wait_queue_entry_t *wait, unsigned mode, int sync, void *key)
1215 struct epitem *epi = ep_item_from_wait(wait);
1259 * Wake up ( if active ) both the eventpoll wait list and the ->poll()
1260 * wait list.
1300 list_del_init(&wait->entry);
1305 * ep/epi or even wait.
1307 smp_store_release(&ep_pwq_from_wait(wait)->whead, NULL);
1314 * This is the callback that is used to add our wait queue to the
1324 init_waitqueue_func_entry(&pwq->wait, ep_poll_callback);
1328 add_wait_queue_exclusive(whead, &pwq->wait);
1330 add_wait_queue(whead, &pwq->wait);
1487 * wait for ep_pm_stay_awake_rcu to finish, synchronize_rcu is
1562 * We have to check if something went wrong during the poll wait queue
1563 * install process. Namely an allocation for a wait queue failed due
1609 * allocated wait queue. Note that we don't care about the ep->ovflist
1850 wait_queue_entry_t wait;
1863 * Avoid the unnecessary trip to the wait queue loop, if the
1897 * thus wait entry is removed from the wait queue on each
1907 * unconditionally removes, because we don't reuse the wait
1912 init_wait(&wait);
1913 wait.func = ep_autoremove_wake_function;
1935 __add_wait_queue_exclusive(&ep->wq, &wait);
1945 * If timed out and still on the wait queue, recheck eavail
1953 if (!list_empty_careful(&wait.entry)) {
1956 * If the thread timed out and is not on the wait queue, it
1958 * before it could reacquire the lock. Thus, when wait.entry is
1962 eavail = list_empty(&wait.entry);
1963 __remove_wait_queue(&ep->wq, &wait);
2326 * Implement the event wait interface for the eventpoll file. It is the kernel
2378 * Implement the event wait interface for the eventpoll file. It is the kernel
2388 * If the caller wants a certain signal mask to be set during the wait,
2411 * If the caller wants a certain signal mask to be set during the wait,