From: NeilBrown Fix Oops at nfsd shutdown. Reap any open nfs4_stateowners remaining on the close_lru hash list prior to reaping nfs4_clients at shutdown. Signed-off-by: Andy Adamson Signed-off-by: J. Bruce Fields Signed-off-by: Neil Brown Signed-off-by: Andrew Morton --- 25-akpm/fs/nfsd/nfs4state.c | 7 +++++++ 1 files changed, 7 insertions(+) diff -puN fs/nfsd/nfs4state.c~nfsd4-fix-oops-on-nfsd4-shutdown fs/nfsd/nfs4state.c --- 25/fs/nfsd/nfs4state.c~nfsd4-fix-oops-on-nfsd4-shutdown 2005-03-07 23:55:15.000000000 -0800 +++ 25-akpm/fs/nfsd/nfs4state.c 2005-03-07 23:55:15.000000000 -0800 @@ -3238,8 +3238,15 @@ __nfs4_state_shutdown(void) int i; struct nfs4_client *clp = NULL; struct nfs4_delegation *dp = NULL; + struct nfs4_stateowner *sop = NULL; struct list_head *pos, *next; + list_for_each_safe(pos, next, &close_lru) { + sop = list_entry(pos, struct nfs4_stateowner, so_close_lru); + list_del(&sop->so_close_lru); + nfs4_put_stateowner(sop); + } + for (i = 0; i < CLIENT_HASH_SIZE; i++) { while (!list_empty(&conf_id_hashtbl[i])) { clp = list_entry(conf_id_hashtbl[i].next, struct nfs4_client, cl_idhash); _