X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=fs%2Fafs%2Fvolume.h;h=bfdcf19ba3f387080523c6e78027197058808c58;hb=9464c7cf61b9433057924c36e6e02f303a00e768;hp=fc9895abc0805094e548779d386c105b433014a3;hpb=41689045f6a3cbe0550e1d34e9cc20d2e8c432ba;p=linux-2.6.git diff --git a/fs/afs/volume.h b/fs/afs/volume.h index fc9895abc..bfdcf19ba 100644 --- a/fs/afs/volume.h +++ b/fs/afs/volume.h @@ -12,11 +12,11 @@ #ifndef _LINUX_AFS_VOLUME_H #define _LINUX_AFS_VOLUME_H -#include #include "types.h" #include "fsclient.h" #include "kafstimod.h" #include "kafsasyncd.h" +#include "cache.h" typedef enum { AFS_VLUPD_SLEEP, /* sleeping waiting for update timer to fire */ @@ -45,6 +45,24 @@ struct afs_cache_vlocation time_t rtime; /* last retrieval time */ }; +#ifdef AFS_CACHING_SUPPORT +extern struct cachefs_index_def afs_vlocation_cache_index_def; +#endif + +/*****************************************************************************/ +/* + * volume -> vnode hash table entry + */ +struct afs_cache_vhash +{ + afs_voltype_t vtype; /* which volume variation */ + uint8_t hash_bucket; /* which hash bucket this represents */ +} __attribute__((packed)); + +#ifdef AFS_CACHING_SUPPORT +extern struct cachefs_index_def afs_volume_cache_index_def; +#endif + /*****************************************************************************/ /* * AFS volume location record @@ -55,8 +73,8 @@ struct afs_vlocation struct list_head link; /* link in cell volume location list */ struct afs_timer timeout; /* decaching timer */ struct afs_cell *cell; /* cell to which volume belongs */ -#ifdef CONFIG_AFS_FSCACHE - struct fscache_cookie *cache; /* caching cookie */ +#ifdef AFS_CACHING_SUPPORT + struct cachefs_cookie *cache; /* caching cookie */ #endif struct afs_cache_vlocation vldb; /* volume information DB record */ struct afs_volume *vols[3]; /* volume access record pointer (index by type) */ @@ -91,8 +109,8 @@ struct afs_volume atomic_t usage; struct afs_cell *cell; /* cell to which belongs (unrefd ptr) */ struct afs_vlocation *vlocation; /* volume location */ -#ifdef CONFIG_AFS_FSCACHE - struct fscache_cookie *cache; /* caching cookie */ +#ifdef AFS_CACHING_SUPPORT + struct cachefs_cookie *cache; /* caching cookie */ #endif afs_volid_t vid; /* volume ID */ afs_voltype_t type; /* type of volume */