aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/aio.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/aio.h')
-rw-r--r--include/linux/aio.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/include/linux/aio.h b/include/linux/aio.h
index a30ef13c9e62..b903fc02bdb7 100644
--- a/include/linux/aio.h
+++ b/include/linux/aio.h
@@ -119,6 +119,12 @@ struct kiocb {
119 119
120 struct list_head ki_list; /* the aio core uses this 120 struct list_head ki_list; /* the aio core uses this
121 * for cancellation */ 121 * for cancellation */
122
123 /*
124 * If the aio_resfd field of the userspace iocb is not zero,
125 * this is the underlying file* to deliver event to.
126 */
127 struct file *ki_eventfd;
122}; 128};
123 129
124#define is_sync_kiocb(iocb) ((iocb)->ki_key == KIOCB_SYNC_KEY) 130#define is_sync_kiocb(iocb) ((iocb)->ki_key == KIOCB_SYNC_KEY)
@@ -226,7 +232,8 @@ int FASTCALL(io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb,
226 __put_ioctx(kioctx); \ 232 __put_ioctx(kioctx); \
227} while (0) 233} while (0)
228 234
229#define in_aio() !is_sync_wait(current->io_wait) 235#define in_aio() (unlikely(!is_sync_wait(current->io_wait)))
236
230/* may be used for debugging */ 237/* may be used for debugging */
231#define warn_if_async() \ 238#define warn_if_async() \
232do { \ 239do { \