File tree Expand file tree Collapse file tree 1 file changed +6
-14
lines changed Expand file tree Collapse file tree 1 file changed +6
-14
lines changed 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)
1495
1495
1496
1496
if (dentry -> d_flags & DCACHE_SHRINK_LIST ) {
1497
1497
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 ++ ;
1505
1501
}
1506
1502
/*
1507
1503
* 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)
1522
1518
if (data -> start == dentry )
1523
1519
goto out ;
1524
1520
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 ) {
1527
1523
rcu_read_lock ();
1528
1524
data -> victim = dentry ;
1529
1525
return D_WALK_QUIT ;
1530
1526
}
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 );
1536
1528
}
1537
1529
/*
1538
1530
* We can return to the caller if we have found some (this
You can’t perform that action at this time.
0 commit comments