Skip to content

Commit 2e85abf

Browse files
committed
mm: allow read-ahead with IOCB_NOWAIT set
The read-ahead shouldn't block, so allow it to be done even if IOCB_NOWAIT is set in the kiocb. Acked-by: Johannes Weiner <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
1 parent b63534c commit 2e85abf

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

mm/filemap.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2028,8 +2028,6 @@ ssize_t generic_file_buffered_read(struct kiocb *iocb,
20282028

20292029
page = find_get_page(mapping, index);
20302030
if (!page) {
2031-
if (iocb->ki_flags & IOCB_NOWAIT)
2032-
goto would_block;
20332031
page_cache_sync_readahead(mapping,
20342032
ra, filp,
20352033
index, last_index - index);

0 commit comments

Comments
 (0)