Lines Matching refs:eventpoll
3 * fs/eventpoll.c (Efficient event retrieval implementation)
26 #include <linux/eventpoll.h>
125 * Each file descriptor added to the eventpoll interface will
132 /* RB tree node links this structure to the eventpoll RB tree */
138 /* List header used to link this structure to the eventpoll ready list */
142 * Works together "struct eventpoll"->ovflist in keeping the
153 * eventpoll->refcount orchestrates "struct eventpoll" disposal
161 struct eventpoll *ep;
175 * structure and represents the main data structure for the eventpoll
178 struct eventpoll {
212 /* The user that created the eventpoll descriptor */
256 static struct eventpoll *inserting_into;
379 * @ep: Pointer to the eventpoll context.
384 static inline int ep_events_available(struct eventpoll *ep)
393 struct eventpoll *ep = p;
404 static bool ep_busy_loop(struct eventpoll *ep, int nonblock)
429 struct eventpoll *ep;
461 static inline bool ep_busy_loop(struct eventpoll *ep, int nonblock)
499 static void ep_poll_safewake(struct eventpoll *ep, struct epitem *epi,
502 struct eventpoll *ep_src;
511 * protected. Thus, we are introducing a per eventpoll nest field.
538 static void ep_poll_safewake(struct eventpoll *ep, struct epitem *epi,
567 static void ep_unregister_pollwait(struct eventpoll *ep, struct epitem *epi)
616 static void ep_start_scan(struct eventpoll *ep, struct list_head *txlist)
633 static void ep_done_scan(struct eventpoll *ep,
688 static void ep_get(struct eventpoll *ep)
696 static bool ep_refcount_dec_and_test(struct eventpoll *ep)
705 static void ep_free(struct eventpoll *ep)
714 * Removes a "struct epitem" from the eventpoll RB tree and deallocates
719 * Returns true if the eventpoll can be disposed.
721 static bool __ep_remove(struct eventpoll *ep, struct epitem *epi, bool force)
765 * At this point it is safe to free the eventpoll item. Use the union
780 static void ep_remove_safe(struct eventpoll *ep, struct epitem *epi)
785 static void ep_clear_and_put(struct eventpoll *ep)
812 * Since we still own a reference to the eventpoll struct, the loop can't
831 struct eventpoll *ep = file->private_data;
843 struct eventpoll *ep = file->private_data;
906 struct eventpoll *ep = f->private_data;
927 /* File callbacks that implement the eventpoll file behaviour */
938 * This is called from eventpoll_release() to unlink files from the eventpoll
940 * closed without being removed from the eventpoll interface.
944 struct eventpoll *ep;
976 static int ep_alloc(struct eventpoll **pep)
978 struct eventpoll *ep;
1000 * Search the file inside the eventpoll tree. The RB tree operations
1004 static struct epitem *ep_find(struct eventpoll *ep, struct file *file, int fd)
1029 static struct epitem *ep_find_tfd(struct eventpoll *ep, int tfd, unsigned long toff)
1052 struct eventpoll *ep;
1133 struct eventpoll *ep = epi->ep;
1171 struct eventpoll *ep = epi->ep;
1214 * Wake up ( if active ) both the eventpoll wait list and the ->poll()
1299 static void ep_rbtree_insert(struct eventpoll *ep, struct epitem *epi)
1382 * eventpoll objects.
1409 epi->ep->ws = wakeup_source_register(NULL, "eventpoll");
1445 struct eventpoll *ep = NULL;
1477 static int ep_insert(struct eventpoll *ep, const struct epoll_event *event,
1484 struct eventpoll *tep = NULL;
1604 static int ep_modify(struct eventpoll *ep, struct epitem *epi,
1676 static int ep_send_events(struct eventpoll *ep,
1812 * @ep: Pointer to the eventpoll context.
1825 static int ep_poll(struct eventpoll *ep, struct epoll_event __user *events,
1955 * @ep: the &struct eventpoll to be currently checked.
1961 static int ep_loop_check_proc(struct eventpoll *ep, int depth)
1972 struct eventpoll *ep_tovisit;
2010 static int ep_loop_check(struct eventpoll *ep, struct eventpoll *to)
2028 * Open an eventpoll file descriptor.
2033 struct eventpoll *ep = NULL;
2042 * Create the internal data structure ("struct eventpoll").
2048 * Creates all the items needed to setup an eventpoll file. That is,
2056 file = anon_inode_getfile("[eventpoll]", &eventpoll_fops, ep,
2117 struct eventpoll *ep;
2119 struct eventpoll *tep = NULL;
2142 * the user passed to us _is_ an eventpoll file. And also we do not permit
2226 * The eventpoll itself is still alive: the refcount
2264 * the eventpoll file that enables the insertion/removal/change of
2280 * Implement the event wait interface for the eventpoll file. It is the kernel
2288 struct eventpoll *ep;
2298 /* Get the "struct file *" for the eventpoll file */
2305 * the user passed to us _is_ an eventpoll file.
2335 * Implement the event wait interface for the eventpoll file. It is the kernel