From: Greg Kroah-Hartman Date: Fri, 6 Dec 2013 18:33:32 +0000 (-0800) Subject: 3.4-stable patches X-Git-Tag: v3.4.73~8 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=dedb44753341e6b85fa7aba66aaf9cd75d95663b;p=thirdparty%2Fkernel%2Fstable-queue.git 3.4-stable patches added patches: nfsd-use-init_net-for-portmapper.patch --- diff --git a/queue-3.4/nfsd-use-init_net-for-portmapper.patch b/queue-3.4/nfsd-use-init_net-for-portmapper.patch new file mode 100644 index 00000000000..e90eb0126cf --- /dev/null +++ b/queue-3.4/nfsd-use-init_net-for-portmapper.patch @@ -0,0 +1,42 @@ +From f7fb86c6e639360ad9c253cec534819ef928a674 Mon Sep 17 00:00:00 2001 +From: Stanislav Kinsbursky +Date: Mon, 10 Dec 2012 12:19:04 +0300 +Subject: nfsd: use "init_net" for portmapper + +From: Stanislav Kinsbursky + +commit f7fb86c6e639360ad9c253cec534819ef928a674 upstream. + +There could be a situation, when NFSd was started in one network namespace, but +stopped in another one. +This will trigger kernel panic, because RPCBIND client is stored on per-net +NFSd data, and will be NULL on NFSd shutdown. + +Signed-off-by: Stanislav Kinsbursky +Signed-off-by: J. Bruce Fields +Signed-off-by: Weng Meiling +Signed-off-by: Greg Kroah-Hartman + +--- + fs/nfsd/nfssvc.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +--- a/fs/nfsd/nfssvc.c ++++ b/fs/nfsd/nfssvc.c +@@ -11,7 +11,6 @@ + #include + #include + #include +-#include + + #include + #include +@@ -330,7 +329,7 @@ static int nfsd_get_default_max_blksize( + int nfsd_create_serv(void) + { + int error; +- struct net *net = current->nsproxy->net_ns; ++ struct net *net = &init_net; + + WARN_ON(!mutex_is_locked(&nfsd_mutex)); + if (nfsd_serv) { diff --git a/queue-3.4/series b/queue-3.4/series index c2dfa6859f9..582173786c4 100644 --- a/queue-3.4/series +++ b/queue-3.4/series @@ -24,3 +24,4 @@ ipv6-fix-possible-seqlock-deadlock-in-ip6_finish_output2.patch pktgen-xfrm-update-ipv4-header-total-len-and-checksum-after-tranformation.patch hid-picolcd_core-validate-output-report-details.patch mmc-block-fix-a-bug-of-error-handling-in-mmc-driver.patch +nfsd-use-init_net-for-portmapper.patch