diff options
author | Matthew Wilcox (Oracle) <willy@infradead.org> | 2023-09-21 22:07:45 +0200 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2023-10-25 20:31:29 +0200 |
commit | c2d20492e28c1071abfdc079f4d34acaf965b9b4 (patch) | |
tree | 9834c8092499a88f4459f7d43b21bca4b9e20952 /fs/ext2/ext2.h | |
parent | ext2: Convert ext2_delete_entry() to use folios (diff) | |
download | linux-c2d20492e28c1071abfdc079f4d34acaf965b9b4.tar.xz linux-c2d20492e28c1071abfdc079f4d34acaf965b9b4.zip |
ext2: Convert ext2_unlink() and ext2_rename() to use folios
This involves changing ext2_find_entry(), ext2_dotdot(),
ext2_inode_by_name(), ext2_set_link() and ext2_delete_entry() to
take a folio. These were also the last users of ext2_get_page() and
ext2_put_page(), so remove those at the same time.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Jan Kara <jack@suse.cz>
Message-Id: <20230921200746.3303942-8-willy@infradead.org>
Diffstat (limited to 'fs/ext2/ext2.h')
-rw-r--r-- | fs/ext2/ext2.h | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/fs/ext2/ext2.h b/fs/ext2/ext2.h index 7fdd685c384d..677a9ad45dcb 100644 --- a/fs/ext2/ext2.h +++ b/fs/ext2/ext2.h @@ -717,22 +717,17 @@ extern void ext2_init_block_alloc_info(struct inode *); extern void ext2_rsv_window_add(struct super_block *sb, struct ext2_reserve_window_node *rsv); /* dir.c */ -extern int ext2_add_link (struct dentry *, struct inode *); -extern int ext2_inode_by_name(struct inode *dir, +int ext2_add_link(struct dentry *, struct inode *); +int ext2_inode_by_name(struct inode *dir, const struct qstr *child, ino_t *ino); -extern int ext2_make_empty(struct inode *, struct inode *); -extern struct ext2_dir_entry_2 *ext2_find_entry(struct inode *, const struct qstr *, - struct page **); -extern int ext2_delete_entry(struct ext2_dir_entry_2 *dir, struct page *page); -extern int ext2_empty_dir (struct inode *); -extern struct ext2_dir_entry_2 *ext2_dotdot(struct inode *dir, struct page **p); +int ext2_make_empty(struct inode *, struct inode *); +struct ext2_dir_entry_2 *ext2_find_entry(struct inode *, const struct qstr *, + struct folio **foliop); +int ext2_delete_entry(struct ext2_dir_entry_2 *dir, struct folio *folio); +int ext2_empty_dir(struct inode *); +struct ext2_dir_entry_2 *ext2_dotdot(struct inode *dir, struct folio **foliop); int ext2_set_link(struct inode *dir, struct ext2_dir_entry_2 *de, - struct page *page, struct inode *inode, bool update_times); -static inline void ext2_put_page(struct page *page, void *page_addr) -{ - kunmap_local(page_addr); - put_page(page); -} + struct folio *folio, struct inode *inode, bool update_times); /* ialloc.c */ extern struct inode * ext2_new_inode (struct inode *, umode_t, const struct qstr *); |