aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorMika Kukkonen <mika@osdl.org>2004-07-10 19:34:08 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-07-10 19:34:08 -0700
commit6b2c2734bc8da49716e9a197f378a3b58ab1b01c (patch)
treeeac9022c47c20064d31d1f1acd9b84ac4b2c05bc /fs
parentf400f3bb6f071245b8bf8c4f757ce26737b97edb (diff)
downloadhistory-6b2c2734bc8da49716e9a197f378a3b58ab1b01c.tar.gz
[PATCH] Correct return type of hashfn() in fs/dquot.c
CC fs/dquot.o fs/dquot.c:208: warning: type qualifiers ignored on function return type Once again with extra gcc warnings enabled. Every user of the function is expecting unsigned value, not int in first place, and I think the const is just misplaced. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs')
-rw-r--r--fs/dquot.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/fs/dquot.c b/fs/dquot.c
index 2c2bdb506c3f92..35c84acdcc8003 100644
--- a/fs/dquot.c
+++ b/fs/dquot.c
@@ -206,9 +206,12 @@ struct dqstats dqstats;
static void dqput(struct dquot *dquot);
-static inline int const hashfn(struct super_block *sb, unsigned int id, int type)
+static inline unsigned int
+hashfn(const struct super_block *sb, unsigned int id, int type)
{
- unsigned long tmp = (((unsigned long)sb>>L1_CACHE_SHIFT) ^ id) * (MAXQUOTAS - type);
+ unsigned long tmp;
+
+ tmp = (((unsigned long)sb>>L1_CACHE_SHIFT) ^ id) * (MAXQUOTAS - type);
return (tmp + (tmp >> dq_hash_bits)) & dq_hash_mask;
}