summaryrefslogtreecommitdiff
path: root/fs/ntfs3/inode.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2022-03-03 21:43:29 +0300
committerMatthew Wilcox (Oracle) <willy@infradead.org>2022-05-08 21:28:56 +0300
commit44ab23b9b3c7a73c738b37a8f5f84adb7d66c267 (patch)
tree5ea3aff552b0cde6c47a22a96b1f10bd0546c6b7 /fs/ntfs3/inode.c
parent27a77913448fe976f7c1d5e4b5467a5fa1b2a195 (diff)
downloadlinux-44ab23b9b3c7a73c738b37a8f5f84adb7d66c267.tar.xz
ntfs3: Call ntfs_write_begin() and ntfs_write_end() directly
There is only one kind of write_begin/write_end aops, so we don't need to look up which aop it is, just make ntfs_write_begin() and ntfs_write_end() available to this file and call them directly. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Namjae Jeon <linkinjeon@kernel.org> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/ntfs3/inode.c')
-rw-r--r--fs/ntfs3/inode.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/fs/ntfs3/inode.c b/fs/ntfs3/inode.c
index 1364174cc6c9..bfd71f384e21 100644
--- a/fs/ntfs3/inode.c
+++ b/fs/ntfs3/inode.c
@@ -861,9 +861,8 @@ static int ntfs_get_block_write_begin(struct inode *inode, sector_t vbn,
bh_result, create, GET_BLOCK_WRITE_BEGIN);
}
-static int ntfs_write_begin(struct file *file, struct address_space *mapping,
- loff_t pos, u32 len, struct page **pagep,
- void **fsdata)
+int ntfs_write_begin(struct file *file, struct address_space *mapping,
+ loff_t pos, u32 len, struct page **pagep, void **fsdata)
{
int err;
struct inode *inode = mapping->host;
@@ -904,10 +903,9 @@ out:
/*
* ntfs_write_end - Address_space_operations::write_end.
*/
-static int ntfs_write_end(struct file *file, struct address_space *mapping,
- loff_t pos, u32 len, u32 copied, struct page *page,
- void *fsdata)
-
+int ntfs_write_end(struct file *file, struct address_space *mapping,
+ loff_t pos, u32 len, u32 copied, struct page *page,
+ void *fsdata)
{
struct inode *inode = mapping->host;
struct ntfs_inode *ni = ntfs_i(inode);