aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2010-08-03 22:11:22 -0400
committerRusty Russell <rusty@rustcorp.com.au>2010-08-11 09:34:15 -0400
commit8e4e15d44a817e9f02cb04a6cd6c0ee77ed3fbd8 (patch)
tree292477c3dff33e574daf73fa8d1c858123dea21e /net
parent101d6c826fa03266f8538ea4f6a459190e6863e8 (diff)
nfs: update for module_param_named API change
After merging the rr tree, today's linux-next build (powerpc ppc64_defconfig) failed like this: net/sunrpc/auth.c:74: error: 'param_ops_hashtbl_sz' undeclared here (not in a function) Caused by commit 0685652df0929cec7d78efa85127f6eb34962132 ("param:param_ops") interacting with commit f8f853ab19fcc415b6eadd273373edc424916212 ("SUNRPC: Make the credential cache hashtable size configurable") from the nfs tree. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/auth.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/net/sunrpc/auth.c b/net/sunrpc/auth.c
index 880d0de3f50f..36cb66022a27 100644
--- a/net/sunrpc/auth.c
+++ b/net/sunrpc/auth.c
@@ -39,7 +39,7 @@ static LIST_HEAD(cred_unused);
39static unsigned long number_cred_unused; 39static unsigned long number_cred_unused;
40 40
41#define MAX_HASHTABLE_BITS (10) 41#define MAX_HASHTABLE_BITS (10)
42static int param_set_hashtbl_sz(const char *val, struct kernel_param *kp) 42static int param_set_hashtbl_sz(const char *val, const struct kernel_param *kp)
43{ 43{
44 unsigned long num; 44 unsigned long num;
45 unsigned int nbits; 45 unsigned int nbits;
@@ -61,7 +61,7 @@ out_inval:
61 return -EINVAL; 61 return -EINVAL;
62} 62}
63 63
64static int param_get_hashtbl_sz(char *buffer, struct kernel_param *kp) 64static int param_get_hashtbl_sz(char *buffer, const struct kernel_param *kp)
65{ 65{
66 unsigned int nbits; 66 unsigned int nbits;
67 67
@@ -71,6 +71,11 @@ static int param_get_hashtbl_sz(char *buffer, struct kernel_param *kp)
71 71
72#define param_check_hashtbl_sz(name, p) __param_check(name, p, unsigned int); 72#define param_check_hashtbl_sz(name, p) __param_check(name, p, unsigned int);
73 73
74static struct kernel_param_ops param_ops_hashtbl_sz = {
75 .set = param_set_hashtbl_sz,
76 .get = param_get_hashtbl_sz,
77};
78
74module_param_named(auth_hashtable_size, auth_hashbits, hashtbl_sz, 0644); 79module_param_named(auth_hashtable_size, auth_hashbits, hashtbl_sz, 0644);
75MODULE_PARM_DESC(auth_hashtable_size, "RPC credential cache hashtable size"); 80MODULE_PARM_DESC(auth_hashtable_size, "RPC credential cache hashtable size");
76 81