diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2023-03-06 11:36:24 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2023-12-18 21:07:29 -0500 |
commit | 6628f69ee66a24602a6007ecfb9ab66390475b98 (patch) | |
tree | fac3c61110bcec58b203da437bbfd2b7f76d1e85 /fs/minix/namei.c | |
parent | ee0d27c90777da4c1da633aa7b91dbafd176c0c4 (diff) | |
download | lwn-6628f69ee66a24602a6007ecfb9ab66390475b98.tar.gz lwn-6628f69ee66a24602a6007ecfb9ab66390475b98.zip |
minixfs: Use dir_put_page() in minix_unlink() and minix_rename()
... rather than open-coding it there. Counterpart of the
corresponding fs/sysv commit from Fabio's series...
Reviewed-by: Fabio M. De Francesco <fabio.maria.de.francesco@linux.intel.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/minix/namei.c')
-rw-r--r-- | fs/minix/namei.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/fs/minix/namei.c b/fs/minix/namei.c index 114084d5636a..20923a15e30a 100644 --- a/fs/minix/namei.c +++ b/fs/minix/namei.c @@ -149,8 +149,7 @@ static int minix_unlink(struct inode * dir, struct dentry *dentry) if (!de) return -ENOENT; err = minix_delete_entry(de, page); - kunmap(page); - put_page(page); + dir_put_page(page); if (err) return err; @@ -242,13 +241,10 @@ static int minix_rename(struct mnt_idmap *idmap, inode_dec_link_count(old_dir); } out_dir: - if (dir_de) { - kunmap(dir_page); - put_page(dir_page); - } + if (dir_de) + dir_put_page(dir_page); out_old: - kunmap(old_page); - put_page(old_page); + dir_put_page(old_page); out: return err; } |