aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/bluetooth/bnep/core.c2
-rw-r--r--net/bluetooth/cmtp/core.c2
-rw-r--r--net/bluetooth/hidp/core.c2
-rw-r--r--net/bluetooth/rfcomm/core.c2
-rw-r--r--net/compat.c3
-rw-r--r--net/core/netpoll.c8
-rw-r--r--net/core/pktgen.c2
-rw-r--r--net/core/scm.c3
-rw-r--r--net/ieee80211/softmac/ieee80211softmac_assoc.c5
-rw-r--r--net/netlabel/netlabel_user.c4
-rw-r--r--net/socket.c4
-rw-r--r--net/sunrpc/auth.c11
-rw-r--r--net/sunrpc/auth_gss/auth_gss.c1
-rw-r--r--net/sunrpc/auth_gss/gss_krb5_mech.c1
-rw-r--r--net/sunrpc/auth_gss/gss_mech_switch.c14
-rw-r--r--net/sunrpc/auth_gss/gss_spkm3_mech.c1
-rw-r--r--net/sunrpc/auth_gss/svcauth_gss.c32
-rw-r--r--net/sunrpc/svcauth_unix.c7
18 files changed, 73 insertions, 31 deletions
diff --git a/net/bluetooth/bnep/core.c b/net/bluetooth/bnep/core.c
index 1c8f4a0c5f43..1f78c3e336d8 100644
--- a/net/bluetooth/bnep/core.c
+++ b/net/bluetooth/bnep/core.c
@@ -36,6 +36,7 @@
36#include <linux/signal.h> 36#include <linux/signal.h>
37#include <linux/init.h> 37#include <linux/init.h>
38#include <linux/wait.h> 38#include <linux/wait.h>
39#include <linux/freezer.h>
39#include <linux/errno.h> 40#include <linux/errno.h>
40#include <linux/net.h> 41#include <linux/net.h>
41#include <net/sock.h> 42#include <net/sock.h>
@@ -474,7 +475,6 @@ static int bnep_session(void *arg)
474 475
475 daemonize("kbnepd %s", dev->name); 476 daemonize("kbnepd %s", dev->name);
476 set_user_nice(current, -15); 477 set_user_nice(current, -15);
477 current->flags |= PF_NOFREEZE;
478 478
479 init_waitqueue_entry(&wait, current); 479 init_waitqueue_entry(&wait, current);
480 add_wait_queue(sk->sk_sleep, &wait); 480 add_wait_queue(sk->sk_sleep, &wait);
diff --git a/net/bluetooth/cmtp/core.c b/net/bluetooth/cmtp/core.c
index 66bef1ccee2a..ca60a4517fd3 100644
--- a/net/bluetooth/cmtp/core.c
+++ b/net/bluetooth/cmtp/core.c
@@ -29,6 +29,7 @@
29#include <linux/slab.h> 29#include <linux/slab.h>
30#include <linux/poll.h> 30#include <linux/poll.h>
31#include <linux/fcntl.h> 31#include <linux/fcntl.h>
32#include <linux/freezer.h>
32#include <linux/skbuff.h> 33#include <linux/skbuff.h>
33#include <linux/socket.h> 34#include <linux/socket.h>
34#include <linux/ioctl.h> 35#include <linux/ioctl.h>
@@ -287,7 +288,6 @@ static int cmtp_session(void *arg)
287 288
288 daemonize("kcmtpd_ctr_%d", session->num); 289 daemonize("kcmtpd_ctr_%d", session->num);
289 set_user_nice(current, -15); 290 set_user_nice(current, -15);
290 current->flags |= PF_NOFREEZE;
291 291
292 init_waitqueue_entry(&wait, current); 292 init_waitqueue_entry(&wait, current);
293 add_wait_queue(sk->sk_sleep, &wait); 293 add_wait_queue(sk->sk_sleep, &wait);
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c
index 450eb0244bbf..64d89ca28847 100644
--- a/net/bluetooth/hidp/core.c
+++ b/net/bluetooth/hidp/core.c
@@ -28,6 +28,7 @@
28#include <linux/sched.h> 28#include <linux/sched.h>
29#include <linux/slab.h> 29#include <linux/slab.h>
30#include <linux/poll.h> 30#include <linux/poll.h>
31#include <linux/freezer.h>
31#include <linux/fcntl.h> 32#include <linux/fcntl.h>
32#include <linux/skbuff.h> 33#include <linux/skbuff.h>
33#include <linux/socket.h> 34#include <linux/socket.h>
@@ -547,7 +548,6 @@ static int hidp_session(void *arg)
547 548
548 daemonize("khidpd_%04x%04x", vendor, product); 549 daemonize("khidpd_%04x%04x", vendor, product);
549 set_user_nice(current, -15); 550 set_user_nice(current, -15);
550 current->flags |= PF_NOFREEZE;
551 551
552 init_waitqueue_entry(&ctrl_wait, current); 552 init_waitqueue_entry(&ctrl_wait, current);
553 init_waitqueue_entry(&intr_wait, current); 553 init_waitqueue_entry(&intr_wait, current);
diff --git a/net/bluetooth/rfcomm/core.c b/net/bluetooth/rfcomm/core.c
index 52e04df323ea..bb7220770f2c 100644
--- a/net/bluetooth/rfcomm/core.c
+++ b/net/bluetooth/rfcomm/core.c
@@ -33,6 +33,7 @@
33#include <linux/sched.h> 33#include <linux/sched.h>
34#include <linux/signal.h> 34#include <linux/signal.h>
35#include <linux/init.h> 35#include <linux/init.h>
36#include <linux/freezer.h>
36#include <linux/wait.h> 37#include <linux/wait.h>
37#include <linux/device.h> 38#include <linux/device.h>
38#include <linux/net.h> 39#include <linux/net.h>
@@ -1940,7 +1941,6 @@ static int rfcomm_run(void *unused)
1940 1941
1941 daemonize("krfcommd"); 1942 daemonize("krfcommd");
1942 set_user_nice(current, -10); 1943 set_user_nice(current, -10);
1943 current->flags |= PF_NOFREEZE;
1944 1944
1945 BT_DBG(""); 1945 BT_DBG("");
1946 1946
diff --git a/net/compat.c b/net/compat.c
index 9a0f5f2b90c8..d74d82155d78 100644
--- a/net/compat.c
+++ b/net/compat.c
@@ -276,7 +276,8 @@ void scm_detach_fds_compat(struct msghdr *kmsg, struct scm_cookie *scm)
276 err = security_file_receive(fp[i]); 276 err = security_file_receive(fp[i]);
277 if (err) 277 if (err)
278 break; 278 break;
279 err = get_unused_fd(); 279 err = get_unused_fd_flags(MSG_CMSG_CLOEXEC & kmsg->msg_flags
280 ? O_CLOEXEC : 0);
280 if (err < 0) 281 if (err < 0)
281 break; 282 break;
282 new_fd = err; 283 new_fd = err;
diff --git a/net/core/netpoll.c b/net/core/netpoll.c
index d1264e9a50a8..de1b26aa5720 100644
--- a/net/core/netpoll.c
+++ b/net/core/netpoll.c
@@ -124,13 +124,6 @@ static void poll_napi(struct netpoll *np)
124 if (test_bit(__LINK_STATE_RX_SCHED, &np->dev->state) && 124 if (test_bit(__LINK_STATE_RX_SCHED, &np->dev->state) &&
125 npinfo->poll_owner != smp_processor_id() && 125 npinfo->poll_owner != smp_processor_id() &&
126 spin_trylock(&npinfo->poll_lock)) { 126 spin_trylock(&npinfo->poll_lock)) {
127 /* When calling dev->poll from poll_napi, we may end up in
128 * netif_rx_complete. However, only the CPU to which the
129 * device was queued is allowed to remove it from poll_list.
130 * Setting POLL_LIST_FROZEN tells netif_rx_complete
131 * to leave the NAPI state alone.
132 */
133 set_bit(__LINK_STATE_POLL_LIST_FROZEN, &np->dev->state);
134 npinfo->rx_flags |= NETPOLL_RX_DROP; 127 npinfo->rx_flags |= NETPOLL_RX_DROP;
135 atomic_inc(&trapped); 128 atomic_inc(&trapped);
136 129
@@ -138,7 +131,6 @@ static void poll_napi(struct netpoll *np)
138 131
139 atomic_dec(&trapped); 132 atomic_dec(&trapped);
140 npinfo->rx_flags &= ~NETPOLL_RX_DROP; 133 npinfo->rx_flags &= ~NETPOLL_RX_DROP;
141 clear_bit(__LINK_STATE_POLL_LIST_FROZEN, &np->dev->state);
142 spin_unlock(&npinfo->poll_lock); 134 spin_unlock(&npinfo->poll_lock);
143 } 135 }
144} 136}
diff --git a/net/core/pktgen.c b/net/core/pktgen.c
index 75215331b045..bca787fdbc51 100644
--- a/net/core/pktgen.c
+++ b/net/core/pktgen.c
@@ -3465,6 +3465,8 @@ static int pktgen_thread_worker(void *arg)
3465 3465
3466 set_current_state(TASK_INTERRUPTIBLE); 3466 set_current_state(TASK_INTERRUPTIBLE);
3467 3467
3468 set_freezable();
3469
3468 while (!kthread_should_stop()) { 3470 while (!kthread_should_stop()) {
3469 pkt_dev = next_to_run(t); 3471 pkt_dev = next_to_run(t);
3470 3472
diff --git a/net/core/scm.c b/net/core/scm.c
index 292ad8d5ad76..44c4ec2c8769 100644
--- a/net/core/scm.c
+++ b/net/core/scm.c
@@ -228,7 +228,8 @@ void scm_detach_fds(struct msghdr *msg, struct scm_cookie *scm)
228 err = security_file_receive(fp[i]); 228 err = security_file_receive(fp[i]);
229 if (err) 229 if (err)
230 break; 230 break;
231 err = get_unused_fd(); 231 err = get_unused_fd_flags(MSG_CMSG_CLOEXEC & msg->msg_flags
232 ? O_CLOEXEC : 0);
232 if (err < 0) 233 if (err < 0)
233 break; 234 break;
234 new_fd = err; 235 new_fd = err;
diff --git a/net/ieee80211/softmac/ieee80211softmac_assoc.c b/net/ieee80211/softmac/ieee80211softmac_assoc.c
index cc8110bdd579..afb6c6698b27 100644
--- a/net/ieee80211/softmac/ieee80211softmac_assoc.c
+++ b/net/ieee80211/softmac/ieee80211softmac_assoc.c
@@ -271,8 +271,11 @@ ieee80211softmac_assoc_work(struct work_struct *work)
271 */ 271 */
272 dprintk(KERN_INFO PFX "Associate: Scanning for networks first.\n"); 272 dprintk(KERN_INFO PFX "Associate: Scanning for networks first.\n");
273 ieee80211softmac_notify(mac->dev, IEEE80211SOFTMAC_EVENT_SCAN_FINISHED, ieee80211softmac_assoc_notify_scan, NULL); 273 ieee80211softmac_notify(mac->dev, IEEE80211SOFTMAC_EVENT_SCAN_FINISHED, ieee80211softmac_assoc_notify_scan, NULL);
274 if (ieee80211softmac_start_scan(mac)) 274 if (ieee80211softmac_start_scan(mac)) {
275 dprintk(KERN_INFO PFX "Associate: failed to initiate scan. Is device up?\n"); 275 dprintk(KERN_INFO PFX "Associate: failed to initiate scan. Is device up?\n");
276 mac->associnfo.associating = 0;
277 mac->associnfo.associated = 0;
278 }
276 goto out; 279 goto out;
277 } else { 280 } else {
278 mac->associnfo.associating = 0; 281 mac->associnfo.associating = 0;
diff --git a/net/netlabel/netlabel_user.c b/net/netlabel/netlabel_user.c
index 42f12bd65964..89dcc485653b 100644
--- a/net/netlabel/netlabel_user.c
+++ b/net/netlabel/netlabel_user.c
@@ -46,10 +46,6 @@
46#include "netlabel_cipso_v4.h" 46#include "netlabel_cipso_v4.h"
47#include "netlabel_user.h" 47#include "netlabel_user.h"
48 48
49/* do not do any auditing if audit_enabled == 0, see kernel/audit.c for
50 * details */
51extern int audit_enabled;
52
53/* 49/*
54 * NetLabel NETLINK Setup Functions 50 * NetLabel NETLINK Setup Functions
55 */ 51 */
diff --git a/net/socket.c b/net/socket.c
index f4530196a70a..b71114250046 100644
--- a/net/socket.c
+++ b/net/socket.c
@@ -1939,9 +1939,7 @@ asmlinkage long sys_recvmsg(int fd, struct msghdr __user *msg,
1939 total_len = err; 1939 total_len = err;
1940 1940
1941 cmsg_ptr = (unsigned long)msg_sys.msg_control; 1941 cmsg_ptr = (unsigned long)msg_sys.msg_control;
1942 msg_sys.msg_flags = 0; 1942 msg_sys.msg_flags = flags & (MSG_CMSG_CLOEXEC|MSG_CMSG_COMPAT);
1943 if (MSG_CMSG_COMPAT & flags)
1944 msg_sys.msg_flags = MSG_CMSG_COMPAT;
1945 1943
1946 if (sock->file->f_flags & O_NONBLOCK) 1944 if (sock->file->f_flags & O_NONBLOCK)
1947 flags |= MSG_DONTWAIT; 1945 flags |= MSG_DONTWAIT;
diff --git a/net/sunrpc/auth.c b/net/sunrpc/auth.c
index aa55d0a03e6f..29a8ecc60928 100644
--- a/net/sunrpc/auth.c
+++ b/net/sunrpc/auth.c
@@ -543,17 +543,18 @@ rpcauth_uptodatecred(struct rpc_task *task)
543 test_bit(RPCAUTH_CRED_UPTODATE, &cred->cr_flags) != 0; 543 test_bit(RPCAUTH_CRED_UPTODATE, &cred->cr_flags) != 0;
544} 544}
545 545
546 546static struct shrinker rpc_cred_shrinker = {
547static struct shrinker *rpc_cred_shrinker; 547 .shrink = rpcauth_cache_shrinker,
548 .seeks = DEFAULT_SEEKS,
549};
548 550
549void __init rpcauth_init_module(void) 551void __init rpcauth_init_module(void)
550{ 552{
551 rpc_init_authunix(); 553 rpc_init_authunix();
552 rpc_cred_shrinker = set_shrinker(DEFAULT_SEEKS, rpcauth_cache_shrinker); 554 register_shrinker(&rpc_cred_shrinker);
553} 555}
554 556
555void __exit rpcauth_remove_module(void) 557void __exit rpcauth_remove_module(void)
556{ 558{
557 if (rpc_cred_shrinker != NULL) 559 unregister_shrinker(&rpc_cred_shrinker);
558 remove_shrinker(rpc_cred_shrinker);
559} 560}
diff --git a/net/sunrpc/auth_gss/auth_gss.c b/net/sunrpc/auth_gss/auth_gss.c
index baf4096d52d4..abfda33bac64 100644
--- a/net/sunrpc/auth_gss/auth_gss.c
+++ b/net/sunrpc/auth_gss/auth_gss.c
@@ -43,6 +43,7 @@
43#include <linux/types.h> 43#include <linux/types.h>
44#include <linux/slab.h> 44#include <linux/slab.h>
45#include <linux/sched.h> 45#include <linux/sched.h>
46#include <linux/smp_lock.h>
46#include <linux/pagemap.h> 47#include <linux/pagemap.h>
47#include <linux/sunrpc/clnt.h> 48#include <linux/sunrpc/clnt.h>
48#include <linux/sunrpc/auth.h> 49#include <linux/sunrpc/auth.h>
diff --git a/net/sunrpc/auth_gss/gss_krb5_mech.c b/net/sunrpc/auth_gss/gss_krb5_mech.c
index 71b9daefdff3..9843eacef11d 100644
--- a/net/sunrpc/auth_gss/gss_krb5_mech.c
+++ b/net/sunrpc/auth_gss/gss_krb5_mech.c
@@ -231,6 +231,7 @@ static struct pf_desc gss_kerberos_pfs[] = {
231static struct gss_api_mech gss_kerberos_mech = { 231static struct gss_api_mech gss_kerberos_mech = {
232 .gm_name = "krb5", 232 .gm_name = "krb5",
233 .gm_owner = THIS_MODULE, 233 .gm_owner = THIS_MODULE,
234 .gm_oid = {9, (void *)"\x2a\x86\x48\x86\xf7\x12\x01\x02\x02"},
234 .gm_ops = &gss_kerberos_ops, 235 .gm_ops = &gss_kerberos_ops,
235 .gm_pf_num = ARRAY_SIZE(gss_kerberos_pfs), 236 .gm_pf_num = ARRAY_SIZE(gss_kerberos_pfs),
236 .gm_pfs = gss_kerberos_pfs, 237 .gm_pfs = gss_kerberos_pfs,
diff --git a/net/sunrpc/auth_gss/gss_mech_switch.c b/net/sunrpc/auth_gss/gss_mech_switch.c
index 26872517ccf3..61801a069ff0 100644
--- a/net/sunrpc/auth_gss/gss_mech_switch.c
+++ b/net/sunrpc/auth_gss/gss_mech_switch.c
@@ -194,6 +194,20 @@ gss_mech_get_by_pseudoflavor(u32 pseudoflavor)
194EXPORT_SYMBOL(gss_mech_get_by_pseudoflavor); 194EXPORT_SYMBOL(gss_mech_get_by_pseudoflavor);
195 195
196u32 196u32
197gss_svc_to_pseudoflavor(struct gss_api_mech *gm, u32 service)
198{
199 int i;
200
201 for (i = 0; i < gm->gm_pf_num; i++) {
202 if (gm->gm_pfs[i].service == service) {
203 return gm->gm_pfs[i].pseudoflavor;
204 }
205 }
206 return RPC_AUTH_MAXFLAVOR; /* illegal value */
207}
208EXPORT_SYMBOL(gss_svc_to_pseudoflavor);
209
210u32
197gss_pseudoflavor_to_service(struct gss_api_mech *gm, u32 pseudoflavor) 211gss_pseudoflavor_to_service(struct gss_api_mech *gm, u32 pseudoflavor)
198{ 212{
199 int i; 213 int i;
diff --git a/net/sunrpc/auth_gss/gss_spkm3_mech.c b/net/sunrpc/auth_gss/gss_spkm3_mech.c
index 577d590e755f..5deb4b6e4514 100644
--- a/net/sunrpc/auth_gss/gss_spkm3_mech.c
+++ b/net/sunrpc/auth_gss/gss_spkm3_mech.c
@@ -217,6 +217,7 @@ static struct pf_desc gss_spkm3_pfs[] = {
217static struct gss_api_mech gss_spkm3_mech = { 217static struct gss_api_mech gss_spkm3_mech = {
218 .gm_name = "spkm3", 218 .gm_name = "spkm3",
219 .gm_owner = THIS_MODULE, 219 .gm_owner = THIS_MODULE,
220 .gm_oid = {7, "\053\006\001\005\005\001\003"},
220 .gm_ops = &gss_spkm3_ops, 221 .gm_ops = &gss_spkm3_ops,
221 .gm_pf_num = ARRAY_SIZE(gss_spkm3_pfs), 222 .gm_pf_num = ARRAY_SIZE(gss_spkm3_pfs),
222 .gm_pfs = gss_spkm3_pfs, 223 .gm_pfs = gss_spkm3_pfs,
diff --git a/net/sunrpc/auth_gss/svcauth_gss.c b/net/sunrpc/auth_gss/svcauth_gss.c
index c094583386fd..490697542fc2 100644
--- a/net/sunrpc/auth_gss/svcauth_gss.c
+++ b/net/sunrpc/auth_gss/svcauth_gss.c
@@ -743,6 +743,15 @@ find_gss_auth_domain(struct gss_ctx *ctx, u32 svc)
743 743
744static struct auth_ops svcauthops_gss; 744static struct auth_ops svcauthops_gss;
745 745
746u32 svcauth_gss_flavor(struct auth_domain *dom)
747{
748 struct gss_domain *gd = container_of(dom, struct gss_domain, h);
749
750 return gd->pseudoflavor;
751}
752
753EXPORT_SYMBOL(svcauth_gss_flavor);
754
746int 755int
747svcauth_gss_register_pseudoflavor(u32 pseudoflavor, char * name) 756svcauth_gss_register_pseudoflavor(u32 pseudoflavor, char * name)
748{ 757{
@@ -913,10 +922,23 @@ svcauth_gss_set_client(struct svc_rqst *rqstp)
913 struct gss_svc_data *svcdata = rqstp->rq_auth_data; 922 struct gss_svc_data *svcdata = rqstp->rq_auth_data;
914 struct rsc *rsci = svcdata->rsci; 923 struct rsc *rsci = svcdata->rsci;
915 struct rpc_gss_wire_cred *gc = &svcdata->clcred; 924 struct rpc_gss_wire_cred *gc = &svcdata->clcred;
925 int stat;
916 926
917 rqstp->rq_client = find_gss_auth_domain(rsci->mechctx, gc->gc_svc); 927 /*
918 if (rqstp->rq_client == NULL) 928 * A gss export can be specified either by:
929 * export *(sec=krb5,rw)
930 * or by
931 * export gss/krb5(rw)
932 * The latter is deprecated; but for backwards compatibility reasons
933 * the nfsd code will still fall back on trying it if the former
934 * doesn't work; so we try to make both available to nfsd, below.
935 */
936 rqstp->rq_gssclient = find_gss_auth_domain(rsci->mechctx, gc->gc_svc);
937 if (rqstp->rq_gssclient == NULL)
919 return SVC_DENIED; 938 return SVC_DENIED;
939 stat = svcauth_unix_set_client(rqstp);
940 if (stat == SVC_DROP)
941 return stat;
920 return SVC_OK; 942 return SVC_OK;
921} 943}
922 944
@@ -1088,7 +1110,6 @@ svcauth_gss_accept(struct svc_rqst *rqstp, __be32 *authp)
1088 svc_putnl(resv, GSS_SEQ_WIN); 1110 svc_putnl(resv, GSS_SEQ_WIN);
1089 if (svc_safe_putnetobj(resv, &rsip->out_token)) 1111 if (svc_safe_putnetobj(resv, &rsip->out_token))
1090 goto drop; 1112 goto drop;
1091 rqstp->rq_client = NULL;
1092 } 1113 }
1093 goto complete; 1114 goto complete;
1094 case RPC_GSS_PROC_DESTROY: 1115 case RPC_GSS_PROC_DESTROY:
@@ -1131,6 +1152,8 @@ svcauth_gss_accept(struct svc_rqst *rqstp, __be32 *authp)
1131 } 1152 }
1132 svcdata->rsci = rsci; 1153 svcdata->rsci = rsci;
1133 cache_get(&rsci->h); 1154 cache_get(&rsci->h);
1155 rqstp->rq_flavor = gss_svc_to_pseudoflavor(
1156 rsci->mechctx->mech_type, gc->gc_svc);
1134 ret = SVC_OK; 1157 ret = SVC_OK;
1135 goto out; 1158 goto out;
1136 } 1159 }
@@ -1317,6 +1340,9 @@ out_err:
1317 if (rqstp->rq_client) 1340 if (rqstp->rq_client)
1318 auth_domain_put(rqstp->rq_client); 1341 auth_domain_put(rqstp->rq_client);
1319 rqstp->rq_client = NULL; 1342 rqstp->rq_client = NULL;
1343 if (rqstp->rq_gssclient)
1344 auth_domain_put(rqstp->rq_gssclient);
1345 rqstp->rq_gssclient = NULL;
1320 if (rqstp->rq_cred.cr_group_info) 1346 if (rqstp->rq_cred.cr_group_info)
1321 put_group_info(rqstp->rq_cred.cr_group_info); 1347 put_group_info(rqstp->rq_cred.cr_group_info);
1322 rqstp->rq_cred.cr_group_info = NULL; 1348 rqstp->rq_cred.cr_group_info = NULL;
diff --git a/net/sunrpc/svcauth_unix.c b/net/sunrpc/svcauth_unix.c
index 07dcd20cbee4..411479411b21 100644
--- a/net/sunrpc/svcauth_unix.c
+++ b/net/sunrpc/svcauth_unix.c
@@ -5,6 +5,7 @@
5#include <linux/sunrpc/xdr.h> 5#include <linux/sunrpc/xdr.h>
6#include <linux/sunrpc/svcsock.h> 6#include <linux/sunrpc/svcsock.h>
7#include <linux/sunrpc/svcauth.h> 7#include <linux/sunrpc/svcauth.h>
8#include <linux/sunrpc/gss_api.h>
8#include <linux/err.h> 9#include <linux/err.h>
9#include <linux/seq_file.h> 10#include <linux/seq_file.h>
10#include <linux/hash.h> 11#include <linux/hash.h>
@@ -637,7 +638,7 @@ static int unix_gid_find(uid_t uid, struct group_info **gip,
637 } 638 }
638} 639}
639 640
640static int 641int
641svcauth_unix_set_client(struct svc_rqst *rqstp) 642svcauth_unix_set_client(struct svc_rqst *rqstp)
642{ 643{
643 struct sockaddr_in *sin = svc_addr_in(rqstp); 644 struct sockaddr_in *sin = svc_addr_in(rqstp);
@@ -672,6 +673,8 @@ svcauth_unix_set_client(struct svc_rqst *rqstp)
672 return SVC_OK; 673 return SVC_OK;
673} 674}
674 675
676EXPORT_SYMBOL(svcauth_unix_set_client);
677
675static int 678static int
676svcauth_null_accept(struct svc_rqst *rqstp, __be32 *authp) 679svcauth_null_accept(struct svc_rqst *rqstp, __be32 *authp)
677{ 680{
@@ -707,6 +710,7 @@ svcauth_null_accept(struct svc_rqst *rqstp, __be32 *authp)
707 svc_putnl(resv, RPC_AUTH_NULL); 710 svc_putnl(resv, RPC_AUTH_NULL);
708 svc_putnl(resv, 0); 711 svc_putnl(resv, 0);
709 712
713 rqstp->rq_flavor = RPC_AUTH_NULL;
710 return SVC_OK; 714 return SVC_OK;
711} 715}
712 716
@@ -784,6 +788,7 @@ svcauth_unix_accept(struct svc_rqst *rqstp, __be32 *authp)
784 svc_putnl(resv, RPC_AUTH_NULL); 788 svc_putnl(resv, RPC_AUTH_NULL);
785 svc_putnl(resv, 0); 789 svc_putnl(resv, 0);
786 790
791 rqstp->rq_flavor = RPC_AUTH_UNIX;
787 return SVC_OK; 792 return SVC_OK;
788 793
789badcred: 794badcred: