diff options
author | NeilBrown <neilb@suse.de> | 2006-03-27 04:15:01 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-27 11:44:41 -0500 |
commit | 7d317f2c9f1e9dcf4f632fa98f91d1d4a36c4cae (patch) | |
tree | 7794c88facd3943a7496f7d41c2b7eb24a5d0be0 /fs/nfsd | |
parent | eab7e2e647c348b418e8715ecaca0177e1b473c7 (diff) |
[PATCH] knfsd: Get rid of 'inplace' sunrpc caches
These were an unnecessary wart. Also only have one 'DefineSimpleCache..'
instead of two.
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/nfsd')
-rw-r--r-- | fs/nfsd/export.c | 4 | ||||
-rw-r--r-- | fs/nfsd/nfs4idmap.c | 10 |
2 files changed, 4 insertions, 10 deletions
diff --git a/fs/nfsd/export.c b/fs/nfsd/export.c index 587829ed651c..c591761a1ad6 100644 --- a/fs/nfsd/export.c +++ b/fs/nfsd/export.c | |||
@@ -250,7 +250,7 @@ static inline void svc_expkey_update(struct svc_expkey *new, struct svc_expkey * | |||
250 | new->ek_dentry = dget(item->ek_dentry); | 250 | new->ek_dentry = dget(item->ek_dentry); |
251 | } | 251 | } |
252 | 252 | ||
253 | static DefineSimpleCacheLookup(svc_expkey,0) /* no inplace updates */ | 253 | static DefineSimpleCacheLookup(svc_expkey, svc_expkey) |
254 | 254 | ||
255 | #define EXPORT_HASHBITS 8 | 255 | #define EXPORT_HASHBITS 8 |
256 | #define EXPORT_HASHMAX (1<< EXPORT_HASHBITS) | 256 | #define EXPORT_HASHMAX (1<< EXPORT_HASHBITS) |
@@ -482,7 +482,7 @@ static inline void svc_export_update(struct svc_export *new, struct svc_export * | |||
482 | new->ex_fsid = item->ex_fsid; | 482 | new->ex_fsid = item->ex_fsid; |
483 | } | 483 | } |
484 | 484 | ||
485 | static DefineSimpleCacheLookup(svc_export,1) /* allow inplace updates */ | 485 | static DefineSimpleCacheLookup(svc_export, svc_export) |
486 | 486 | ||
487 | 487 | ||
488 | struct svc_expkey * | 488 | struct svc_expkey * |
diff --git a/fs/nfsd/nfs4idmap.c b/fs/nfsd/nfs4idmap.c index 13369650cdf9..dea690aa8bb5 100644 --- a/fs/nfsd/nfs4idmap.c +++ b/fs/nfsd/nfs4idmap.c | |||
@@ -76,12 +76,6 @@ struct ent { | |||
76 | char authname[IDMAP_NAMESZ]; | 76 | char authname[IDMAP_NAMESZ]; |
77 | }; | 77 | }; |
78 | 78 | ||
79 | #define DefineSimpleCacheLookupMap(STRUCT, FUNC) \ | ||
80 | DefineCacheLookup(struct STRUCT, h, FUNC##_lookup, \ | ||
81 | (struct STRUCT *item, int set), /*no setup */, \ | ||
82 | & FUNC##_cache, FUNC##_hash(item), FUNC##_match(item, tmp), \ | ||
83 | STRUCT##_init(new, item), STRUCT##_update(tmp, item), 0) | ||
84 | |||
85 | /* Common entry handling */ | 79 | /* Common entry handling */ |
86 | 80 | ||
87 | #define ENT_HASHBITS 8 | 81 | #define ENT_HASHBITS 8 |
@@ -264,7 +258,7 @@ out: | |||
264 | return error; | 258 | return error; |
265 | } | 259 | } |
266 | 260 | ||
267 | static DefineSimpleCacheLookupMap(ent, idtoname); | 261 | static DefineSimpleCacheLookup(ent, idtoname); |
268 | 262 | ||
269 | /* | 263 | /* |
270 | * Name -> ID cache | 264 | * Name -> ID cache |
@@ -390,7 +384,7 @@ out: | |||
390 | return (error); | 384 | return (error); |
391 | } | 385 | } |
392 | 386 | ||
393 | static DefineSimpleCacheLookupMap(ent, nametoid); | 387 | static DefineSimpleCacheLookup(ent, nametoid); |
394 | 388 | ||
395 | /* | 389 | /* |
396 | * Exported API | 390 | * Exported API |