diff options
author | Jan Kara <jack@suse.cz> | 2021-05-24 13:02:30 +0200 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2021-07-13 14:29:00 +0200 |
commit | 7506ae6a7033f617ca5fea53e356fb1f7bd98010 (patch) | |
tree | 2f018aab5c218ed18d25d5c9521add9627010905 /include/linux/fs.h | |
parent | 730633f0b7f951726e87f912a6323641f674ae34 (diff) | |
download | lwn-7506ae6a7033f617ca5fea53e356fb1f7bd98010.tar.gz lwn-7506ae6a7033f617ca5fea53e356fb1f7bd98010.zip |
mm: Add functions to lock invalidate_lock for two mappings
Some operations such as reflinking blocks among files will need to lock
invalidate_lock for two mappings. Add helper functions to do that.
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r-- | include/linux/fs.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 90a80de37ad4..894ff2451793 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -849,6 +849,12 @@ static inline void filemap_invalidate_unlock_shared( void lock_two_nondirectories(struct inode *, struct inode*); void unlock_two_nondirectories(struct inode *, struct inode*); +void filemap_invalidate_lock_two(struct address_space *mapping1, + struct address_space *mapping2); +void filemap_invalidate_unlock_two(struct address_space *mapping1, + struct address_space *mapping2); + + /* * NOTE: in a 32bit arch with a preemptable kernel and * an UP compile the i_size_read/write must be atomic |