mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 17:47:41 +02:00
exfat: add exfat_file_open()
Add exfat_file_open() to handle file open operation for exFAT. This change is a preparation step before introducing iomap-based direct IO support. Acked-by: Christoph Hellwig <hch@lst.de> Acked-by: "Darrick J. Wong" <djwong@kernel.org> Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
This commit is contained in:
parent
3474416bb9
commit
a095c12ef1
|
|
@ -813,7 +813,16 @@ static ssize_t exfat_splice_read(struct file *in, loff_t *ppos,
|
|||
return filemap_splice_read(in, ppos, pipe, len, flags);
|
||||
}
|
||||
|
||||
static int exfat_file_open(struct inode *inode, struct file *filp)
|
||||
{
|
||||
if (unlikely(exfat_forced_shutdown(inode->i_sb)))
|
||||
return -EIO;
|
||||
|
||||
return generic_file_open(inode, filp);
|
||||
}
|
||||
|
||||
const struct file_operations exfat_file_operations = {
|
||||
.open = exfat_file_open,
|
||||
.llseek = generic_file_llseek,
|
||||
.read_iter = exfat_file_read_iter,
|
||||
.write_iter = exfat_file_write_iter,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user