From: Derrick Brashear Date: Sun, 18 Apr 2010 17:35:09 +0000 (-0400) Subject: bulkstat restore bulkfetching state for reused vcaches X-Git-Tag: openafs-devel-1_5_74~2 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=b64a0af473aea79dd7a198210e0283016433546e;p=packages%2Fo%2Fopenafs.git bulkstat restore bulkfetching state for reused vcaches when i introduced NewBulkVCache I elided this case. Set it here. Change-Id: Id88425b0ee662ecc23dd43cf7fa253ab61b02945 Reviewed-on: http://gerrit.openafs.org/1775 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- diff --git a/src/afs/VNOPS/afs_vnop_lookup.c b/src/afs/VNOPS/afs_vnop_lookup.c index 40d0f3195..06a79e94d 100644 --- a/src/afs/VNOPS/afs_vnop_lookup.c +++ b/src/afs/VNOPS/afs_vnop_lookup.c @@ -874,12 +874,17 @@ afs_DoBulkStat(struct vcache *adp, long dirCookie, struct vrequest *areqp) * CBulkFetching state bit and the value in the file size. * It is safe to set the status only if the CBulkFetching * flag is still set and the value in the file size does - * not change. NewBulkVCache sets us up. + * not change. NewBulkVCache sets us up for the new ones. + * Set up the rest here. * * Don't fetch status for dirty files. We need to * preserve the value of the file size. We could * flush the pages, but it wouldn't be worthwhile. */ + if (!(tvcp->f.states & CBulkFetching)) { + tvcp->f.states |= CBulkFetching; + tvcp->f.m.Length = statSeqNo; + } memcpy((char *)(fidsp + fidIndex), (char *)&tfid.Fid, sizeof(*fidsp)); fidIndex++;