aio is unlikely
Stick an unlikely() around is_aio(): I assert that most IO is synchronous. Cc: Suparna Bhattacharya <suparna@in.ibm.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Benjamin LaHaise <bcrl@kvack.org> Cc: Zach Brown <zach.brown@oracle.com> Cc: Ulrich Drepper <drepper@redhat.com> Cc: Christoph Hellwig <hch@lst.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Родитель
b41eeef14d
Коммит
b8522ead35
|
@ -226,7 +226,8 @@ int FASTCALL(io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb,
|
|||
__put_ioctx(kioctx); \
|
||||
} while (0)
|
||||
|
||||
#define in_aio() !is_sync_wait(current->io_wait)
|
||||
#define in_aio() (unlikely(!is_sync_wait(current->io_wait)))
|
||||
|
||||
/* may be used for debugging */
|
||||
#define warn_if_async() \
|
||||
do { \
|
||||
|
|
Загрузка…
Ссылка в новой задаче