mirror of
https://git.openafs.org/openafs.git
synced 2025-01-20 16:00:12 +00:00
libafs: Fix second pass in ShakeLooseVCaches
Commit 3105c7ff
introduced a two phase process for reclaiming
vcache entries. First go through the list and do what's possible
without sleeping (skipping aliased dentries on Linux), then do
a second pass only if necessary, allowing sleeping.
Unfortunately the test for the end of the VLRU scan is incorrect
and can never trigger, so this second pass was effectively disabled
and any code that is conditional on defersleep=1 was never
exercised. The code to start the second scan also has issues.
Fix the end of VLRU test, and also correctly set the variables
needed to restart the scan.
Change-Id: I8034cd3b79aab4f2976ab2559c13c102126480d7
Reviewed-on: http://gerrit.openafs.org/8234
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
This commit is contained in:
parent
fa3116567e
commit
a7828d50a8
@ -736,10 +736,11 @@ afs_ShakeLooseVCaches(afs_int32 anumber)
|
|||||||
i = 0;
|
i = 0;
|
||||||
continue; /* start over - may have raced. */
|
continue; /* start over - may have raced. */
|
||||||
}
|
}
|
||||||
if (tq == uq) {
|
if (uq == &VLRU) {
|
||||||
if (anumber && !defersleep) {
|
if (anumber && !defersleep) {
|
||||||
defersleep = 1;
|
defersleep = 1;
|
||||||
tq = VLRU.prev;
|
uq = VLRU.prev;
|
||||||
|
i = 0;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user