public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Trond Myklebust <trond.myklebust@fys.uio.no>
To: Michal Piotrowski <michal.k.k.piotrowski@gmail.com>
Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>,
	bfields@fieldses.org, neilb@suse.de, nfs@lists.sourceforge.net,
	linux-kernel@vger.kernel.org
Subject: Re: [NFS] [BUG] 2.6.23-rc5 kernel BUG at fs/nfs/nfs4xdr.c:945
Date: Sun, 09 Sep 2007 00:12:29 +0200	[thread overview]
Message-ID: <1189289549.13713.4.camel@localhost.localdomain> (raw)
In-Reply-To: <6bffcb0e0709071656o6881fa17y61818a9733293a4c@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 4118 bytes --]

On Sat, 2007-09-08 at 01:56 +0200, Michal Piotrowski wrote:
> Hi,
> 
> On 07/09/2007, Kamalesh Babulal <kamalesh@linux.vnet.ibm.com> wrote:
> > Sep  7 11:42:49 p55lp2 kernel: kernel BUG at fs/nfs/nfs4xdr.c:945!
> > Sep  7 11:42:49 p55lp2 kernel: Oops: Exception in kernel mode, sig: 5 [#1]
> > Sep  7 11:42:49 p55lp2 kernel: SMP NR_CPUS=128 NUMA pSeries
> > Sep  7 11:42:49 p55lp2 kernel: Modules linked in: nfs lockd nfs_acl
> > sunrpc ipv6 loop dm_mod ibmveth sg ibmvscsic sd_mod scsi_mod
> > Sep  7 11:42:49 p55lp2 kernel: NIP: d000000000378044 LR:
> > d000000000378034 CTR: 80000000001c5840
> > Sep  7 11:42:49 p55lp2 kernel: REGS: c0000000d971b050 TRAP: 0700   Not
> > tainted  (2.6.23-rc5-ppc64)
> > Sep  7 11:42:49 p55lp2 kernel: MSR: 8000000000029032 <EE,ME,IR,DR>  CR:
> > 28000444  XER: 00000014
> > Sep  7 11:42:49 p55lp2 kernel: TASK = c000000002787740[11508] 'fsstress'
> > THREAD: c0000000d9718000 CPU: 1
> > Sep  7 11:42:49 p55lp2 kernel: GPR00: 0000000000000001 c0000000d971b2d0
> > d0000000003bd648 0000000000000037
> > Sep  7 11:42:49 p55lp2 kernel: GPR04: 0000000000000000 0000000000000000
> > 0000000000000000 0000000000000000
> > Sep  7 11:42:49 p55lp2 kernel: GPR08: 0000000000000002 c000000000616538
> > c0000000ef7afb58 c000000000616540
> > Sep  7 11:42:49 p55lp2 kernel: GPR12: 0000000000004000 c0000000005e4a80
> > 0000000000000000 00000000200b2510
> > Sep  7 11:42:49 p55lp2 kernel: GPR16: 0000000020105550 00000000200b2534
> > 000000002008c15c 0000000000000001
> > Sep  7 11:42:49 p55lp2 kernel: GPR20: 0000000000000000 0000000000000001
> > fffffffffffff000 c0000000d971ba30
> > Sep  7 11:42:49 p55lp2 kernel: GPR24: d00000000034f524 c0000000dc4f8054
> > c0000000d971b7d0 c0000000d9d313f0
> > Sep  7 11:42:49 p55lp2 kernel: GPR28: 0000000000000276 0000000022000000
> > d0000000003b8d78 0000000000000000
> > Sep  7 11:42:49 p55lp2 kernel: NIP [d000000000378044]
> > .encode_lookup+0x6c/0xbc [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: LR [d000000000378034]
> > .encode_lookup+0x5c/0xbc [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: Call Trace:
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b2d0] [d000000000378034]
> > .encode_lookup+0x5c/0xbc [nfs] (unreliable)
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b370] [d000000000379f8c]
> > .nfs4_xdr_enc_lookup+0x78/0xbc [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b440] [d000000000314534]
> > .rpcauth_wrap_req+0xe4/0x124 [sunrpc]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b4f0] [d00000000030a790]
> > .call_transmit+0x218/0x2b8 [sunrpc]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b590] [d0000000003124d8]
> > .__rpc_execute+0xd4/0x368 [sunrpc]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b630] [d00000000030b114]
> > .rpc_do_run_task+0xc8/0x104 [sunrpc]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b6e0] [d00000000030b224]
> > .rpc_call_sync+0x2c/0x64 [sunrpc]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b760] [d00000000036ef04]
> > ._nfs4_proc_lookupfh+0xd4/0x124 [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b850] [d0000000003719a0]
> > ._nfs4_proc_lookup+0x80/0x21c [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b910] [d000000000371ba4]
> > .nfs4_proc_lookup+0x68/0xac [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971b9c0] [d000000000354bf4]
> > .nfs_lookup+0x158/0x334 [nfs]
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971bbc0] [c0000000000f3a28]
> > .lookup_hash+0xfc/0x140
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971bc60] [c0000000000f7b28]
> > .sys_renameat+0x164/0x228
> > Sep  7 11:42:49 p55lp2 kernel: [c0000000d971be30] [c000000000008534]
> > syscall_exit+0x0/0x40
> > Sep  7 11:42:49 p55lp2 kernel: Instruction dump:
> > Sep  7 11:42:49 p55lp2 kernel: e8410028 7fa4eb78 7c7f1b79 7fb80026
> > 40820014 e8be83a8 e87e8350 4800c5f9
> > Sep  7 11:42:49 p55lp2 kernel: e8410028 7fb80120 7c180026 54001ffe
> > <0b000000> 3800000f 7b850020 387f0008
> 
> Is this a post 2.6.22 regression? Have you tried 2.6.23-rc5-git1?
> (There are a few nfs fixes)
> 
> Regards,
> Michal

It looks like a bug that has been there at least since 2.6.18. Could you
see if this fixes it?

Trond



[-- Attachment #2: Type: message/rfc822, Size: 997 bytes --]

From: Trond Myklebust <Trond.Myklebust@netapp.com>
Subject: No Subject
Date: Sun, 9 Sep 2007 00:10:51 +0200
Message-ID: <1189289549.13713.5.camel@localhost.localdomain>

It doesn't look as if the NFSv4 name length is being initialised correctly
in the struct nfs_server. We need to limit any entry there to
NFS4_MAXNAMLEN.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
---

 fs/nfs/client.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/fs/nfs/client.c b/fs/nfs/client.c
index a49f9fe..54068fb 100644
--- a/fs/nfs/client.c
+++ b/fs/nfs/client.c
@@ -928,6 +928,9 @@ static int nfs4_init_server(struct nfs_server *server,
 
 	error = nfs_init_server_rpcclient(server, authflavour);
 
+	if (server->namelen == 0 || server->namelen > NFS4_MAXNAMLEN)
+		server->namelen = NFS4_MAXNAMLEN;
+
 	/* Done */
 	dprintk("<-- nfs4_init_server() = %d\n", error);
 	return error;

  reply	other threads:[~2007-09-08 22:13 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-07 10:02 [BUG] 2.6.23-rc5 kernel BUG at fs/nfs/nfs4xdr.c:945 Kamalesh Babulal
2007-09-07 15:29 ` J. Bruce Fields
2007-09-10 18:02   ` Kamalesh Babulal
2007-09-07 23:56 ` Michal Piotrowski
2007-09-08 22:12   ` Trond Myklebust [this message]
2007-09-10  8:11     ` [NFS] " suzuki
2007-09-10 21:03       ` Trond Myklebust
2007-09-11  4:56         ` suzuki
2007-09-10 13:06     ` Kamalesh Babulal
2007-09-19 17:31       ` Trond Myklebust
2007-09-24 19:01         ` Kamalesh Babulal
2007-09-24 21:26           ` Trond Myklebust
2007-09-28 12:05             ` Kamalesh Babulal
2007-09-10 12:56   ` Kamalesh Babulal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1189289549.13713.4.camel@localhost.localdomain \
    --to=trond.myklebust@fys.uio.no \
    --cc=bfields@fieldses.org \
    --cc=kamalesh@linux.vnet.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michal.k.k.piotrowski@gmail.com \
    --cc=neilb@suse.de \
    --cc=nfs@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox