commit | e8a7498715181ece36130335536e13733a5c3187 | [log] [tgz] |
---|---|---|
author | Sage Weil <sage@newdream.net> | Thu Apr 15 14:08:49 2010 -0700 |
committer | Sage Weil <sage@newdream.net> | Mon May 17 15:25:27 2010 -0700 |
tree | 3a8afe3901eecfefd833e024cf6f661c6992a12c | |
parent | f1f2765faedc24f8f2e9fd68521a5ea469801b60 [diff] [blame] |
ceph: skip set_dentry_offset work if directory not I_COMPLETE Signed-off-by: Sage Weil <sage@newdream.net>
diff --git a/fs/ceph/inode.c b/fs/ceph/inode.c index 913cafd..49a0935 100644 --- a/fs/ceph/inode.c +++ b/fs/ceph/inode.c
@@ -861,6 +861,10 @@ di = ceph_dentry(dn); spin_lock(&inode->i_lock); + if ((ceph_inode(inode)->i_ceph_flags & CEPH_I_COMPLETE) == 0) { + spin_unlock(&inode->i_lock); + return; + } di->offset = ceph_inode(inode)->i_max_offset++; spin_unlock(&inode->i_lock);