Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-28 Thread Sagi Grimberg
On 4/27/2014 3:37 PM, Chuck Lever wrote: SNIP Why not first create a new id+qp and assign them - and then destroy the old id+qp? see SRP related section: ib_srp.x:srp_create_target_ib() Anyway it is indeed important to guarantee that no xmit flows happens concurrently to that, and cleanups

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-27 Thread Chuck Lever
On Apr 27, 2014, at 6:12 AM, Sagi Grimberg sa...@dev.mellanox.co.il wrote: On 4/24/2014 6:01 PM, Chuck Lever wrote: On Apr 24, 2014, at 3:12 AM, Sagi Grimberg sa...@dev.mellanox.co.il wrote: On 4/24/2014 2:30 AM, Devesh Sharma wrote: Hi Chuck Following is the complete call trace of a

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-24 Thread Sagi Grimberg
On 4/24/2014 2:30 AM, Devesh Sharma wrote: Hi Chuck Following is the complete call trace of a typical NFS-RDMA transaction while mounting a share. It is unavoidable to stop calling post-send in case it is not created. Therefore, applying checks to the connection state is a must While

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-24 Thread Chuck Lever
On Apr 24, 2014, at 3:12 AM, Sagi Grimberg sa...@dev.mellanox.co.il wrote: On 4/24/2014 2:30 AM, Devesh Sharma wrote: Hi Chuck Following is the complete call trace of a typical NFS-RDMA transaction while mounting a share. It is unavoidable to stop calling post-send in case it is not

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-24 Thread Devesh Sharma
; Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 24, 2014, at 3:12 AM, Sagi Grimberg sa...@dev.mellanox.co.il wrote: On 4/24/2014 2:30 AM, Devesh Sharma wrote: Hi Chuck Following

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-23 Thread Devesh Sharma
15, 2014 11:56 PM To: Chuck Lever Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks -Original Message- From: Chuck Lever [mailto:chuck.le...@oracle.com] Sent: Tuesday, April 15, 2014 6:10

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-15 Thread Devesh Sharma
-Original Message- From: Chuck Lever [mailto:chuck.le...@oracle.com] Sent: Tuesday, April 15, 2014 6:10 AM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 14

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-14 Thread Chuck Lever
Hi Devesh- On Apr 13, 2014, at 12:01 AM, Chuck Lever chuck.le...@oracle.com wrote: On Apr 11, 2014, at 7:51 PM, Devesh Sharma devesh.sha...@emulex.com wrote: Hi Chuck, Yes that is the case, Following is the trace I got. 4RPC: 355 setting alarm for 6 ms 4RPC: 355 sync task

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-14 Thread Devesh Sharma
Hi Chuck -Original Message- From: Chuck Lever [mailto:chuck.le...@oracle.com] Sent: Tuesday, April 15, 2014 2:24 AM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks Hi

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-14 Thread Devesh Sharma
V1] NFS-RDMA: fix qp pointer validation checks Hi Devesh- On Apr 10, 2014, at 1:54 PM, Devesh Sharma devesh.sha...@emulex.com wrote: Alright here it is: 3ocrdma_mbx_create_qp(0) rq_err 3ocrdma_mbx_create_qp(0) sq_err 3ocrdma_create_qp(0) error=-1 1BUG: unable to handle

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-14 Thread Chuck Lever
Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks Hi Devesh- On Apr 13, 2014, at 12:01 AM, Chuck Lever chuck.le...@oracle.com wrote: On Apr 11, 2014, at 7:51 PM, Devesh Sharma devesh.sha...@emulex.com wrote: Hi Chuck, Yes that is the case, Following is the trace

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-12 Thread Chuck Lever
11:21 PM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 10, 2014, at 1:42 PM, Devesh Sharma devesh.sha...@emulex.com wrote: However it seems to me the new (!ia-ri_id-qp

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-11 Thread Devesh Sharma
...@vger.kernel.org [mailto:linux-rdma- ow...@vger.kernel.org] On Behalf Of Chuck Lever Sent: Thursday, April 10, 2014 11:21 PM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 10

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Steve Wise
Lever [mailto:chuck.le...@oracle.com] Sent: Thursday, April 10, 2014 1:57 AM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 9, 2014, at 4:22 PM, Trond Myklebust trond.mykleb

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Devesh Sharma
-Original Message- From: Chuck Lever [mailto:chuck.le...@oracle.com] Sent: Thursday, April 10, 2014 5:56 AM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 9, 2014

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Chuck Lever
@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 9, 2014, at 4:22 PM, Trond Myklebust trond.mykleb...@primarydata.com wrote: Hi Devesh, This looks a lot better. I still have a couple of small suggestions, though. On Apr 9

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Chuck Lever
On Apr 10, 2014, at 1:42 PM, Devesh Sharma devesh.sha...@emulex.com wrote: However it seems to me the new (!ia-ri_id-qp) checks outside the connect logic are unnecessary. Clearly, as you noticed, the ib_post_{send,recv} verbs do not check that their qp argument is NULL before

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Devesh Sharma
List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 10, 2014, at 1:42 PM, Devesh Sharma devesh.sha...@emulex.com wrote: However it seems to me the new (!ia-ri_id-qp) checks outside the connect logic are unnecessary

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Steve Wise
-Original Message- From: Chuck Lever [mailto:chuck.le...@oracle.com] Sent: Thursday, April 10, 2014 12:44 PM To: Steve Wise Cc: Devesh Sharma; Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-10 Thread Chuck Lever
Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 10, 2014, at 1:42 PM, Devesh Sharma devesh.sha...@emulex.com wrote: However it seems to me the new (!ia-ri_id-qp) checks outside

[PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-09 Thread Devesh Sharma
If the rdma_create_qp fails to create qp due to device firmware being in invalid state xprtrdma still tries to destroy the non-existant qp and ends up in a NULL pointer reference crash. Adding proper checks for vaidating QP pointer avoids this to happen. Signed-off-by: Devesh Sharma

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-09 Thread Trond Myklebust
Hi Devesh, This looks a lot better. I still have a couple of small suggestions, though. On Apr 9, 2014, at 14:40, Devesh Sharma devesh.sha...@emulex.com wrote: If the rdma_create_qp fails to create qp due to device firmware being in invalid state xprtrdma still tries to destroy the

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-09 Thread Chuck Lever
On Apr 9, 2014, at 4:22 PM, Trond Myklebust trond.mykleb...@primarydata.com wrote: Hi Devesh, This looks a lot better. I still have a couple of small suggestions, though. On Apr 9, 2014, at 14:40, Devesh Sharma devesh.sha...@emulex.com wrote: If the rdma_create_qp fails to create qp

RE: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-09 Thread Devesh Sharma
Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks On Apr 9, 2014, at 4:22 PM, Trond Myklebust trond.mykleb...@primarydata.com wrote: Hi Devesh, This looks a lot better. I still have a couple of small suggestions, though. On Apr 9, 2014, at 14:40, Devesh Sharma

Re: [PATCH V1] NFS-RDMA: fix qp pointer validation checks

2014-04-09 Thread Chuck Lever
will trigger a separate completion event. -Original Message- From: Chuck Lever [mailto:chuck.le...@oracle.com] Sent: Thursday, April 10, 2014 1:57 AM To: Devesh Sharma Cc: Linux NFS Mailing List; linux-rdma@vger.kernel.org; Trond Myklebust Subject: Re: [PATCH V1] NFS-RDMA: fix qp pointer