]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - fs/xfs/xfs_dfrag.c
dlm: use idr_for_each_entry() in recover_idr_clear() error path
[karo-tx-linux.git] / fs / xfs / xfs_dfrag.c
index a8bd26b82ecb00dd14063da4c62c1a64011f0caa..f852b082a0844abf3f8fbfea601589c0c162a9c7 100644 (file)
@@ -78,14 +78,14 @@ xfs_swapext(
                goto out_put_tmp_file;
        }
 
-       if (IS_SWAPFILE(f.file->f_path.dentry->d_inode) ||
-           IS_SWAPFILE(tmp.file->f_path.dentry->d_inode)) {
+       if (IS_SWAPFILE(file_inode(f.file)) ||
+           IS_SWAPFILE(file_inode(tmp.file))) {
                error = XFS_ERROR(EINVAL);
                goto out_put_tmp_file;
        }
 
-       ip = XFS_I(f.file->f_path.dentry->d_inode);
-       tip = XFS_I(tmp.file->f_path.dentry->d_inode);
+       ip = XFS_I(file_inode(f.file));
+       tip = XFS_I(file_inode(tmp.file));
 
        if (ip->i_mount != tip->i_mount) {
                error = XFS_ERROR(EINVAL);