diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-09-01 15:57:51 -0400 |
---|---|---|
committer | Chris Mason <chris.mason@fusionio.com> | 2013-11-15 09:18:14 -0500 |
commit | 54563d41a58be77e9bd9ef7af1ea4026cf0e7e07 (patch) | |
tree | 5aedb277d3ed8e43f42af1077ebc72699f4d44b1 /fs/btrfs/ioctl.c | |
parent | 46e0f66a0cf9e1fe25bfdcf4a60c08aface85998 (diff) |
btrfs: get rid of fdentry()
3 of 4 callers actually want file_inode()...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'fs/btrfs/ioctl.c')
-rw-r--r-- | fs/btrfs/ioctl.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c index 64a0876c7872..a111622598b0 100644 --- a/fs/btrfs/ioctl.c +++ b/fs/btrfs/ioctl.c | |||
@@ -320,7 +320,7 @@ static int btrfs_ioctl_getversion(struct file *file, int __user *arg) | |||
320 | 320 | ||
321 | static noinline int btrfs_ioctl_fitrim(struct file *file, void __user *arg) | 321 | static noinline int btrfs_ioctl_fitrim(struct file *file, void __user *arg) |
322 | { | 322 | { |
323 | struct btrfs_fs_info *fs_info = btrfs_sb(fdentry(file)->d_sb); | 323 | struct btrfs_fs_info *fs_info = btrfs_sb(file_inode(file)->i_sb); |
324 | struct btrfs_device *device; | 324 | struct btrfs_device *device; |
325 | struct request_queue *q; | 325 | struct request_queue *q; |
326 | struct fstrim_range range; | 326 | struct fstrim_range range; |
@@ -2089,7 +2089,7 @@ static noinline int btrfs_ioctl_ino_lookup(struct file *file, | |||
2089 | static noinline int btrfs_ioctl_snap_destroy(struct file *file, | 2089 | static noinline int btrfs_ioctl_snap_destroy(struct file *file, |
2090 | void __user *arg) | 2090 | void __user *arg) |
2091 | { | 2091 | { |
2092 | struct dentry *parent = fdentry(file); | 2092 | struct dentry *parent = file->f_path.dentry; |
2093 | struct dentry *dentry; | 2093 | struct dentry *dentry; |
2094 | struct inode *dir = parent->d_inode; | 2094 | struct inode *dir = parent->d_inode; |
2095 | struct inode *inode; | 2095 | struct inode *inode; |
@@ -3105,7 +3105,7 @@ out: | |||
3105 | static noinline long btrfs_ioctl_clone(struct file *file, unsigned long srcfd, | 3105 | static noinline long btrfs_ioctl_clone(struct file *file, unsigned long srcfd, |
3106 | u64 off, u64 olen, u64 destoff) | 3106 | u64 off, u64 olen, u64 destoff) |
3107 | { | 3107 | { |
3108 | struct inode *inode = fdentry(file)->d_inode; | 3108 | struct inode *inode = file_inode(file); |
3109 | struct btrfs_root *root = BTRFS_I(inode)->root; | 3109 | struct btrfs_root *root = BTRFS_I(inode)->root; |
3110 | struct fd src_file; | 3110 | struct fd src_file; |
3111 | struct inode *src; | 3111 | struct inode *src; |
@@ -4304,7 +4304,7 @@ static long btrfs_ioctl_quota_rescan_status(struct file *file, void __user *arg) | |||
4304 | 4304 | ||
4305 | static long btrfs_ioctl_quota_rescan_wait(struct file *file, void __user *arg) | 4305 | static long btrfs_ioctl_quota_rescan_wait(struct file *file, void __user *arg) |
4306 | { | 4306 | { |
4307 | struct btrfs_root *root = BTRFS_I(fdentry(file)->d_inode)->root; | 4307 | struct btrfs_root *root = BTRFS_I(file_inode(file))->root; |
4308 | 4308 | ||
4309 | if (!capable(CAP_SYS_ADMIN)) | 4309 | if (!capable(CAP_SYS_ADMIN)) |
4310 | return -EPERM; | 4310 | return -EPERM; |