X-Git-Url: https://git.openafs.org/?p=openafs.git;a=blobdiff_plain;f=src%2Fafs%2Fafs.h;h=25a49ad03294d04c6b9f34d50ddb79bc6b010854;hp=0205b758b8817dd602b5070b23f44ecb3ab6fb5f;hb=57150405dac2e8ba5b815e880107dda7c48cbd58;hpb=0d57910b60b3283803464eb26cd0a33d16c2d7db diff --git a/src/afs/afs.h b/src/afs/afs.h index 0205b75..25a49ad 100644 --- a/src/afs/afs.h +++ b/src/afs/afs.h @@ -620,6 +620,7 @@ struct vcache { struct afs_q vlruq; /* lru q next and prev */ struct vcache *nextfree; /* next on free list (if free) */ struct vcache *hnext; /* Hash next */ + struct vcache *vhnext; /* vol hash next */ struct VenusFid fid; struct mstat { afs_size_t Length; @@ -1065,6 +1066,8 @@ struct memCacheEntry { /* don't hash on the cell, our callback-breaking code sometimes fails to compute the cell correctly, and only scans one hash bucket */ #define VCHash(fid) (((fid)->Fid.Volume + (fid)->Fid.Vnode) & (VCSIZE-1)) +/* Hash only on volume to speed up volume callbacks. */ +#define VCHashV(fid) ((fid)->Fid.Volume & (VCSIZE-1)) extern struct dcache **afs_indexTable; /*Pointers to in-memory dcache entries */ extern afs_int32 *afs_indexUnique; /*dcache entry Fid.Unique */ @@ -1074,6 +1077,7 @@ extern afs_int32 afs_cacheFiles; /*Size of afs_indexTable */ extern afs_int32 afs_cacheBlocks; /*1K blocks in cache */ extern afs_int32 afs_cacheStats; /*Stat entries in cache */ extern struct vcache *afs_vhashT[VCSIZE]; /*Stat cache hash table */ +extern struct vcache *afs_vhashTV[VCSIZE]; /* cache hash table on volume */ extern afs_int32 afs_initState; /*Initialization state */ extern afs_int32 afs_termState; /* Termination state */ extern struct VenusFid afs_rootFid; /*Root for whole file system */