• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500-V1.0.1.40_1.0.68/src/linux/linux-2.6/fs/

Lines Matching refs:to

172 /* aio_ring_event: returns a pointer to the event at the given index from
267 * when the processes owning a context have all exited to encourage
317 * Waits on the given sync kiocb to complete.
332 * there is no way for any new requests to be submited or any of the
333 * io_* syscalls to be called on the context. However, there may be
334 * outstanding requests which hold references to the context; as they
365 * and the struct needs to be freed.
394 * Returns with kiocb->users set to 2. The io submit code path holds
422 /* Check if the completion queue has enough free space to
517 /* Must be done under the lock to serialise against cancellation.
569 * (Note: this routine is intended to be called only
584 * Note that on UML this *requires* PF_BORROWED_MM to be set, otherwise
598 * (Note: this routine is intended to be called only
614 * Queue up a kiocb to be retried. Assumes that the kiocb
618 * the kiocb (to tell the caller to activate the work
619 * queue to process it), or 0, if it found that it was
640 * Expects to be invoked with iocb->ki_ctx->lock
648 * needs to be non-blocking as far as possible, to avoid
649 * holding up other iocbs waiting to be serviced by the
652 * The trickier parts in this code have to do with
671 * operation to start until this one has returned and
675 * iteration. We want to remember that and enable the
679 * So, in order to be able to register a "kick", but
691 * This is so that aio_complete knows it doesn't need to
693 * INIT_LIST_HEAD because we don't want a kick_iocb to
708 * Now we are all set to call the retry method in async
710 * to point to the wait queue entry inside the currently
714 * cause the iocb to be kicked for continuation (through
732 * and know that there is more left to go,
747 * be safe to unconditionally queue the context into the
836 * Work queue handler triggered to process pending
867 * Called by kick_iocb to queue the kiocb for retry
868 * and if required activate the aio work queue to process
877 /* We're supposed to be the only path putting the iocb back on the run
897 * (aio_wake_function) to trigger a retry of the iocb.
934 * ref, no other paths have a way to get another ref
935 * - the sync task helpfully left a reference to itself in the iocb
946 * Check if the user asked us to deliver the result through an
947 * eventfd. The eventfd_signal() function is safe to be called
955 /* add a completion event to the ring buffer.
956 * must be done holding ctx->ctx_lock to prevent
1000 pr_debug("added to ring %p at [%lu]\n", iocb, tail);
1056 struct aio_timeout *to = (struct aio_timeout *)data;
1058 to->timed_out = 1;
1059 wake_up_process(to->p);
1062 static inline void init_timeout(struct aio_timeout *to)
1064 init_timer(&to->timer);
1065 to->timer.data = (unsigned long)to;
1066 to->timer.function = timeout_func;
1067 to->timed_out = 0;
1068 to->p = current;
1071 static inline void set_timeout(long start_jiffies, struct aio_timeout *to,
1074 to->timer.expires = start_jiffies + timespec_to_jiffies(ts);
1075 if (time_after(to->timer.expires, jiffies))
1076 add_timer(&to->timer);
1078 to->timed_out = 1;
1081 static inline void clear_timeout(struct aio_timeout *to)
1083 del_singleshot_timer_sync(&to->timer);
1097 struct aio_timeout to;
1100 /* needed to zero any padding within an entry (there shouldn't be
1117 dprintk("aio: lost an event due to EFAULT.\n");
1122 /* Good, event copied to userland, update counts. */
1141 init_timeout(&to);
1148 set_timeout(start_jiffies, &to, &ts);
1161 if (to.timed_out) /* Only check after read evt */
1179 dprintk("aio: lost an event due to EFAULT.\n");
1183 /* Good, event copied to userland, update counts. */
1189 clear_timeout(&to);
1225 * ctxp must not point to an aio_context that already exists, and
1226 * must be initialized to 0 prior to the call. On successful
1260 get_ioctx(ioctx); /* io_destroy() expects us to hold a ref */
1271 * implemented. May fail with -EFAULT if the context pointed to
1341 /* No need to retry anymore */
1501 * a kiocb (current->io_wait points to this wait queue
1550 req = aio_get_req(ctx); /* returns with 2 references to req */
1599 aio_put_req(req); /* drop extra ref to req */
1603 aio_put_req(req); /* drop extra ref to req */
1604 aio_put_req(req); /* drop i/o ref to req */
1609 * Queue the nr iocbs pointed to by iocbpp for processing. Returns
1614 * -EFAULT if any of the data structures point to invalid data. May
1617 * are available to queue any iocbs. Will return 0 if nr is 0. Will
1686 * Attempts to cancel an iocb previously passed to io_submit. If
1688 * copied into the memory pointed to by result without being placed
1690 * -EFAULT if any of the data structures pointed to are invalid.
1746 * Attempts to read at least min_nr events and up to nr events from
1750 * -EFAULT if any of the memory specified to is invalid. May return
1753 * timeout. Note that the timeout pointed to by when is relative and