diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-03-21 11:06:46 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-04-09 14:13:02 -0400 |
commit | 4b8a8f1e4f94fd87747e6e3acef74cf0b4dc0dae (patch) | |
tree | fb45e867f1c548fb763b4283c7f57349374ab6a7 /fs/pipe.c | |
parent | 7bee130e222dfb3a7a70c0404dc09f104cddd7d6 (diff) |
get rid of the last free_pipe_info() callers
and rename __free_pipe_info() to free_pipe_info()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/pipe.c')
-rw-r--r-- | fs/pipe.c | 18 |
1 files changed, 6 insertions, 12 deletions
@@ -751,7 +751,7 @@ pipe_release(struct inode *inode, struct file *file) | |||
751 | __pipe_unlock(pipe); | 751 | __pipe_unlock(pipe); |
752 | 752 | ||
753 | if (kill) | 753 | if (kill) |
754 | __free_pipe_info(pipe); | 754 | free_pipe_info(pipe); |
755 | 755 | ||
756 | return 0; | 756 | return 0; |
757 | } | 757 | } |
@@ -795,7 +795,7 @@ struct pipe_inode_info *alloc_pipe_info(void) | |||
795 | return NULL; | 795 | return NULL; |
796 | } | 796 | } |
797 | 797 | ||
798 | void __free_pipe_info(struct pipe_inode_info *pipe) | 798 | void free_pipe_info(struct pipe_inode_info *pipe) |
799 | { | 799 | { |
800 | int i; | 800 | int i; |
801 | 801 | ||
@@ -810,12 +810,6 @@ void __free_pipe_info(struct pipe_inode_info *pipe) | |||
810 | kfree(pipe); | 810 | kfree(pipe); |
811 | } | 811 | } |
812 | 812 | ||
813 | void free_pipe_info(struct inode *inode) | ||
814 | { | ||
815 | __free_pipe_info(inode->i_pipe); | ||
816 | inode->i_pipe = NULL; | ||
817 | } | ||
818 | |||
819 | static struct vfsmount *pipe_mnt __read_mostly; | 813 | static struct vfsmount *pipe_mnt __read_mostly; |
820 | 814 | ||
821 | /* | 815 | /* |
@@ -911,12 +905,12 @@ int create_pipe_files(struct file **res, int flags) | |||
911 | err_file: | 905 | err_file: |
912 | put_filp(f); | 906 | put_filp(f); |
913 | err_dentry: | 907 | err_dentry: |
914 | free_pipe_info(inode); | 908 | free_pipe_info(inode->i_pipe); |
915 | path_put(&path); | 909 | path_put(&path); |
916 | return err; | 910 | return err; |
917 | 911 | ||
918 | err_inode: | 912 | err_inode: |
919 | free_pipe_info(inode); | 913 | free_pipe_info(inode->i_pipe); |
920 | iput(inode); | 914 | iput(inode); |
921 | return err; | 915 | return err; |
922 | } | 916 | } |
@@ -1039,7 +1033,7 @@ static int fifo_open(struct inode *inode, struct file *filp) | |||
1039 | if (unlikely(inode->i_pipe)) { | 1033 | if (unlikely(inode->i_pipe)) { |
1040 | inode->i_pipe->files++; | 1034 | inode->i_pipe->files++; |
1041 | spin_unlock(&inode->i_lock); | 1035 | spin_unlock(&inode->i_lock); |
1042 | __free_pipe_info(pipe); | 1036 | free_pipe_info(pipe); |
1043 | pipe = inode->i_pipe; | 1037 | pipe = inode->i_pipe; |
1044 | } else { | 1038 | } else { |
1045 | inode->i_pipe = pipe; | 1039 | inode->i_pipe = pipe; |
@@ -1143,7 +1137,7 @@ err: | |||
1143 | spin_unlock(&inode->i_lock); | 1137 | spin_unlock(&inode->i_lock); |
1144 | __pipe_unlock(pipe); | 1138 | __pipe_unlock(pipe); |
1145 | if (kill) | 1139 | if (kill) |
1146 | __free_pipe_info(pipe); | 1140 | free_pipe_info(pipe); |
1147 | return ret; | 1141 | return ret; |
1148 | } | 1142 | } |
1149 | 1143 | ||