forked from Minki/linux
fs: Remove noop_invalidatepage()
We used to have to use noop_invalidatepage() to prevent block_invalidatepage() from being called, but that behaviour is now gone. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Tested-by: Damien Le Moal <damien.lemoal@opensource.wdc.com> Acked-by: Damien Le Moal <damien.lemoal@opensource.wdc.com> Tested-by: Mike Marshall <hubcap@omnibond.com> # orangefs Tested-by: David Howells <dhowells@redhat.com> # afs
This commit is contained in:
parent
7ba13abbd3
commit
5660a8630d
@ -347,7 +347,6 @@ static unsigned long dax_get_unmapped_area(struct file *filp,
|
||||
|
||||
static const struct address_space_operations dev_dax_aops = {
|
||||
.set_page_dirty = __set_page_dirty_no_writeback,
|
||||
.invalidatepage = noop_invalidatepage,
|
||||
};
|
||||
|
||||
static int dax_open(struct inode *inode, struct file *filp)
|
||||
|
@ -1001,7 +1001,6 @@ static const struct address_space_operations ext2_dax_aops = {
|
||||
.writepages = ext2_dax_writepages,
|
||||
.direct_IO = noop_direct_IO,
|
||||
.set_page_dirty = __set_page_dirty_no_writeback,
|
||||
.invalidatepage = noop_invalidatepage,
|
||||
};
|
||||
|
||||
/*
|
||||
|
@ -3632,7 +3632,6 @@ static const struct address_space_operations ext4_dax_aops = {
|
||||
.direct_IO = noop_direct_IO,
|
||||
.set_page_dirty = __set_page_dirty_no_writeback,
|
||||
.bmap = ext4_bmap,
|
||||
.invalidatepage = noop_invalidatepage,
|
||||
.swap_activate = ext4_iomap_swap_activate,
|
||||
};
|
||||
|
||||
|
@ -1327,7 +1327,6 @@ static const struct address_space_operations fuse_dax_file_aops = {
|
||||
.writepages = fuse_dax_writepages,
|
||||
.direct_IO = noop_direct_IO,
|
||||
.set_page_dirty = __set_page_dirty_no_writeback,
|
||||
.invalidatepage = noop_invalidatepage,
|
||||
};
|
||||
|
||||
static bool fuse_should_enable_dax(struct inode *inode, unsigned int flags)
|
||||
|
11
fs/libfs.c
11
fs/libfs.c
@ -1198,17 +1198,6 @@ int noop_fsync(struct file *file, loff_t start, loff_t end, int datasync)
|
||||
}
|
||||
EXPORT_SYMBOL(noop_fsync);
|
||||
|
||||
void noop_invalidatepage(struct page *page, unsigned int offset,
|
||||
unsigned int length)
|
||||
{
|
||||
/*
|
||||
* There is no page cache to invalidate in the dax case, however
|
||||
* we need this callback defined to prevent falling back to
|
||||
* block_invalidatepage() in do_invalidatepage().
|
||||
*/
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(noop_invalidatepage);
|
||||
|
||||
ssize_t noop_direct_IO(struct kiocb *iocb, struct iov_iter *iter)
|
||||
{
|
||||
/*
|
||||
|
@ -582,6 +582,5 @@ const struct address_space_operations xfs_dax_aops = {
|
||||
.writepages = xfs_dax_writepages,
|
||||
.direct_IO = noop_direct_IO,
|
||||
.set_page_dirty = __set_page_dirty_no_writeback,
|
||||
.invalidatepage = noop_invalidatepage,
|
||||
.swap_activate = xfs_iomap_swapfile_activate,
|
||||
};
|
||||
|
@ -3323,8 +3323,6 @@ extern int simple_rename(struct user_namespace *, struct inode *,
|
||||
extern void simple_recursive_removal(struct dentry *,
|
||||
void (*callback)(struct dentry *));
|
||||
extern int noop_fsync(struct file *, loff_t, loff_t, int);
|
||||
extern void noop_invalidatepage(struct page *page, unsigned int offset,
|
||||
unsigned int length);
|
||||
extern ssize_t noop_direct_IO(struct kiocb *iocb, struct iov_iter *iter);
|
||||
extern int simple_empty(struct dentry *);
|
||||
extern int simple_write_begin(struct file *file, struct address_space *mapping,
|
||||
|
Loading…
Reference in New Issue
Block a user