1 /* Coda filesystem -- Linux Minicache
3 * Copyright (C) 1989 - 1997 Carnegie Mellon University
5 * Carnegie Mellon University encourages users of this software to
6 * contribute improvements to the Coda project. Contact Peter Braam
10 #ifndef _CFSNC_HEADER_
11 #define _CFSNC_HEADER_
14 * Structure for an element in the Coda Credential Cache.
18 struct list_head cc_cclist
; /* list of all cache entries */
19 struct list_head cc_cnlist
; /* list of cache entries/cnode */
21 struct coda_cred cc_cred
;
24 /* credential cache */
25 void coda_cache_enter(struct inode
*inode
, int mask
);
26 void coda_cache_clear_inode(struct inode
*);
27 void coda_cache_clear_all(struct super_block
*sb
);
28 void coda_cache_clear_cred(struct super_block
*sb
, struct coda_cred
*cred
);
29 int coda_cache_check(struct inode
*inode
, int mask
);
31 /* for downcalls and attributes and lookups */
32 void coda_flag_inode(struct inode
*inode
, int flag
);
33 void coda_flag_inode_children(struct inode
*inode
, int flag
);
37 * Structure to contain statistics on the cache usage
40 struct cfsnc_statistics
{
45 unsigned long_name_enters
;
46 unsigned long_name_lookups
;
54 unsigned Sum_bucket_len
;
55 unsigned Sum2_bucket_len
;
56 unsigned Max_bucket_len
;
57 unsigned Num_zero_len
;
62 #define CFSNC_FIND ((u_long) 1)
63 #define CFSNC_REMOVE ((u_long) 2)
64 #define CFSNC_INIT ((u_long) 3)
65 #define CFSNC_ENTER ((u_long) 4)
66 #define CFSNC_LOOKUP ((u_long) 5)
67 #define CFSNC_ZAPPFID ((u_long) 6)
68 #define CFSNC_ZAPFID ((u_long) 7)
69 #define CFSNC_ZAPVNODE ((u_long) 8)
70 #define CFSNC_ZAPFILE ((u_long) 9)
71 #define CFSNC_PURGEUSER ((u_long) 10)
72 #define CFSNC_FLUSH ((u_long) 11)
73 #define CFSNC_PRINTCFSNC ((u_long) 12)
74 #define CFSNC_PRINTSTATS ((u_long) 13)
75 #define CFSNC_REPLACE ((u_long) 14)