Re: [PATCH] RDMA/cma: fix first byte overwritten for AF_IB

2014-12-17 Thread Jinpu Wang
Hi Or,

We have some trouble in the past about IPoIB support about neighbour
discovery, AF_IB doesn't relay on IPoIB, so
we think have another option maybe give us more safe in some cases.



On Wed, Dec 17, 2014 at 11:40 AM, Or Gerlitz ogerl...@mellanox.com wrote:
 On 12/16/2014 5:43 PM, Jack Wang wrote:

 If user attach private data for AF_IB,


 Just out of curiosity, can you share what was the motivation for you to use
 AF_IB?


 Or.


 the first byte will
 be overwritten, because we always set the cma version no matter
 family is AF_IB, so move the version set inside if condition.





-- 
Mit freundlichen Grüßen,
Best Regards,

Jack Wang

Linux Kernel Developer Storage
ProfitBricks GmbH  The IaaS-Company.

ProfitBricks GmbH
Greifswalder Str. 207
D - 10405 Berlin
Tel: +49 30 5770083-42
Fax: +49 30 5770085-98
Email: jinpu.w...@profitbricks.com
URL: http://www.profitbricks.de

Sitz der Gesellschaft: Berlin.
Registergericht: Amtsgericht Charlottenburg, HRB 125506 B.
Geschäftsführer: Andreas Gauger, Achim Weiss.
--
To unsubscribe from this list: send the line unsubscribe linux-rdma in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RFC: FMR support in SRP

2014-09-19 Thread Jinpu Wang
Hi Bart and all,

During go through SRP FMR support, I found ib_srp pre-alloc
fmr_list/map_page in each request,
fmr_list are alloced as many as target-cmd_sg_cnt

I add some debug message when run fio test with different settings.
Result show, state.ndesc and state.nmdesc is 1, state.npages is 0,
after srp_map_sg,
my question is : do we really need as many cmd_sg_cnt fmr_list, or I
miss something,  ndesc and nmdesc could be bigger than 1?



-- 

Mit freundlichen Grüßen,
Best Regards,

Jack Wang

Linux Kernel Developer Storage
ProfitBricks GmbH  The IaaS-Company.
--
To unsubscribe from this list: send the line unsubscribe linux-rdma in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: RFC: FMR support in SRP

2014-09-19 Thread Jinpu Wang


 Hello Jack,

 Did you know that file descriptor 0 corresponds to stdin ? With command-line
 option -w the test program reads data from stdin and sends that data to a
 SCSI device. I think the test program is waiting for you to provide input
 data :-)

 Bart.

Thanks Bart,

Now I know it:)

This command works, generated 128 descriptors.
./discontiguous-io -l 512  -s /dev/sdb



Thanks a lot.


-- 
Mit freundlichen Grüßen,
Best Regards,

Jack Wang
--
To unsubscribe from this list: send the line unsubscribe linux-rdma in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: RFC: FMR support in SRP

2014-09-19 Thread Jinpu Wang
On Fri, Sep 19, 2014 at 5:35 PM, Jinpu Wang jinpu.w...@profitbricks.com wrote:


 Hello Jack,

 Did you know that file descriptor 0 corresponds to stdin ? With command-line
 option -w the test program reads data from stdin and sends that data to a
 SCSI device. I think the test program is waiting for you to provide input
 data :-)

 Bart.

 Thanks Bart,

 Now I know it:)

 This command works, generated 128 descriptors.
 ./discontiguous-io -l 512  -s /dev/sdb



 Thanks a lot.


 --
 Mit freundlichen Grüßen,
 Best Regards,

 Jack Wang

Another question, in srp_map_finish_fmr, the desc va is set to 0,
could you point me how SRP protect multiple rdma operation write to
same
addr?  or different fmr-rkey will protect this?

-- 

Best Regards,

Jack Wang
--
To unsubscribe from this list: send the line unsubscribe linux-rdma in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: list corruption in IPOIB

2013-05-20 Thread Jinpu Wang
which list_del do you mean? in ipoib_cm_tx_start?

On Mon, May 20, 2013 at 11:05 AM, Or Gerlitz ogerl...@mellanox.com wrote:
 On 19/05/2013 12:17, Jack Wang wrote:

 we added inject_bug sysfs node to make function run into error case, like
 something below. Yes, you are right, we want to speedup the bug reproduce
 process, and we saw the warning and come to conclusion the neigh-list
 corrupted some where. What's your opinion?


 Yes, for the synthetic experiment you made, there's a possible point here:

 Under the CM error flow (e.g your injected error), we delete a neighbour,
 but we also do it from the flow that flush neighbours (e.g when changing the
 device mode from UD to CM, as you did in your script). When this happens
 concurrently, these two code pieces call for deleting the neighbour from the
 list. So the spinlock might not be enough and we should have do
 list_del_init(neigh-list) instead of list_del, helps?

 Or.



-- 
Mit freundlichen Grüßen,
Best Regards,

Jack Wang

Linux Kernel Developer Storage
ProfitBricks GmbH  The IaaS-Company.

ProfitBricks GmbH
Greifswalder Str. 207
D - 10405 Berlin
Tel: +49 30 6098 56991-308
Fax: +49 30 6098 56992-203
Email: jinpu.w...@profitbricks.com
URL: http://www.profitbricks.com

Sitz der Gesellschaft: Berlin.
Registergericht: Amtsgericht Charlottenburg, HRB 125506 B.
Geschäftsführer: Andreas Gauger, Achim Weiss.
--
To unsubscribe from this list: send the line unsubscribe linux-rdma in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: list corruption in IPOIB

2013-05-20 Thread Jinpu Wang
A quick test show the list_corruption warning is gone, after I convert
 all list_del(neigh-list) to  list_del_list(neigh-list).

Test is still running, will update status if anything wrong.

Thanks Or.



On Mon, May 20, 2013 at 12:58 PM, Or Gerlitz ogerl...@mellanox.com wrote:
 On 20/05/2013 12:10, Jinpu Wang wrote:

 which list_del do you mean? in ipoib_cm_tx_start?

 yes, but not only, you can start with 5KG hammer and convert all thesehits
 to list_del_init

 linux-2.6]# grep list_del drivers/infiniband/ulp/ipoib/*.c | grep neigh
 drivers/infiniband/ulp/ipoib/ipoib_cm.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_cm.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_cm.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_main.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_main.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_main.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_main.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_main.c: list_del(neigh-list);
 drivers/infiniband/ulp/ipoib/ipoib_main.c: list_del(neigh-list);




-- 
Mit freundlichen Grüßen,
Best Regards,

Jack Wang

Linux Kernel Developer Storage
ProfitBricks GmbH  The IaaS-Company.

ProfitBricks GmbH
Greifswalder Str. 207
D - 10405 Berlin
Tel: +49 30 6098 56991-308
Fax: +49 30 6098 56992-203
Email: jinpu.w...@profitbricks.com
URL: http://www.profitbricks.com

Sitz der Gesellschaft: Berlin.
Registergericht: Amtsgericht Charlottenburg, HRB 125506 B.
Geschäftsführer: Andreas Gauger, Achim Weiss.
--
To unsubscribe from this list: send the line unsubscribe linux-rdma in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html