Commit 652efdec authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Christian Brauner

xfs: don't call xfs_file_open from xfs_dir_open

Directories do not support direct I/O and thus no non-blocking direct
I/O either.  Open code the shutdown check and call to generic_file_open
instead.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20240423124608.537794-4-hch@lst.deReviewed-by: default avatarDarrick J. Wong <djwong@kernel.org>
Signed-off-by: default avatarChristian Brauner <brauner@kernel.org>
parent f5080571
......@@ -1243,7 +1243,9 @@ xfs_dir_open(
unsigned int mode;
int error;
error = xfs_file_open(inode, file);
if (xfs_is_shutdown(ip->i_mount))
return -EIO;
error = generic_file_open(inode, file);
if (error)
return error;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment