File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1495,13 +1495,9 @@ static enum d_walk_ret select_collect(void *_data, struct dentry *dentry)
14951495
14961496 if (dentry -> d_flags & DCACHE_SHRINK_LIST ) {
14971497 data -> found ++ ;
1498- } else {
1499- if (dentry -> d_flags & DCACHE_LRU_LIST )
1500- d_lru_del (dentry );
1501- if (!dentry -> d_lockref .count ) {
1502- d_shrink_add (dentry , & data -> dispose );
1503- data -> found ++ ;
1504- }
1498+ } else if (!dentry -> d_lockref .count ) {
1499+ to_shrink_list (dentry , & data -> dispose );
1500+ data -> found ++ ;
15051501 }
15061502 /*
15071503 * We can return to the caller if we have found some (this
@@ -1522,17 +1518,13 @@ static enum d_walk_ret select_collect2(void *_data, struct dentry *dentry)
15221518 if (data -> start == dentry )
15231519 goto out ;
15241520
1525- if (dentry -> d_flags & DCACHE_SHRINK_LIST ) {
1526- if (! dentry -> d_lockref . count ) {
1521+ if (! dentry -> d_lockref . count ) {
1522+ if (dentry -> d_flags & DCACHE_SHRINK_LIST ) {
15271523 rcu_read_lock ();
15281524 data -> victim = dentry ;
15291525 return D_WALK_QUIT ;
15301526 }
1531- } else {
1532- if (dentry -> d_flags & DCACHE_LRU_LIST )
1533- d_lru_del (dentry );
1534- if (!dentry -> d_lockref .count )
1535- d_shrink_add (dentry , & data -> dispose );
1527+ to_shrink_list (dentry , & data -> dispose );
15361528 }
15371529 /*
15381530 * We can return to the caller if we have found some (this
You can’t perform that action at this time.
0 commit comments