[PATCH v1] IB/cma: Use inner P_Key to determine netdev

2015-10-20 Thread Haggai Eran
When discussing the patches to demux ids in rdma_cm instead of ib_cm, it was decided that it is best to use the P_Key value in the packet headers. However, the mlx5 and ipath drivers are currently unable to send correct P_Key values in GMP headers. They always send using a single P_Key that is set

Re: [PATCH v1] IB/cma: Use inner P_Key to determine netdev

2015-10-20 Thread Doug Ledford
On 10/20/2015 02:53 AM, Haggai Eran wrote: > When discussing the patches to demux ids in rdma_cm instead of ib_cm, it > was decided that it is best to use the P_Key value in the packet headers. > However, the mlx5 and ipath drivers are currently unable to send correct > P_Key values in GMP

[PATCH for-next 0/5] RDMA/ocrdma: bug fixes

2015-10-20 Thread Selvin Xavier
This patch series includs fix in CQ door bell logic, check to prevent driver crash and code cleanup. Please apply. Devesh Sharma (1): RDMA/ocrdma: Prevent CQ-Doorbell floods Naga Irrinki (1): RDMA/ocrdma: Check resource ids received in Async CQE Selvin Xavier (3): RDMA/ocrdma: Cleanup

[PATCH for-next 1/5] RDMA/ocrdma: Cleanup unused device list and rcu variables

2015-10-20 Thread Selvin Xavier
ocrdma_dev_list is not used by the driver. So removing the references of this variable. dev->rcu was introduced for the ipv6 notifier for GID management. This is no longer required as the GID management is outside the HW driver. Signed-off-by: Padmanabh Ratnakar

[PATCH for-next 5/5] RDMA/ocrdma: Bump up ocrdma version number to 11.0.0.0

2015-10-20 Thread Selvin Xavier
Updating the version number to 11.0.0.0 Signed-off-by: Selvin Xavier --- drivers/infiniband/hw/ocrdma/ocrdma.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/infiniband/hw/ocrdma/ocrdma.h b/drivers/infiniband/hw/ocrdma/ocrdma.h index

[PATCH for-next 4/5] RDMA/ocrdma: Prevent CQ-Doorbell floods

2015-10-20 Thread Selvin Xavier
From: Devesh Sharma Changing CQ-Doorbell(DB) logic to prevent DB floods, it is supposed to be pressed only if any hw CQE is polled. If cq-arm was requested previously then don't bother about number of hw CQEs polled and arm the CQ. Signed-off-by: Devesh Sharma

[PATCH for-next 3/5] RDMA/ocrdma: Check resource ids received in Async CQE

2015-10-20 Thread Selvin Xavier
From: Naga Irrinki Some versions of the FW sends wrong QP or CQ IDs in the Async CQE. Adding a check to see whether qp or cq structures associated with the CQE is valid. Signed-off-by: Devesh Sharma Signed-off-by: Selvin Xavier

[PATCH for-next 2/5] RDMA/ocrdma: Avoid a possible crash in ocrdma_rem_port_stats

2015-10-20 Thread Selvin Xavier
debugfs_remove should be called before freeing the driver stats resources to avoid any crash during ocrdma_remove. Signed-off-by: Devesh Sharma Signed-off-by: Selvin Xavier --- drivers/infiniband/hw/ocrdma/ocrdma_stats.c | 2 +- 1 file

Re: [PATCH v1] IB/cma: Use inner P_Key to determine netdev

2015-10-20 Thread Haggai Eran
On 20/10/2015 10:20, Doug Ledford wrote: > On 10/20/2015 02:53 AM, Haggai Eran wrote: >> When discussing the patches to demux ids in rdma_cm instead of ib_cm, it >> was decided that it is best to use the P_Key value in the packet headers. >> However, the mlx5 and ipath drivers are currently unable

Re: [PATCH v5 00/26] New fast registration API

2015-10-20 Thread Sagi Grimberg
Doug, are you planning on taking this for 4.4? I think this set has converged towards inclusion. Reminder, this series goes on top of Christoph's wr_cleanup patches and iser bounce buffering cleanup. Sagi. -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Or Gerlitz
On Tue, Oct 20, 2015 at 4:08 PM, Sagi Grimberg wrote: >>> I think this is very useful to have and I'd love having it in 4.4, >>> does anyone have any other comments on this patch? >> Were we ever presented with performance gains achieved using the patch? > Can you

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Sagi Grimberg
So this patch seems to work well for me. I've ran some kernel applications (ipoib, iser, srp, nfs) and a user-space application (ibsrpdm) over mlx4/mlx5 and didn't spot any issues. I think this is very useful to have and I'd love having it in 4.4, does anyone have any other comments on this

Re: [PATCH 00/23] Update driver to 0.9-294

2015-10-20 Thread Moni Shoua
> > Perhaps I did not chose my words carefully enough. > > The largest issue on the TODO list is the refactoring of the code to be > shared between the hfi1 and qib driver. While the hardware between hfi1 and > qib is similar and thus the initial code looked similar, our performance > tuning

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Or Gerlitz
On Tue, Oct 20, 2015 at 3:00 PM, Sagi Grimberg wrote: > So this patch seems to work well for me. I've ran some kernel > applications (ipoib, iser, srp, nfs) and a user-space application > (ibsrpdm) over mlx4/mlx5 and didn't spot any issues. > > I think this is very

Re: [PATCH] IB/cma: Use inner P_Key to determine netdev

2015-10-20 Thread Haggai Eran
On 19/10/2015 21:19, Jason Gunthorpe wrote: > On Mon, Oct 19, 2015 at 09:09:25PM +0300, Haggai Eran wrote: >> When discussing the patches to demux ids in rdma_cm instead of ib_cm, it >> was decided that it is best to use the P_Key value in the packet headers >> [1]. However, some drivers are

Re: [PATCH rdma-cm] IB/core: Fix use after free of ifa

2015-10-20 Thread Matan Barak
On 10/19/2015 6:27 PM, Doug Ledford wrote: On 10/19/2015 10:20 AM, Matan Barak wrote: On 10/19/2015 3:23 PM, Doug Ledford wrote: This is a major cause of the slowness. Unless you have a specific need of them, per-entry rwlocks are *NOT* a good idea. I was going to bring this up

Re: [PATCH TRIVIAL] ib_pack.h: Fix commentary IBA reference for CNP in IB opcode enum

2015-10-20 Thread Doug Ledford
On 09/30/2015 03:04 PM, Hal Rosenstock wrote: > > IBA spec is now 1.3 not 3.1 and vol 1 should be mentioned > as there is also vol 2. > > Signed-off-by: Hal Rosenstock > --- > diff --git a/include/rdma/ib_pack.h b/include/rdma/ib_pack.h > index 709a533..e99d8f9 100644 > ---

Re: [PATCH] IB/iser: fix a comment typo

2015-10-20 Thread Doug Ledford
On 10/04/2015 05:00 AM, Geliang Tang wrote: > Just fix a typo in the code comment. > > Signed-off-by: Geliang Tang This has been picked up for the 4.4 merge window. -- Doug Ledford GPG KeyID: 0E572FDD signature.asc Description:

Re: [PATCH] IB/ucma: check workqueue allocation before usage

2015-10-20 Thread Doug Ledford
On 10/01/2015 10:54 AM, Sasha Levin wrote: > On 09/17/2015 06:59 PM, Jason Gunthorpe wrote: >> On Thu, Sep 17, 2015 at 04:04:19PM -0400, Sasha Levin wrote: >>> Allocating a workqueue might fail, which wasn't checked so far and would >>> lead to NULL ptr derefs when an attempt to use it was made.

Re: 4.4's rdma plate

2015-10-20 Thread Or Gerlitz
On Wed, Oct 14, 2015 at 3:56 PM, Doug Ledford wrote: > On 10/14/2015 12:51 AM, Or Gerlitz wrote: >> On Sun, Oct 11, 2015 at 11:58 PM, Or Gerlitz wrote: >>> Hi Doug, >>> As we're soon on 4.3-rc5, could you please update how things look for 4.4? >>> >>>

Re: 4.4's rdma plate

2015-10-20 Thread Or Gerlitz
On Tue, Oct 20, 2015 at 7:31 PM, Doug Ledford wrote: > On 10/20/2015 12:25 PM, Or Gerlitz wrote: >> On Wed, Oct 14, 2015 at 3:56 PM, Doug Ledford wrote: >>> On 10/14/2015 12:51 AM, Or Gerlitz wrote: On Sun, Oct 11, 2015 at 11:58 PM, Or Gerlitz

Re: [PATCH rdma-RC] IB/cm: Fix sleeping while atomic when creating AH from WC

2015-10-20 Thread Hal Rosenstock
On 10/20/2015 11:57 AM, Hefty, Sean wrote: >> Today, cm assumes paths are reversible primary_path->reversible = 1. > > I can't quickly find a link, but I believe all CM MADs are reversible, per > the spec. Spec citation for this is: C12-5.1.3: All responses generated by the CM protocol shall

Re: [PATCH 00/23] Update driver to 0.9-294

2015-10-20 Thread ira.weiny
On Tue, Oct 20, 2015 at 03:45:47PM +0300, Moni Shoua wrote: > > > > Perhaps I did not chose my words carefully enough. > > > > The largest issue on the TODO list is the refactoring of the code to be > > shared between the hfi1 and qib driver. While the hardware between hfi1 > > and qib is similar

Re: [PATCH] IB/cma: Potential NULL dereference in cma_id_from_event

2015-10-20 Thread Doug Ledford
On 09/21/2015 09:02 AM, Haggai Eran wrote: > If the lookup of a listening ID failed for an AF_IB request, the code > would try to call dev_put() on a NULL net_dev. > > Fixes: be688195bd08 ("IB/cma: Fix net_dev reference leak with failed > requests") > Reported-by: Dan Carpenter

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Sagi Grimberg
But this makes struct ib_device much much bigger, and this structure is used in **fast** path, e.g the ULP traverses through a pointer from struct ib_device to post_send/recv, poll_cq and friends. Umm, all the caps are appended to the end of the ib_device structure so I don't see how it will

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Or Gerlitz
On Tue, Oct 20, 2015 at 6:00 PM, Sagi Grimberg wrote: >> (2) re this one, as I wrote in the past, I am in favor of simple >> caching of struct ib_device_attr on struct ib_device (best with pointer) and >> not adding >> 333 fields to struct ib_device, I don't see the

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Or Gerlitz
On Tue, Oct 20, 2015 at 6:13 PM, Sagi Grimberg wrote: >> The networking community will let you work for 10y before they add a >> field to struct net_device exactly b/c >> of the reason I brought. Why here we can come out of the blue and add >> tens if not hundreds of

RE: [PATCH rdma-RC] IB/cm: Fix sleeping while atomic when creating AH from WC

2015-10-20 Thread Hefty, Sean
> Today, cm assumes paths are reversible primary_path->reversible = 1. I can't quickly find a link, but I believe all CM MADs are reversible, per the spec.

Re: 4.4's rdma plate

2015-10-20 Thread Jason Gunthorpe
On Tue, Oct 20, 2015 at 07:42:25PM +0300, Or Gerlitz wrote: > As for the RoCE patches, you mentioned reviewing them, this is going to > take time, which makes sense. However, the self-multicast loopback prevention > patches are My issue with the latest round of UAPI changes is I don't see any

Re: [PATCH rdma-cm] IB/core: Fix use after free of ifa

2015-10-20 Thread Doug Ledford
On 10/20/2015 10:50 AM, Matan Barak wrote: > > > On 10/19/2015 6:27 PM, Doug Ledford wrote: >> On 10/19/2015 10:20 AM, Matan Barak wrote: >>> On 10/19/2015 3:23 PM, Doug Ledford wrote: >> This is a major cause of the slowness. Unless you have a specific need of them, per-entry rwlocks

Re: 4.4's rdma plate

2015-10-20 Thread Doug Ledford
On 10/20/2015 12:25 PM, Or Gerlitz wrote: > On Wed, Oct 14, 2015 at 3:56 PM, Doug Ledford wrote: >> On 10/14/2015 12:51 AM, Or Gerlitz wrote: >>> On Sun, Oct 11, 2015 at 11:58 PM, Or Gerlitz wrote: Hi Doug, As we're soon on 4.3-rc5, could you

Re: [PATCH] IB/cma: Use inner P_Key to determine netdev

2015-10-20 Thread Jason Gunthorpe
On Tue, Oct 20, 2015 at 09:45:27AM +0300, Haggai Eran wrote: > On 19/10/2015 21:19, Jason Gunthorpe wrote: > > On Mon, Oct 19, 2015 at 09:09:25PM +0300, Haggai Eran wrote: > >> When discussing the patches to demux ids in rdma_cm instead of ib_cm, it > >> was decided that it is best to use the

Re: [PATCH rdma-RC] IB/cm: Fix sleeping while atomic when creating AH from WC

2015-10-20 Thread Jason Gunthorpe
On Tue, Oct 20, 2015 at 03:57:54PM +, Hefty, Sean wrote: > > Today, cm assumes paths are reversible primary_path->reversible = 1. > > I can't quickly find a link, but I believe all CM MADs are > reversible, per the spec. But the Linux CM code doesn't always create the reverse CM MAD from the

Re: 4.4's rdma plate

2015-10-20 Thread Or Gerlitz
On Tue, Oct 20, 2015 at 7:52 PM, Jason Gunthorpe wrote: > On Tue, Oct 20, 2015 at 07:42:25PM +0300, Or Gerlitz wrote: >> As for the RoCE patches, you mentioned reviewing them, this is going to >> take time, which makes sense. However, the self-multicast loopback prevention >> patches are > > My

Re: [PATCH rdma-RC] IB/cm: Fix rb-tree duplicate free and use-after-free

2015-10-20 Thread Doug Ledford
On 10/15/2015 11:15 AM, Matan Barak wrote: > > > On 10/12/2015 7:37 PM, Hefty, Sean wrote: >>> ib_send_cm_sidr_rep could sometimes erase the node from the sidr >>> (depending on errors in the process). Since ib_send_cm_sidr_rep is >>> called both from cm_sidr_req_handler and cm_destroy_id,

Re: [PATCH v1] IB/cma: Use inner P_Key to determine netdev

2015-10-20 Thread Doug Ledford
On 10/20/2015 04:35 AM, Haggai Eran wrote: > On 20/10/2015 10:20, Doug Ledford wrote: >> On 10/20/2015 02:53 AM, Haggai Eran wrote: >>> When discussing the patches to demux ids in rdma_cm instead of ib_cm, it >>> was decided that it is best to use the P_Key value in the packet headers. >>>

Re: [PATCH rdma-cm] IB/core: Fix use after free of ifa

2015-10-20 Thread Doug Ledford
On 10/15/2015 08:01 AM, Matan Barak wrote: > When using ifup/ifdown while executing enum_netdev_ipv4_ips, > ifa could become invalid and cause use after free error. > Fixing it by protecting with RCU lock. > > Fixes: 03db3a2d81e6 ('IB/core: Add RoCE GID table management') > Signed-off-by: Matan

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Sagi Grimberg
On 10/20/2015 5:08 PM, Or Gerlitz wrote: On Tue, Oct 20, 2015 at 4:08 PM, Sagi Grimberg wrote: I think this is very useful to have and I'd love having it in 4.4, does anyone have any other comments on this patch? Were we ever presented with performance gains

Re: 4.4's rdma plate

2015-10-20 Thread Jason Gunthorpe
On Wed, Oct 21, 2015 at 12:00:54AM +0300, Or Gerlitz wrote: > As I wrote below, we should encourage people to take part in upstream > development, and making such comment only after the patch sits on the > list whole two months (V1 was very minor change, V2 was re-spin) isn't > going in the

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Sagi Grimberg
I think this is very useful to have and I'd love having it in 4.4, does anyone have any other comments on this patch? Were we ever presented with performance gains achieved using the patch? Hi Or, Can you explain what you mean by performance gains? My understanding is that this patch is

Re: merge struct ib_device_attr into struct ib_device V2

2015-10-20 Thread Christoph Hellwig
On Tue, Oct 20, 2015 at 04:08:54PM +0300, Sagi Grimberg wrote: > Can you explain what you mean by performance gains? My understanding is > that this patch is not performance critical. It just replaces each and > every ULP device attributes caching. Exactly. The only 'performance' we care about