aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGreg Banks <gnb@melbourne.sgi.com>2006-10-02 02:17:49 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-02 07:57:18 -0700
commitbc6f02e516b487ada46823fb05f237a0ef705f92 (patch)
tree17ab76373f238bc8888e357c92a91834d3be367b
parentb41b66d63c730cc45a1024e1f1e67439e507e40f (diff)
[PATCH] knfsd: Use SEQ_START_TOKEN instead of hardcoded magic (void*)1
Signed-off-by: Greg Banks <gnb@melbourne.sgi.com> Acked-by: NeilBrown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--fs/nfsd/export.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/nfsd/export.c b/fs/nfsd/export.c
index 0e1f5d1f1c1..eccd2c2eb60 100644
--- a/fs/nfsd/export.c
+++ b/fs/nfsd/export.c
@@ -1086,7 +1086,7 @@ static void *e_start(struct seq_file *m, loff_t *pos)
exp_readlock();
read_lock(&svc_export_cache.hash_lock);
if (!n--)
- return (void *)1;
+ return SEQ_START_TOKEN;
hash = n >> 32;
export = n & ((1LL<<32) - 1);
@@ -1110,7 +1110,7 @@ static void *e_next(struct seq_file *m, void *p, loff_t *pos)
struct cache_head *ch = p;
int hash = (*pos >> 32);
- if (p == (void *)1)
+ if (p == SEQ_START_TOKEN)
hash = 0;
else if (ch->next == NULL) {
hash++;
@@ -1179,7 +1179,7 @@ static int e_show(struct seq_file *m, void *p)
struct cache_head *cp = p;
struct svc_export *exp = container_of(cp, struct svc_export, h);
- if (p == (void *)1) {
+ if (p == SEQ_START_TOKEN) {
seq_puts(m, "# Version 1.1\n");
seq_puts(m, "# Path Client(Flags) # IPs\n");
return 0;