Lines Matching refs:tail
57 unsigned tail; member
148 unsigned tail; member
509 ring->head = ring->tail = 0; in aio_setup_ring()
930 unsigned tail) in refill_reqs_available() argument
936 if (head <= tail) in refill_reqs_available()
937 events_in_ring = tail - head; in refill_reqs_available()
939 events_in_ring = ctx->nr_events - (head - tail); in refill_reqs_available()
978 refill_reqs_available(ctx, head, ctx->tail); in user_refill_reqs_available()
1056 unsigned tail, pos, head; in aio_complete() local
1083 tail = ctx->tail; in aio_complete()
1084 pos = tail + AIO_EVENTS_OFFSET; in aio_complete()
1086 if (++tail >= ctx->nr_events) in aio_complete()
1087 tail = 0; in aio_complete()
1101 ctx, tail, iocb, iocb->ki_user_iocb, iocb->ki_user_data, in aio_complete()
1109 ctx->tail = tail; in aio_complete()
1113 ring->tail = tail; in aio_complete()
1119 refill_reqs_available(ctx, head, tail); in aio_complete()
1122 pr_debug("added to ring %p at [%u]\n", iocb, tail); in aio_complete()
1157 unsigned head, tail, pos; in aio_read_events_ring() local
1173 tail = ring->tail; in aio_read_events_ring()
1182 pr_debug("h%u t%u m%u\n", head, tail, ctx->nr_events); in aio_read_events_ring()
1184 if (head == tail) in aio_read_events_ring()
1188 tail %= ctx->nr_events; in aio_read_events_ring()
1195 avail = (head <= tail ? tail : ctx->nr_events) - head; in aio_read_events_ring()
1196 if (head == tail) in aio_read_events_ring()
1227 pr_debug("%li h%u t%u\n", ret, head, tail); in aio_read_events_ring()