summaryrefslogtreecommitdiffstats
path: root/fs/nilfs2/cpfile.h
diff options
context:
space:
mode:
authorRyusuke Konishi <konishi.ryusuke@gmail.com>2024-01-22 23:02:00 +0900
committerAndrew Morton <akpm@linux-foundation.org>2024-02-22 15:38:53 -0800
commit1244a6d7a2c1de669f9682e8a0bd46a53c3be233 (patch)
tree3935275b9db3fb90251505975ad34e8d1e9d8226 /fs/nilfs2/cpfile.h
parentcce259b4c3b13a82541992c56f9c8238451da859 (diff)
downloadlinux-1244a6d7a2c1de669f9682e8a0bd46a53c3be233.tar.gz
linux-1244a6d7a2c1de669f9682e8a0bd46a53c3be233.tar.bz2
linux-1244a6d7a2c1de669f9682e8a0bd46a53c3be233.zip
nilfs2: localize highmem mapping for checkpoint reading within cpfile
Move the code for reading from a checkpoint entry that is performed in nilfs_attach_checkpoint() to the cpfile side, and make the page mapping local and temporary. And use kmap_local instead of kmap to access the checkpoint entry page. In order to load the ifile inode information included in the checkpoint entry within the inode lock section of nilfs_ifile_read(), the newly added checkpoint reading method nilfs_cpfile_read_checkpoint() is called indirectly via nilfs_ifile_read() instead of from nilfs_attach_checkpoint(). Link: https://lkml.kernel.org/r/20240122140202.6950-14-konishi.ryusuke@gmail.com Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'fs/nilfs2/cpfile.h')
-rw-r--r--fs/nilfs2/cpfile.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nilfs2/cpfile.h b/fs/nilfs2/cpfile.h
index aa1408a3af01..2cfa14011bc8 100644
--- a/fs/nilfs2/cpfile.h
+++ b/fs/nilfs2/cpfile.h
@@ -19,6 +19,8 @@
int nilfs_cpfile_get_checkpoint(struct inode *, __u64, int,
struct nilfs_checkpoint **,
struct buffer_head **);
+int nilfs_cpfile_read_checkpoint(struct inode *cpfile, __u64 cno,
+ struct nilfs_root *root, struct inode *ifile);
int nilfs_cpfile_create_checkpoint(struct inode *cpfile, __u64 cno);
void nilfs_cpfile_put_checkpoint(struct inode *, __u64, struct buffer_head *);
int nilfs_cpfile_finalize_checkpoint(struct inode *cpfile, __u64 cno,