aboutsummaryrefslogtreecommitdiff
path: root/fs/ext4/file.c
diff options
context:
space:
mode:
authorChristoph Hellwig <[email protected]>2024-02-29 19:54:12 +0530
committerTheodore Ts'o <[email protected]>2024-05-02 10:53:32 -0400
commita0c7cce824a54dbb83bb722df19f1ddcfa5f8d25 (patch)
tree726a85c2986f4af9b68aca306a98603d68cd0260 /fs/ext4/file.c
parent53c17fe55a06cbb405b94d96759611d725d2c47a (diff)
ext4: set FMODE_CAN_ODIRECT instead of a dummy direct_IO method
Since commit a2ad63daa88b ("VFS: add FMODE_CAN_ODIRECT file flag") file systems can just set the FMODE_CAN_ODIRECT flag at open time instead of wiring up a dummy direct_IO method to indicate support for direct I/O. Signed-off-by: Christoph Hellwig <[email protected]> [RH: Rebased to upstream] Signed-off-by: Ritesh Harjani (IBM) <[email protected]> Reviewed-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/e5797bb597219a49043e53e4e90aa494b97dc328.1709215665.git.ritesh.list@gmail.com Signed-off-by: Theodore Ts'o <[email protected]>
Diffstat (limited to 'fs/ext4/file.c')
-rw-r--r--fs/ext4/file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/file.c b/fs/ext4/file.c
index 54d6ff22585c..965febab1d04 100644
--- a/fs/ext4/file.c
+++ b/fs/ext4/file.c
@@ -886,7 +886,7 @@ static int ext4_file_open(struct inode *inode, struct file *filp)
}
filp->f_mode |= FMODE_NOWAIT | FMODE_BUF_RASYNC |
- FMODE_DIO_PARALLEL_WRITE;
+ FMODE_DIO_PARALLEL_WRITE | FMODE_CAN_ODIRECT;
return dquot_file_open(inode, filp);
}