summaryrefslogtreecommitdiff
path: root/fs/kernfs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2015-05-07 11:19:14 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2015-05-11 08:13:13 -0400
commitecc087ff14352aed52b8e775b4511e7f9cfc64ec (patch)
tree46a1845f647b8d59e28c49be683949a179b2ecdd /fs/kernfs
parent5f2c4179e129bdc47870a81a65d0aff85aa18293 (diff)
new helper: free_page_put_link()
similar to kfree_put_link() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/kernfs')
-rw-r--r--fs/kernfs/symlink.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/fs/kernfs/symlink.c b/fs/kernfs/symlink.c
index f6aa2e5a76b4..db272528ab5b 100644
--- a/fs/kernfs/symlink.c
+++ b/fs/kernfs/symlink.c
@@ -126,11 +126,6 @@ static const char *kernfs_iop_follow_link(struct dentry *dentry, void **cookie)
return *cookie = (char *)page;
}
-static void kernfs_iop_put_link(struct inode *unused, void *cookie)
-{
- free_page((unsigned long)cookie);
-}
-
const struct inode_operations kernfs_symlink_iops = {
.setxattr = kernfs_iop_setxattr,
.removexattr = kernfs_iop_removexattr,
@@ -138,7 +133,7 @@ const struct inode_operations kernfs_symlink_iops = {
.listxattr = kernfs_iop_listxattr,
.readlink = generic_readlink,
.follow_link = kernfs_iop_follow_link,
- .put_link = kernfs_iop_put_link,
+ .put_link = free_page_put_link,
.setattr = kernfs_iop_setattr,
.getattr = kernfs_iop_getattr,
.permission = kernfs_iop_permission,