Commit 24c3767e authored by Trond Myklebust's avatar Trond Myklebust Committed by J. Bruce Fields

SUNRPC: The sunrpc server code should not be used by out-of-tree modules

Signed-off-by: default avatarTrond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
parent 22945e4a
...@@ -98,7 +98,7 @@ struct cache_head *sunrpc_cache_lookup(struct cache_detail *detail, ...@@ -98,7 +98,7 @@ struct cache_head *sunrpc_cache_lookup(struct cache_detail *detail,
return new; return new;
} }
EXPORT_SYMBOL(sunrpc_cache_lookup); EXPORT_SYMBOL_GPL(sunrpc_cache_lookup);
static void queue_loose(struct cache_detail *detail, struct cache_head *ch); static void queue_loose(struct cache_detail *detail, struct cache_head *ch);
...@@ -173,7 +173,7 @@ struct cache_head *sunrpc_cache_update(struct cache_detail *detail, ...@@ -173,7 +173,7 @@ struct cache_head *sunrpc_cache_update(struct cache_detail *detail,
cache_put(old, detail); cache_put(old, detail);
return tmp; return tmp;
} }
EXPORT_SYMBOL(sunrpc_cache_update); EXPORT_SYMBOL_GPL(sunrpc_cache_update);
static int cache_make_upcall(struct cache_detail *detail, struct cache_head *h); static int cache_make_upcall(struct cache_detail *detail, struct cache_head *h);
/* /*
...@@ -245,7 +245,7 @@ int cache_check(struct cache_detail *detail, ...@@ -245,7 +245,7 @@ int cache_check(struct cache_detail *detail,
cache_put(h, detail); cache_put(h, detail);
return rv; return rv;
} }
EXPORT_SYMBOL(cache_check); EXPORT_SYMBOL_GPL(cache_check);
/* /*
* caches need to be periodically cleaned. * caches need to be periodically cleaned.
...@@ -373,7 +373,7 @@ int cache_register(struct cache_detail *cd) ...@@ -373,7 +373,7 @@ int cache_register(struct cache_detail *cd)
schedule_delayed_work(&cache_cleaner, 0); schedule_delayed_work(&cache_cleaner, 0);
return 0; return 0;
} }
EXPORT_SYMBOL(cache_register); EXPORT_SYMBOL_GPL(cache_register);
void cache_unregister(struct cache_detail *cd) void cache_unregister(struct cache_detail *cd)
{ {
...@@ -399,7 +399,7 @@ void cache_unregister(struct cache_detail *cd) ...@@ -399,7 +399,7 @@ void cache_unregister(struct cache_detail *cd)
out: out:
printk(KERN_ERR "nfsd: failed to unregister %s cache\n", cd->name); printk(KERN_ERR "nfsd: failed to unregister %s cache\n", cd->name);
} }
EXPORT_SYMBOL(cache_unregister); EXPORT_SYMBOL_GPL(cache_unregister);
/* clean cache tries to find something to clean /* clean cache tries to find something to clean
* and cleans it. * and cleans it.
...@@ -514,7 +514,7 @@ void cache_flush(void) ...@@ -514,7 +514,7 @@ void cache_flush(void)
while (cache_clean() != -1) while (cache_clean() != -1)
cond_resched(); cond_resched();
} }
EXPORT_SYMBOL(cache_flush); EXPORT_SYMBOL_GPL(cache_flush);
void cache_purge(struct cache_detail *detail) void cache_purge(struct cache_detail *detail)
{ {
...@@ -523,7 +523,7 @@ void cache_purge(struct cache_detail *detail) ...@@ -523,7 +523,7 @@ void cache_purge(struct cache_detail *detail)
cache_flush(); cache_flush();
detail->flush_time = 1; detail->flush_time = 1;
} }
EXPORT_SYMBOL(cache_purge); EXPORT_SYMBOL_GPL(cache_purge);
/* /*
...@@ -988,7 +988,7 @@ void qword_add(char **bpp, int *lp, char *str) ...@@ -988,7 +988,7 @@ void qword_add(char **bpp, int *lp, char *str)
*bpp = bp; *bpp = bp;
*lp = len; *lp = len;
} }
EXPORT_SYMBOL(qword_add); EXPORT_SYMBOL_GPL(qword_add);
void qword_addhex(char **bpp, int *lp, char *buf, int blen) void qword_addhex(char **bpp, int *lp, char *buf, int blen)
{ {
...@@ -1017,7 +1017,7 @@ void qword_addhex(char **bpp, int *lp, char *buf, int blen) ...@@ -1017,7 +1017,7 @@ void qword_addhex(char **bpp, int *lp, char *buf, int blen)
*bpp = bp; *bpp = bp;
*lp = len; *lp = len;
} }
EXPORT_SYMBOL(qword_addhex); EXPORT_SYMBOL_GPL(qword_addhex);
static void warn_no_listener(struct cache_detail *detail) static void warn_no_listener(struct cache_detail *detail)
{ {
...@@ -1140,7 +1140,7 @@ int qword_get(char **bpp, char *dest, int bufsize) ...@@ -1140,7 +1140,7 @@ int qword_get(char **bpp, char *dest, int bufsize)
*dest = '\0'; *dest = '\0';
return len; return len;
} }
EXPORT_SYMBOL(qword_get); EXPORT_SYMBOL_GPL(qword_get);
/* /*
......
...@@ -106,7 +106,7 @@ void svc_seq_show(struct seq_file *seq, const struct svc_stat *statp) { ...@@ -106,7 +106,7 @@ void svc_seq_show(struct seq_file *seq, const struct svc_stat *statp) {
seq_putc(seq, '\n'); seq_putc(seq, '\n');
} }
} }
EXPORT_SYMBOL(svc_seq_show); EXPORT_SYMBOL_GPL(svc_seq_show);
/** /**
* rpc_alloc_iostats - allocate an rpc_iostats structure * rpc_alloc_iostats - allocate an rpc_iostats structure
...@@ -249,14 +249,14 @@ svc_proc_register(struct svc_stat *statp, const struct file_operations *fops) ...@@ -249,14 +249,14 @@ svc_proc_register(struct svc_stat *statp, const struct file_operations *fops)
{ {
return do_register(statp->program->pg_name, statp, fops); return do_register(statp->program->pg_name, statp, fops);
} }
EXPORT_SYMBOL(svc_proc_register); EXPORT_SYMBOL_GPL(svc_proc_register);
void void
svc_proc_unregister(const char *name) svc_proc_unregister(const char *name)
{ {
remove_proc_entry(name, proc_net_rpc); remove_proc_entry(name, proc_net_rpc);
} }
EXPORT_SYMBOL(svc_proc_unregister); EXPORT_SYMBOL_GPL(svc_proc_unregister);
void void
rpc_proc_init(void) rpc_proc_init(void)
......
...@@ -431,7 +431,7 @@ svc_create(struct svc_program *prog, unsigned int bufsize, ...@@ -431,7 +431,7 @@ svc_create(struct svc_program *prog, unsigned int bufsize,
{ {
return __svc_create(prog, bufsize, /*npools*/1, family, shutdown); return __svc_create(prog, bufsize, /*npools*/1, family, shutdown);
} }
EXPORT_SYMBOL(svc_create); EXPORT_SYMBOL_GPL(svc_create);
struct svc_serv * struct svc_serv *
svc_create_pooled(struct svc_program *prog, unsigned int bufsize, svc_create_pooled(struct svc_program *prog, unsigned int bufsize,
...@@ -450,7 +450,7 @@ svc_create_pooled(struct svc_program *prog, unsigned int bufsize, ...@@ -450,7 +450,7 @@ svc_create_pooled(struct svc_program *prog, unsigned int bufsize,
return serv; return serv;
} }
EXPORT_SYMBOL(svc_create_pooled); EXPORT_SYMBOL_GPL(svc_create_pooled);
/* /*
* Destroy an RPC service. Should be called with appropriate locking to * Destroy an RPC service. Should be called with appropriate locking to
...@@ -492,7 +492,7 @@ svc_destroy(struct svc_serv *serv) ...@@ -492,7 +492,7 @@ svc_destroy(struct svc_serv *serv)
kfree(serv->sv_pools); kfree(serv->sv_pools);
kfree(serv); kfree(serv);
} }
EXPORT_SYMBOL(svc_destroy); EXPORT_SYMBOL_GPL(svc_destroy);
/* /*
* Allocate an RPC server's buffer space. * Allocate an RPC server's buffer space.
...@@ -567,7 +567,7 @@ svc_prepare_thread(struct svc_serv *serv, struct svc_pool *pool) ...@@ -567,7 +567,7 @@ svc_prepare_thread(struct svc_serv *serv, struct svc_pool *pool)
out_enomem: out_enomem:
return ERR_PTR(-ENOMEM); return ERR_PTR(-ENOMEM);
} }
EXPORT_SYMBOL(svc_prepare_thread); EXPORT_SYMBOL_GPL(svc_prepare_thread);
/* /*
* Choose a pool in which to create a new thread, for svc_set_num_threads * Choose a pool in which to create a new thread, for svc_set_num_threads
...@@ -689,7 +689,7 @@ svc_set_num_threads(struct svc_serv *serv, struct svc_pool *pool, int nrservs) ...@@ -689,7 +689,7 @@ svc_set_num_threads(struct svc_serv *serv, struct svc_pool *pool, int nrservs)
return error; return error;
} }
EXPORT_SYMBOL(svc_set_num_threads); EXPORT_SYMBOL_GPL(svc_set_num_threads);
/* /*
* Called from a server thread as it's exiting. Caller must hold the BKL or * Called from a server thread as it's exiting. Caller must hold the BKL or
...@@ -717,7 +717,7 @@ svc_exit_thread(struct svc_rqst *rqstp) ...@@ -717,7 +717,7 @@ svc_exit_thread(struct svc_rqst *rqstp)
if (serv) if (serv)
svc_destroy(serv); svc_destroy(serv);
} }
EXPORT_SYMBOL(svc_exit_thread); EXPORT_SYMBOL_GPL(svc_exit_thread);
#ifdef CONFIG_SUNRPC_REGISTER_V4 #ifdef CONFIG_SUNRPC_REGISTER_V4
...@@ -1231,7 +1231,7 @@ svc_process(struct svc_rqst *rqstp) ...@@ -1231,7 +1231,7 @@ svc_process(struct svc_rqst *rqstp)
svc_putnl(resv, ntohl(rpc_stat)); svc_putnl(resv, ntohl(rpc_stat));
goto sendit; goto sendit;
} }
EXPORT_SYMBOL(svc_process); EXPORT_SYMBOL_GPL(svc_process);
/* /*
* Return (transport-specific) limit on the rpc payload. * Return (transport-specific) limit on the rpc payload.
......
...@@ -440,7 +440,7 @@ void svc_reserve(struct svc_rqst *rqstp, int space) ...@@ -440,7 +440,7 @@ void svc_reserve(struct svc_rqst *rqstp, int space)
svc_xprt_enqueue(xprt); svc_xprt_enqueue(xprt);
} }
} }
EXPORT_SYMBOL(svc_reserve); EXPORT_SYMBOL_GPL(svc_reserve);
static void svc_xprt_release(struct svc_rqst *rqstp) static void svc_xprt_release(struct svc_rqst *rqstp)
{ {
...@@ -501,7 +501,7 @@ void svc_wake_up(struct svc_serv *serv) ...@@ -501,7 +501,7 @@ void svc_wake_up(struct svc_serv *serv)
spin_unlock_bh(&pool->sp_lock); spin_unlock_bh(&pool->sp_lock);
} }
} }
EXPORT_SYMBOL(svc_wake_up); EXPORT_SYMBOL_GPL(svc_wake_up);
int svc_port_is_privileged(struct sockaddr *sin) int svc_port_is_privileged(struct sockaddr *sin)
{ {
...@@ -743,7 +743,7 @@ int svc_recv(struct svc_rqst *rqstp, long timeout) ...@@ -743,7 +743,7 @@ int svc_recv(struct svc_rqst *rqstp, long timeout)
serv->sv_stats->netcnt++; serv->sv_stats->netcnt++;
return len; return len;
} }
EXPORT_SYMBOL(svc_recv); EXPORT_SYMBOL_GPL(svc_recv);
/* /*
* Drop request * Drop request
...@@ -753,7 +753,7 @@ void svc_drop(struct svc_rqst *rqstp) ...@@ -753,7 +753,7 @@ void svc_drop(struct svc_rqst *rqstp)
dprintk("svc: xprt %p dropped request\n", rqstp->rq_xprt); dprintk("svc: xprt %p dropped request\n", rqstp->rq_xprt);
svc_xprt_release(rqstp); svc_xprt_release(rqstp);
} }
EXPORT_SYMBOL(svc_drop); EXPORT_SYMBOL_GPL(svc_drop);
/* /*
* Return reply to client. * Return reply to client.
......
...@@ -57,13 +57,13 @@ svc_authenticate(struct svc_rqst *rqstp, __be32 *authp) ...@@ -57,13 +57,13 @@ svc_authenticate(struct svc_rqst *rqstp, __be32 *authp)
rqstp->rq_authop = aops; rqstp->rq_authop = aops;
return aops->accept(rqstp, authp); return aops->accept(rqstp, authp);
} }
EXPORT_SYMBOL(svc_authenticate); EXPORT_SYMBOL_GPL(svc_authenticate);
int svc_set_client(struct svc_rqst *rqstp) int svc_set_client(struct svc_rqst *rqstp)
{ {
return rqstp->rq_authop->set_client(rqstp); return rqstp->rq_authop->set_client(rqstp);
} }
EXPORT_SYMBOL(svc_set_client); EXPORT_SYMBOL_GPL(svc_set_client);
/* A request, which was authenticated, has now executed. /* A request, which was authenticated, has now executed.
* Time to finalise the credentials and verifier * Time to finalise the credentials and verifier
...@@ -95,7 +95,7 @@ svc_auth_register(rpc_authflavor_t flavor, struct auth_ops *aops) ...@@ -95,7 +95,7 @@ svc_auth_register(rpc_authflavor_t flavor, struct auth_ops *aops)
spin_unlock(&authtab_lock); spin_unlock(&authtab_lock);
return rv; return rv;
} }
EXPORT_SYMBOL(svc_auth_register); EXPORT_SYMBOL_GPL(svc_auth_register);
void void
svc_auth_unregister(rpc_authflavor_t flavor) svc_auth_unregister(rpc_authflavor_t flavor)
...@@ -105,7 +105,7 @@ svc_auth_unregister(rpc_authflavor_t flavor) ...@@ -105,7 +105,7 @@ svc_auth_unregister(rpc_authflavor_t flavor)
authtab[flavor] = NULL; authtab[flavor] = NULL;
spin_unlock(&authtab_lock); spin_unlock(&authtab_lock);
} }
EXPORT_SYMBOL(svc_auth_unregister); EXPORT_SYMBOL_GPL(svc_auth_unregister);
/************************************************** /**************************************************
* 'auth_domains' are stored in a hash table indexed by name. * 'auth_domains' are stored in a hash table indexed by name.
...@@ -132,7 +132,7 @@ void auth_domain_put(struct auth_domain *dom) ...@@ -132,7 +132,7 @@ void auth_domain_put(struct auth_domain *dom)
spin_unlock(&auth_domain_lock); spin_unlock(&auth_domain_lock);
} }
} }
EXPORT_SYMBOL(auth_domain_put); EXPORT_SYMBOL_GPL(auth_domain_put);
struct auth_domain * struct auth_domain *
auth_domain_lookup(char *name, struct auth_domain *new) auth_domain_lookup(char *name, struct auth_domain *new)
...@@ -157,10 +157,10 @@ auth_domain_lookup(char *name, struct auth_domain *new) ...@@ -157,10 +157,10 @@ auth_domain_lookup(char *name, struct auth_domain *new)
spin_unlock(&auth_domain_lock); spin_unlock(&auth_domain_lock);
return new; return new;
} }
EXPORT_SYMBOL(auth_domain_lookup); EXPORT_SYMBOL_GPL(auth_domain_lookup);
struct auth_domain *auth_domain_find(char *name) struct auth_domain *auth_domain_find(char *name)
{ {
return auth_domain_lookup(name, NULL); return auth_domain_lookup(name, NULL);
} }
EXPORT_SYMBOL(auth_domain_find); EXPORT_SYMBOL_GPL(auth_domain_find);
...@@ -64,7 +64,7 @@ struct auth_domain *unix_domain_find(char *name) ...@@ -64,7 +64,7 @@ struct auth_domain *unix_domain_find(char *name)
rv = auth_domain_lookup(name, &new->h); rv = auth_domain_lookup(name, &new->h);
} }
} }
EXPORT_SYMBOL(unix_domain_find); EXPORT_SYMBOL_GPL(unix_domain_find);
static void svcauth_unix_domain_release(struct auth_domain *dom) static void svcauth_unix_domain_release(struct auth_domain *dom)
{ {
...@@ -358,7 +358,7 @@ int auth_unix_add_addr(struct in6_addr *addr, struct auth_domain *dom) ...@@ -358,7 +358,7 @@ int auth_unix_add_addr(struct in6_addr *addr, struct auth_domain *dom)
else else
return -ENOMEM; return -ENOMEM;
} }
EXPORT_SYMBOL(auth_unix_add_addr); EXPORT_SYMBOL_GPL(auth_unix_add_addr);
int auth_unix_forget_old(struct auth_domain *dom) int auth_unix_forget_old(struct auth_domain *dom)
{ {
...@@ -370,7 +370,7 @@ int auth_unix_forget_old(struct auth_domain *dom) ...@@ -370,7 +370,7 @@ int auth_unix_forget_old(struct auth_domain *dom)
udom->addr_changes++; udom->addr_changes++;
return 0; return 0;
} }
EXPORT_SYMBOL(auth_unix_forget_old); EXPORT_SYMBOL_GPL(auth_unix_forget_old);
struct auth_domain *auth_unix_lookup(struct in6_addr *addr) struct auth_domain *auth_unix_lookup(struct in6_addr *addr)
{ {
...@@ -395,13 +395,13 @@ struct auth_domain *auth_unix_lookup(struct in6_addr *addr) ...@@ -395,13 +395,13 @@ struct auth_domain *auth_unix_lookup(struct in6_addr *addr)
cache_put(&ipm->h, &ip_map_cache); cache_put(&ipm->h, &ip_map_cache);
return rv; return rv;
} }
EXPORT_SYMBOL(auth_unix_lookup); EXPORT_SYMBOL_GPL(auth_unix_lookup);
void svcauth_unix_purge(void) void svcauth_unix_purge(void)
{ {
cache_purge(&ip_map_cache); cache_purge(&ip_map_cache);
} }
EXPORT_SYMBOL(svcauth_unix_purge); EXPORT_SYMBOL_GPL(svcauth_unix_purge);
static inline struct ip_map * static inline struct ip_map *
ip_map_cached_get(struct svc_rqst *rqstp) ip_map_cached_get(struct svc_rqst *rqstp)
...@@ -714,7 +714,7 @@ svcauth_unix_set_client(struct svc_rqst *rqstp) ...@@ -714,7 +714,7 @@ svcauth_unix_set_client(struct svc_rqst *rqstp)
return SVC_OK; return SVC_OK;
} }
EXPORT_SYMBOL(svcauth_unix_set_client); EXPORT_SYMBOL_GPL(svcauth_unix_set_client);
static int static int
svcauth_null_accept(struct svc_rqst *rqstp, __be32 *authp) svcauth_null_accept(struct svc_rqst *rqstp, __be32 *authp)
......
...@@ -285,7 +285,7 @@ svc_sock_names(char *buf, struct svc_serv *serv, char *toclose) ...@@ -285,7 +285,7 @@ svc_sock_names(char *buf, struct svc_serv *serv, char *toclose)
return -ENOENT; return -ENOENT;
return len; return len;
} }
EXPORT_SYMBOL(svc_sock_names); EXPORT_SYMBOL_GPL(svc_sock_names);
/* /*
* Check input queue length * Check input queue length
...@@ -1097,7 +1097,7 @@ void svc_sock_update_bufs(struct svc_serv *serv) ...@@ -1097,7 +1097,7 @@ void svc_sock_update_bufs(struct svc_serv *serv)
} }
spin_unlock_bh(&serv->sv_lock); spin_unlock_bh(&serv->sv_lock);
} }
EXPORT_SYMBOL(svc_sock_update_bufs); EXPORT_SYMBOL_GPL(svc_sock_update_bufs);
/* /*
* Initialize socket for RPC use and create svc_sock struct * Initialize socket for RPC use and create svc_sock struct
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment