2004-03-15 19:47:15

by Dave Jones

[permalink] [raw]
Subject: 2.6.4 sunrpc oops.

To repeat..

modprobe auth_rpcgss
rmmod auth_rpcgss
rmmod sunrpc
*bang*

Seems to survive rmmod sunrpc usually, so it's the auth_rpcgcc
module leaving something around long after its dead perhaps?

Dave

Unable to handle kernel paging request at virtual address c7890674
printing eip:
c78ffabf
*pde = 06f3f067
*pte = 00000000
Oops: 0000 [#1]
SMP
CPU: 0
EIP: 0060:[<c78ffabf>] Not tainted
EFLAGS: 00010283 (2.6.4-prep)
EIP is at cache_clean+0xbb/0x298 [sunrpc]
eax: 4056078d ebx: c7912020 ecx: c789066c edx: c7890640
esi: c031bbd8 edi: 00000000 ebp: c33e5000 esp: c33e5f40
ds: 007b es: 007b ss: 0068
Process rmmod (pid: 1682, threadinfo=c33e5000 task=c5ade670)
Stack: c7912020 c7912020 c7912020 c031bbd8 00000000 c78ffcf4 c78ff7a9 000000cc
000000cc c7912880 c7902e09 c01376cc 00000000 726e7573 c3006370 c3d7a5ac
b8005000 c014f9e1 c359cc98 b8006000 c014fe8f c3d7a5e8 c35f2104 c6c673e4
Call Trace:
[<c78ffcf4>] cache_flush+0x1a/0x3b [sunrpc]
[<c78ff7a9>] cache_unregister+0xa/0x179 [sunrpc]
[<c7902e09>] cleanup_sunrpc+0x14/0x5e [sunrpc]
[<c01376cc>] sys_delete_module+0x115/0x157
[<c014f9e1>] unmap_vma_list+0xe/0x17
[<c014fe8f>] do_munmap+0x17e/0x18a
[<c02c4567>] syscall_call+0x7/0xb

Code: 39 42 34 76 0a 8b 41 d4 a3 84 33 91 c7 eb 12 c7 05 84 33 91


2004-03-15 20:38:56

by J. Bruce Fields

[permalink] [raw]
Subject: Re: 2.6.4 sunrpc oops.

On Mon, Mar 15, 2004 at 07:46:42PM +0000, Dave Jones wrote:
> modprobe auth_rpcgss
> rmmod auth_rpcgss
> rmmod sunrpc
> *bang*
>
> Seems to survive rmmod sunrpc usually, so it's the auth_rpcgcc
> module leaving something around long after its dead perhaps?

Yes, this is my fault, apologies. I'll follow up with a patch as soon
as I've made one....--Bruce Fields

2004-04-21 17:45:32

by J. Bruce Fields

[permalink] [raw]
Subject: Re: 2.6.4 sunrpc oops.

On Mon, Mar 15, 2004 at 03:38:53PM -0500, J. Bruce Fields wrote:
> On Mon, Mar 15, 2004 at 07:46:42PM +0000, Dave Jones wrote:
> > modprobe auth_rpcgss
> > rmmod auth_rpcgss
> > rmmod sunrpc
> > *bang*
> >
> > Seems to survive rmmod sunrpc usually, so it's the auth_rpcgcc
> > module leaving something around long after its dead perhaps?
>
> Yes, this is my fault, apologies. I'll follow up with a patch as soon
> as I've made one....--Bruce Fields

Ugh, sorry for the delay.

--b.

Unregister svcauth_gss caches on exit from gss module; fixes an oops on rmmod.


include/linux/sunrpc/svcauth_gss.h | 1 +
net/sunrpc/auth_gss/auth_gss.c | 1 +
net/sunrpc/auth_gss/svcauth_gss.c | 7 +++++++
3 files changed, 9 insertions(+)

diff -puN include/linux/sunrpc/svcauth_gss.h~nfsd_gss_rmmod_fix include/linux/sunrpc/svcauth_gss.h
--- linux-2.6.6-rc1/include/linux/sunrpc/svcauth_gss.h~nfsd_gss_rmmod_fix 2004-04-21 13:42:56.000000000 -0400
+++ linux-2.6.6-rc1-bfields/include/linux/sunrpc/svcauth_gss.h 2004-04-21 13:42:56.000000000 -0400
@@ -20,6 +20,7 @@
#include <linux/sunrpc/auth_gss.h>

int gss_svc_init(void);
+void gss_svc_shutdown(void);
int svcauth_gss_register_pseudoflavor(u32 pseudoflavor, char * name);

#endif /* __KERNEL__ */
diff -puN net/sunrpc/auth_gss/auth_gss.c~nfsd_gss_rmmod_fix net/sunrpc/auth_gss/auth_gss.c
--- linux-2.6.6-rc1/net/sunrpc/auth_gss/auth_gss.c~nfsd_gss_rmmod_fix 2004-04-21 13:42:56.000000000 -0400
+++ linux-2.6.6-rc1-bfields/net/sunrpc/auth_gss/auth_gss.c 2004-04-21 13:42:56.000000000 -0400
@@ -998,6 +998,7 @@ out:

static void __exit exit_rpcsec_gss(void)
{
+ gss_svc_shutdown();
gss_mech_unregister_all();
rpcauth_unregister(&authgss_ops);
}
diff -puN net/sunrpc/auth_gss/svcauth_gss.c~nfsd_gss_rmmod_fix net/sunrpc/auth_gss/svcauth_gss.c
--- linux-2.6.6-rc1/net/sunrpc/auth_gss/svcauth_gss.c~nfsd_gss_rmmod_fix 2004-04-21 13:42:56.000000000 -0400
+++ linux-2.6.6-rc1-bfields/net/sunrpc/auth_gss/svcauth_gss.c 2004-04-21 13:42:56.000000000 -0400
@@ -1086,3 +1086,10 @@ gss_svc_init(void)
svc_auth_register(RPC_AUTH_GSS, &svcauthops_gss);
return 0;
}
+
+void
+gss_svc_shutdown(void)
+{
+ cache_unregister(&rsc_cache);
+ cache_unregister(&rsi_cache);
+}

_