Re: 2.6.3-rc3-mm1 won't boot: nfs hangs @ slab.c:1931

J. Bruce Fields
2004-02-11T18:32:02Z

On Wed, Feb 11, 2004 at 07:20:32PM +0100, Jurriaan wrote:
> My debian system mentions
>
> Exporting directories ... debug: sleeping function called from illegal
> context at mm/slab.c:1931
>
> The system is an up-to-date Debian Unstable dual P3/450.
> I've search my lkml archives and can't find any mention of this.

You need the following.--Bruce Fields

diff -puN net/sunrpc/svcauth.c~neil_NfsdCacheImprove net/sunrpc/svcauth.c
--- linux-2.6.1/net/sunrpc/svcauth.c~neil_NfsdCacheImprove 2004-02-08 13:54:41.000000000 -0500
+++ linux-2.6.1-bfields/net/sunrpc/svcauth.c 2004-02-08 14:09:08.000000000 -0500
@@ -150,7 +150,11 @@ DefineCacheLookup(struct auth_domain,
&auth_domain_cache,
auth_domain_hash(item),
auth_domain_match(tmp, item),
- kfree(new); if(!set) return NULL;
+ kfree(new); if(!set) {
+ if (new) write_unlock(&auth_domain_cache.hash_lock);
+ else read_unlock(&auth_domain_cache.hash_lock);
+ return NULL;
+ }
new=item; atomic_inc(&new->h.refcnt),
/* no update */,
0 /* no inplace updates */

_