diff options
author | Sage Weil <sage@newdream.net> | 2011-05-24 16:06:14 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2011-05-26 07:26:53 -0400 |
commit | 051e8f0ee23c9ca963e2a0208153c6cd475f05fb (patch) | |
tree | a6fe507530abb5b134f20d1929aaf9fa85311f16 | |
parent | 51892bbb57e87854c27c105317797823f8891e68 (diff) |
ceph: remove unnecessary dentry_unhash calls
Ceph does not need these, and they screw up our use of the dcache as a
consistent cache.
Signed-off-by: Sage Weil <sage@newdream.net>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | fs/ceph/dir.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/fs/ceph/dir.c b/fs/ceph/dir.c index 377b96404235..1a867a3601ae 100644 --- a/fs/ceph/dir.c +++ b/fs/ceph/dir.c | |||
@@ -827,9 +827,6 @@ static int ceph_unlink(struct inode *dir, struct dentry *dentry) | |||
827 | int err = -EROFS; | 827 | int err = -EROFS; |
828 | int op; | 828 | int op; |
829 | 829 | ||
830 | if ((dentry->d_inode->i_mode & S_IFMT) == S_IFDIR) | ||
831 | dentry_unhash(dentry); | ||
832 | |||
833 | if (ceph_snap(dir) == CEPH_SNAPDIR) { | 830 | if (ceph_snap(dir) == CEPH_SNAPDIR) { |
834 | /* rmdir .snap/foo is RMSNAP */ | 831 | /* rmdir .snap/foo is RMSNAP */ |
835 | dout("rmsnap dir %p '%.*s' dn %p\n", dir, dentry->d_name.len, | 832 | dout("rmsnap dir %p '%.*s' dn %p\n", dir, dentry->d_name.len, |
@@ -869,9 +866,6 @@ static int ceph_rename(struct inode *old_dir, struct dentry *old_dentry, | |||
869 | struct ceph_mds_request *req; | 866 | struct ceph_mds_request *req; |
870 | int err; | 867 | int err; |
871 | 868 | ||
872 | if (new_dentry->d_inode && S_ISDIR(new_dentry->d_inode->i_mode)) | ||
873 | dentry_unhash(new_dentry); | ||
874 | |||
875 | if (ceph_snap(old_dir) != ceph_snap(new_dir)) | 869 | if (ceph_snap(old_dir) != ceph_snap(new_dir)) |
876 | return -EXDEV; | 870 | return -EXDEV; |
877 | if (ceph_snap(old_dir) != CEPH_NOSNAP || | 871 | if (ceph_snap(old_dir) != CEPH_NOSNAP || |