Lines Matching defs:mtx
57 * ep->mtx, re-queueing items in level-triggered mode.
70 * > ep->mtx (per-eventpoll; sleepable; serializes most ops)
74 * nested inside ep->mtx, outside ep->lock)
80 * - ep->mtx is a sleepable mutex because the event delivery loop
87 * - Per-ep ep->mtx is preferred for scalability elsewhere. Events
91 * ep->mtx on both: outer first, target second. Since cycles are
92 * forbidden the set of live ep->mtx holds is always a strict chain,
101 * mtx - self
102 * rbr - ep->mtx
106 * refs - file->f_lock for adds; ep->mtx for removes;
108 * ws - ep->mtx
115 * rbn / rcu union - rbn: ep->mtx (while epi is linked in ep->rbr).
120 * pwqlist - ep->mtx for writes; POLLFREE clears pwq->whead
125 * rcu_dereference_check(mtx))
126 * event - ep->mtx for writes; lockless read in
163 * rollback. Caller holds ep->mtx.
174 * A and B both hold ep->mtx serially. B walks the rbtree with
176 * B and C both take ep->mtx; the loser sees fewer entries or an
302 struct mutex mtx;
393 * skip this machinery entirely and take only ep->mtx.
898 * descriptor. Must be called with "mtx" held.
912 /* call only when ep->mtx is held */
915 return rcu_dereference_check(epi->ws, lockdep_is_held(&epi->ep->mtx));
918 /* call only when ep->mtx is held */
932 /* call when ep->mtx cannot be held (ep_poll_callback) */
1041 mutex_destroy(&ep->mtx);
1054 * because the caller holds ep->mtx and eventpoll_release_file() blocks
1086 lockdep_assert_held(&ep->mtx);
1113 lockdep_assert_held(&ep->mtx);
1127 * ep->mtx. The rcu read side, reverse_path_check_proc(), does not make
1143 lockdep_assert_held(&ep->mtx);
1175 lockdep_assert_held(&ep->mtx);
1193 * file serializes with us via ep->mtx; ep_remove() transparently
1202 lockdep_assert_held(&ep->mtx);
1216 * Two passes under ep->mtx: first ep_drain_pollwaits() quiesces
1228 mutex_lock(&ep->mtx);
1231 mutex_unlock(&ep->mtx);
1287 mutex_lock_nested(&ep->mtx, depth);
1304 mutex_unlock(&ep->mtx);
1310 * the ep->mtx so we need to start from depth=1, such that mutex_lock_nested()
1346 mutex_lock(&ep->mtx);
1360 mutex_unlock(&ep->mtx);
1403 mutex_lock(&ep->mtx);
1410 mutex_unlock(&ep->mtx);
1427 mutex_init(&ep->mtx);
1445 * are protected by the "mtx" mutex, and ep_find() must be called with
1446 * "mtx" held.
1836 * tep->mtx at subclass 1 across the attach + rbtree insert to serialize
1837 * with the target side. RB tree ops are protected by @ep->mtx, which
1854 mutex_lock_nested(&tep->mtx, 1);
1859 mutex_unlock(&tep->mtx);
1871 mutex_unlock(&tep->mtx);
1878 * Must be called with "mtx" held.
1962 * has a match in the current file status. Must be called with "mtx" held.
1980 epi->event.data = event->data; /* protected by mtx */
2047 * Caller holds ep->mtx and the scan is active.
2074 * Re-poll under ep->mtx so userspace cannot change the item
2103 * by ep->mtx, and the poll callback queues to ovflist
2130 mutex_lock(&ep->mtx);
2135 * scan_batch; items cannot vanish while we hold ep->mtx.
2153 mutex_unlock(&ep->mtx);
2382 mutex_lock_nested(&ep->mtx, depth + 1);
2409 mutex_unlock(&ep->mtx);
2545 * Always takes ep->mtx. For EPOLL_CTL_ADD, additionally runs the
2553 * 0 success; ep->mtx held.
2554 * 1 success; ep->mtx held AND the full check ran under
2571 error = epoll_mutex_lock(&ep->mtx, nonblock);
2581 /* Full check needed: drop ep->mtx so we can take epnested_mutex. */
2582 mutex_unlock(&ep->mtx);
2597 error = epoll_mutex_lock(&ep->mtx, nonblock);
2613 mutex_unlock(&ep->mtx);
2667 * Look the target up in ep's RB tree. We hold ep->mtx, so the
2909 mutex_lock(&ep->mtx);
2915 mutex_unlock(&ep->mtx);