Whamcloud - gitweb
LU-8003 llite: remove obsolete code and comments 81/19881/3
authorJohn L. Hammond <john.hammond@intel.com>
Fri, 29 Apr 2016 12:03:10 +0000 (07:03 -0500)
committerOleg Drokin <oleg.drokin@intel.com>
Tue, 5 Jul 2016 23:48:46 +0000 (23:48 +0000)
Remove obsolete comments about the behavior of ll_ddelete() and the
removed function ll_d_iput(). Remove '#if 0'-ed out code from
ll_ddelete().

Test-Parameters: trivial

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Id2f2eed8e96ee07fdcd4ec14c4e82ed463752562
Reviewed-on: http://review.whamcloud.com/19881
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andrew Perepechko <andrew.perepechko@seagate.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/llite/dcache.c
lustre/llite/namei.c

index 732a841..fa0e7aa 100644 (file)
@@ -150,17 +150,6 @@ static int ll_ddelete(HAVE_D_DELETE_CONST struct dentry *de)
        LASSERT(ll_d_count(de) == 1);
 #endif
 
        LASSERT(ll_d_count(de) == 1);
 #endif
 
-       /* Disable this piece of code temproarily because this is called
-        * inside dcache_lock so it's not appropriate to do lots of work
-        * here. ATTENTION: Before this piece of code enabling, LU-2487 must be
-        * resolved. */
-#if 0
-       /* if not ldlm lock for this inode, set i_nlink to 0 so that
-        * this inode can be recycled later b=20433 */
-       if (de->d_inode && !find_cbdata(de->d_inode))
-               clear_nlink(de->d_inode);
-#endif
-
        if (d_lustre_invalid((struct dentry *)de))
                RETURN(1);
        RETURN(0);
        if (d_lustre_invalid((struct dentry *)de))
                RETURN(1);
        RETURN(0);
index 3cb0398..3e6c706 100644 (file)
@@ -1266,10 +1266,6 @@ int ll_rmdir_entry(struct inode *dir, char *name, int namelen)
        RETURN(rc);
 }
 
        RETURN(rc);
 }
 
-/* ll_unlink() doesn't update the inode with the new link count.
- * Instead, ll_ddelete() and ll_d_iput() will update it based upon if
- * there is any lock existing. They will recycle dentries and inodes
- * based upon locks too. b=20433 */
 static int ll_unlink(struct inode *dir, struct dentry *dchild)
 {
        struct qstr *name = &dchild->d_name;
 static int ll_unlink(struct inode *dir, struct dentry *dchild)
 {
        struct qstr *name = &dchild->d_name;