aboutsummaryrefslogtreecommitdiffstats
path: root/fs/netfs/direct_read.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/netfs/direct_read.c')
-rw-r--r--fs/netfs/direct_read.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/netfs/direct_read.c b/fs/netfs/direct_read.c
index e72c8b69b147..a05e13472baf 100644
--- a/fs/netfs/direct_read.c
+++ b/fs/netfs/direct_read.c
@@ -185,7 +185,8 @@ ssize_t netfs_unbuffered_read_iter_locked(struct kiocb *iocb, struct iov_iter *i
rreq = netfs_alloc_request(iocb->ki_filp->f_mapping, iocb->ki_filp,
iocb->ki_pos, orig_count,
- NETFS_DIO_READ);
+ iocb->ki_flags & IOCB_DIRECT ?
+ NETFS_DIO_READ : NETFS_UNBUFFERED_READ);
if (IS_ERR(rreq))
return PTR_ERR(rreq);