All of lore.kernel.org
 help / color / mirror / Atom feed
* RE: [PATCH 14/14] IB/mad: Add final OPA MAD processing
@ 2015-05-28 16:21 Liran Liss
  0 siblings, 0 replies; 26+ messages in thread
From: Liran Liss @ 2015-05-28 16:21 UTC (permalink / raw)
  To: linux-rdma-u79uwXL29TY76Z2rM5mHXA

> >
> > Why do you have RDMA_NODE_IB_SWITCH related stuff inside the
> handle_opa_smi() function?
> > Is there a node type of "switch" in OPA similar to IB?
> >
> 
> Yes.  OPA uses the same node types as IB.
> 
> Ira
> 

No, OPA cannot impersonate IB.
It has to have distinct node and link types.

--Liran

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

^ permalink raw reply	[flat|nested] 26+ messages in thread
* [PATCH 00/14] IB/mad: Add support for OPA MAD processing.
@ 2015-06-06 18:38 ira.weiny-ral2JQCrhuEAvxtiuMwx3w
       [not found] ` <1433615915-24591-1-git-send-email-ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 26+ messages in thread
From: ira.weiny-ral2JQCrhuEAvxtiuMwx3w @ 2015-06-06 18:38 UTC (permalink / raw)
  To: dledford-H+wXaHxf7aLQT0dZR+AlfA
  Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA, Ira Weiny

From: Ira Weiny <ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

The following patch series modifies the kernel MAD processing (ib_mad/ib_umad)
and related interfaces to send and receive Intel Omni-Path Architecture MADs on
devices which support them.

OPA MADs share the same common header with IBTA MADs which allows us to share
most of the MAD processing code.

In addition to supporting some IBTA management classes, OPA devices use MADs
with lengths up to 2K.  These MADs increase the performance of management
traffic on OPA fabrics.

Devices report their support of OPA MADs through the new immutable data
capability flag and immutable max mad size.

Changes from V1:
================

Remove patch:
	IB/mad: Create an RMPP Base header

Add new patch:
	IB/mad cleanup: Clean up function params -- find_mad_agent

Address comments from Jason about the idea of a flex array for struct ib_mad:
	ib_mad does not really allocate struct ib_mads.  Rather it allocates
	ib_mad_private objects.  This is where the flex array was more
	appropriate.  So this series changes struct ib_mad_private to end in a
	flex array to store MAD data.  Casts are used where appropriate to
	IB/OPA mad structures or headers.

Minor updates:
	Clean up commit messages
	Fix/add const and bool usage
	Remove inline qualifiers (let complier handle inline)
	Add additional Immutable data checks
	Change WARN_ON to BUG_ON in drivers
	Add out_mad_pkey_index to process_mad in order to maintain the
	"constness" of the struct ib_wc parameter.


Ira Weiny (14):
  IB/mad cleanup: Clean up function params -- find_mad_agent
  IB/mad cleanup: Generalize processing of MAD data
  IB/mad: Split IB SMI handling from MAD Recv handler
  IB/mad: Create a generic helper for DR SMP Send processing
  IB/mad: Create a generic helper for DR SMP Recv processing
  IB/mad: Create a generic helper for DR forwarding checks
  IB/mad: Support alternate Base Versions when creating MADs
  IB/core: Add ability for drivers to report an alternate MAD size.
  IB/mad: Convert allocations from kmem_cache to kzalloc
  IB/mad: Add support for additional MAD info to/from drivers
  IB/core: Add OPA MAD core capability flag
  IB/mad: Add partial Intel OPA MAD support
  IB/mad: Add partial Intel OPA MAD support
  IB/mad: Add final OPA MAD processing

 drivers/infiniband/core/agent.c              |  15 +-
 drivers/infiniband/core/agent.h              |   4 +-
 drivers/infiniband/core/cm.c                 |   6 +-
 drivers/infiniband/core/device.c             |  11 +
 drivers/infiniband/core/mad.c                | 541 +++++++++++++++++++--------
 drivers/infiniband/core/mad_priv.h           |  11 +-
 drivers/infiniband/core/mad_rmpp.c           |  33 +-
 drivers/infiniband/core/opa_smi.h            |  78 ++++
 drivers/infiniband/core/sa_query.c           |   3 +-
 drivers/infiniband/core/smi.c                | 228 +++++++----
 drivers/infiniband/core/sysfs.c              |   7 +-
 drivers/infiniband/core/user_mad.c           |  20 +-
 drivers/infiniband/hw/amso1100/c2_provider.c |   6 +-
 drivers/infiniband/hw/cxgb3/iwch_provider.c  |   6 +-
 drivers/infiniband/hw/cxgb4/provider.c       |   7 +-
 drivers/infiniband/hw/ehca/ehca_iverbs.h     |   5 +-
 drivers/infiniband/hw/ehca/ehca_main.c       |   2 +
 drivers/infiniband/hw/ehca/ehca_sqp.c        |   9 +-
 drivers/infiniband/hw/ipath/ipath_mad.c      |   9 +-
 drivers/infiniband/hw/ipath/ipath_verbs.c    |   1 +
 drivers/infiniband/hw/ipath/ipath_verbs.h    |   4 +-
 drivers/infiniband/hw/mlx4/mad.c             |  13 +-
 drivers/infiniband/hw/mlx4/main.c            |   2 +
 drivers/infiniband/hw/mlx4/mlx4_ib.h         |   4 +-
 drivers/infiniband/hw/mlx5/mad.c             |   9 +-
 drivers/infiniband/hw/mlx5/main.c            |   1 +
 drivers/infiniband/hw/mlx5/mlx5_ib.h         |   4 +-
 drivers/infiniband/hw/mthca/mthca_dev.h      |   5 +-
 drivers/infiniband/hw/mthca/mthca_mad.c      |  13 +-
 drivers/infiniband/hw/mthca/mthca_provider.c |   1 +
 drivers/infiniband/hw/nes/nes_verbs.c        |   4 +-
 drivers/infiniband/hw/ocrdma/ocrdma_ah.c     |   9 +-
 drivers/infiniband/hw/ocrdma/ocrdma_ah.h     |   4 +-
 drivers/infiniband/hw/ocrdma/ocrdma_main.c   |   2 +
 drivers/infiniband/hw/qib/qib_iba7322.c      |   3 +-
 drivers/infiniband/hw/qib/qib_mad.c          |  12 +-
 drivers/infiniband/hw/qib/qib_verbs.c        |   1 +
 drivers/infiniband/hw/qib/qib_verbs.h        |   4 +-
 drivers/infiniband/ulp/srpt/ib_srpt.c        |   3 +-
 include/rdma/ib_mad.h                        |  37 +-
 include/rdma/ib_verbs.h                      |  55 ++-
 include/rdma/opa_smi.h                       | 106 ++++++
 42 files changed, 997 insertions(+), 301 deletions(-)
 create mode 100644 drivers/infiniband/core/opa_smi.h
 create mode 100644 include/rdma/opa_smi.h

-- 
1.8.2

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

^ permalink raw reply	[flat|nested] 26+ messages in thread
* [PATCH 00/14] IB/mad: Add support for OPA MAD processing.
@ 2015-05-20  8:13 ira.weiny-ral2JQCrhuEAvxtiuMwx3w
       [not found] ` <1432109615-19564-1-git-send-email-ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 26+ messages in thread
From: ira.weiny-ral2JQCrhuEAvxtiuMwx3w @ 2015-05-20  8:13 UTC (permalink / raw)
  To: dledford-H+wXaHxf7aLQT0dZR+AlfA
  Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA,
	sean.hefty-ral2JQCrhuEAvxtiuMwx3w,
	jgunthorpe-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/,
	hal-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb, Ira Weiny

From: Ira Weiny <ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

The following patch series modifies the kernel MAD processing (ib_mad/ib_umad)
and related interfaces to send and receive Intel Omni-Path Architecture MADs on
devices which support them.

OPA MADs share the same common header with IBTA MADs which allows us to share
most of the MAD processing code.

In addition to supporting some IBTA management classes, OPA devices use MADs
with lengths up to 2K.  These MADs increase the performance of management
traffic on OPA fabrics.

Devices report their support of OPA MADs through the new immutable data
capability flag.

I am submitting this as a set of smaller patches which should be easier to
review individually but with the exception of the first patch they should be
accepted as a series.  I recognize that many of the patches could be squashed
when considering functionality only but I don't think that is easiest way to
review them.

The patch series is broken up as follows:

1 patch
  IB/mad: Clean up ib_find_send_mad

	Generalize ib_find_send_mad for both OPA and IB devices

6 patches
  IB/mad: Create an RMPP Base header
  IB/mad: Create handle_ib_smi
  IB/mad: Add helper function for smi_handle_dr_smp_send
  IB/mad: Add helper function for smi_handle_dr_smp_recv
  IB/mad: Add helper function for smi_check_forward_dr_smp
  IB/mad: Add base version to ib_create_send_mad

	Modify existing MAD code in anticipation for that code to handle both
	OPA and IB MADs but retain only the IB functionality within the patches
	themselves.


3 patches
  IB/core: Add rdma_max_mad_size helper
  IB/mad: Convert allocations from kmem_cache to kmalloc
  IB/mad: Add MAD size parameters to process_mad

	Add max MAD size to the device immutable data and convert the MAD code
	to use that value rather than the previous hard coded MAD size of 256
	bytes.  Once again these patches retain the IB functionality but do so
	by specifying a new define for their MAX MAD size.

4 patches
  IB/core: Add rdma_cap_opa_mad helper
  IB/mad: Add partial Intel OPA MAD support
  IB/mad: Add partial Intel OPA MAD support
  IB/mad: Add final OPA MAD processing

	Implement an OPA device immutable core capability flag and use it to
	process OPA MADs as appropriate.  Once again this is split up to make
	reviewing the patches easier.


Due to the large structural change of these patches vs previous submissions I
am submitting these as a new series.

The following general comments were addressed from the last "version".

Rebased to latest Dougs for-4.2 branch
	Update based on Michaels rdma_cap_* helpers and related core capability
	work.

Address Comments by Doug Ledford
	Change device MAD size error message to a WARN_ON
	Add gfp_t flags to alloc_mad_priv and pass the correct flags depending
	on the allocation site.

Address Comments by Sean Hefty
	Change alloc_mad_priv to take mad_size
	Change individual device mad size checks in process_mad to be
	WARN_ON
	create new patch which defines an ib_rmpp_hdr struct to be
	shared between IB and OPA mad defines.
	Change "jumbo" to "opa" and remove jumbo from all related
	documentation/commit messages
	Fix up comments for smi functions
	Remove cached_dev_attr patch and replace with the new immutable data



Ira Weiny (14):
  IB/mad: Clean up ib_find_send_mad
  IB/mad: Create an RMPP Base header
  IB/mad: Create handle_ib_smi
  IB/mad: Add helper function for smi_handle_dr_smp_send
  IB/mad: Add helper function for smi_handle_dr_smp_recv
  IB/mad: Add helper function for smi_check_forward_dr_smp
  IB/mad: Add base version to ib_create_send_mad
  IB/core: Add rdma_max_mad_size helper
  IB/mad: Convert allocations from kmem_cache to kmalloc
  IB/mad: Add MAD size parameters to process_mad
  IB/core: Add rdma_cap_opa_mad helper
  IB/mad: Add partial Intel OPA MAD support
  IB/mad: Add partial Intel OPA MAD support
  IB/mad: Add final OPA MAD processing

 drivers/infiniband/core/agent.c              |  22 +-
 drivers/infiniband/core/agent.h              |   3 +-
 drivers/infiniband/core/cm.c                 |   6 +-
 drivers/infiniband/core/mad.c                | 469 +++++++++++++++++++--------
 drivers/infiniband/core/mad_priv.h           |   7 +-
 drivers/infiniband/core/mad_rmpp.c           | 148 +++++----
 drivers/infiniband/core/opa_smi.h            |  78 +++++
 drivers/infiniband/core/sa_query.c           |   3 +-
 drivers/infiniband/core/smi.c                | 231 +++++++++----
 drivers/infiniband/core/sysfs.c              |   5 +-
 drivers/infiniband/core/user_mad.c           |  36 +-
 drivers/infiniband/hw/amso1100/c2_provider.c |   5 +-
 drivers/infiniband/hw/cxgb3/iwch_provider.c  |   5 +-
 drivers/infiniband/hw/cxgb4/provider.c       |   7 +-
 drivers/infiniband/hw/ehca/ehca_iverbs.h     |   4 +-
 drivers/infiniband/hw/ehca/ehca_main.c       |   2 +
 drivers/infiniband/hw/ehca/ehca_sqp.c        |   9 +-
 drivers/infiniband/hw/ipath/ipath_mad.c      |   9 +-
 drivers/infiniband/hw/ipath/ipath_verbs.c    |   1 +
 drivers/infiniband/hw/ipath/ipath_verbs.h    |   3 +-
 drivers/infiniband/hw/mlx4/mad.c             |  13 +-
 drivers/infiniband/hw/mlx4/main.c            |   2 +
 drivers/infiniband/hw/mlx4/mlx4_ib.h         |   3 +-
 drivers/infiniband/hw/mlx5/mad.c             |   9 +-
 drivers/infiniband/hw/mlx5/main.c            |   1 +
 drivers/infiniband/hw/mlx5/mlx5_ib.h         |   3 +-
 drivers/infiniband/hw/mthca/mthca_dev.h      |   4 +-
 drivers/infiniband/hw/mthca/mthca_mad.c      |  13 +-
 drivers/infiniband/hw/mthca/mthca_provider.c |   1 +
 drivers/infiniband/hw/nes/nes_verbs.c        |   3 +-
 drivers/infiniband/hw/ocrdma/ocrdma_ah.c     |   9 +-
 drivers/infiniband/hw/ocrdma/ocrdma_ah.h     |   3 +-
 drivers/infiniband/hw/ocrdma/ocrdma_main.c   |   2 +
 drivers/infiniband/hw/ocrdma/ocrdma_stats.h  |   1 +
 drivers/infiniband/hw/qib/qib_iba7322.c      |   3 +-
 drivers/infiniband/hw/qib/qib_mad.c          |  12 +-
 drivers/infiniband/hw/qib/qib_verbs.c        |   1 +
 drivers/infiniband/hw/qib/qib_verbs.h        |   3 +-
 drivers/infiniband/ulp/srpt/ib_srpt.c        |   3 +-
 include/rdma/ib_mad.h                        |  36 +-
 include/rdma/ib_verbs.h                      |  44 ++-
 include/rdma/opa_smi.h                       | 106 ++++++
 42 files changed, 994 insertions(+), 334 deletions(-)
 create mode 100644 drivers/infiniband/core/opa_smi.h
 create mode 100644 include/rdma/opa_smi.h

-- 
1.8.2

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

^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2015-06-19 11:53 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-28 16:21 [PATCH 14/14] IB/mad: Add final OPA MAD processing Liran Liss
  -- strict thread matches above, loose matches on Subject: below --
2015-06-06 18:38 [PATCH 00/14] IB/mad: Add support for " ira.weiny-ral2JQCrhuEAvxtiuMwx3w
     [not found] ` <1433615915-24591-1-git-send-email-ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-06-06 18:38   ` [PATCH 14/14] IB/mad: Add final " ira.weiny-ral2JQCrhuEAvxtiuMwx3w
     [not found]     ` <1433615915-24591-15-git-send-email-ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-06-10  6:30       ` Liran Liss
     [not found]         ` <HE1PR05MB1418BB6C461790B76D9C02A3B1BD0-eBadYZ65MZ87O8BmmlM1zNqRiQSDpxhJvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2015-06-10 17:54           ` ira.weiny
2015-06-10 18:37           ` Doug Ledford
     [not found]             ` <1433961446.71666.26.camel-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2015-06-10 18:56               ` Jason Gunthorpe
     [not found]                 ` <20150610185653.GA28153-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2015-06-10 19:59                   ` Doug Ledford
     [not found]                     ` <1433966378.71666.44.camel-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2015-06-11 18:27                       ` Liran Liss
     [not found]                         ` <HE1PR05MB141885494D6967919DAE135EB1BC0-eBadYZ65MZ87O8BmmlM1zNqRiQSDpxhJvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2015-06-12 14:23                           ` Doug Ledford
     [not found]                             ` <557AEB5D.1040003-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2015-06-14 19:16                               ` Liran Liss
     [not found]                                 ` <HE1PR05MB14182DCD7003B52A28BB62A5B1B90-eBadYZ65MZ87O8BmmlM1zNqRiQSDpxhJvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2015-06-15  5:39                                   ` Doug Ledford
     [not found]                                     ` <557E6514.1060600-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2015-06-16 21:05                                       ` Liran Liss
     [not found]                                         ` <HE1PR05MB1418C8F8E54FCC790B0CCAE3B1A70-eBadYZ65MZ87O8BmmlM1zNqRiQSDpxhJvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2015-06-17 14:03                                           ` Weiny, Ira
     [not found]                                             ` <2807E5FD2F6FDA4886F6618EAC48510E1109EA02-8k97q/ur5Z2krb+BlOpmy7fspsVTdybXVpNB7YpNyf8@public.gmane.org>
2015-06-18 20:12                                               ` Liran Liss
2015-06-18 21:00                                           ` Doug Ledford
     [not found]                                             ` <953CDD5A-2738-4427-B763-EBFB4BBB2E03-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2015-06-19 11:53                                               ` Hal Rosenstock
2015-06-16 22:12                                       ` Hefty, Sean
2015-06-11 21:00                       ` Hefty, Sean
     [not found]                         ` <1828884A29C6694DAF28B7E6B8A82373A8FEF1EA-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2015-06-11 23:24                           ` Hal Rosenstock
     [not found]                             ` <557A18C0.6010200-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
2015-06-11 23:52                               ` Hefty, Sean
     [not found]                                 ` <1828884A29C6694DAF28B7E6B8A82373A8FEF321-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2015-06-12  0:22                                   ` Hal Rosenstock
2015-05-20  8:13 [PATCH 00/14] IB/mad: Add support for " ira.weiny-ral2JQCrhuEAvxtiuMwx3w
     [not found] ` <1432109615-19564-1-git-send-email-ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-05-20  8:13   ` [PATCH 14/14] IB/mad: Add final " ira.weiny-ral2JQCrhuEAvxtiuMwx3w
     [not found]     ` <1432109615-19564-15-git-send-email-ira.weiny-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-05-20 18:59       ` Jason Gunthorpe
     [not found]         ` <20150520185901.GK28496-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2015-05-21 16:23           ` ira.weiny
2015-05-20 21:11       ` Suri Shelvapille
     [not found]         ` <CY1PR03MB1440B98A7FE0A82E1BE53D75DEC20-DUcFgbLRNhB/HYnSB+xpdWP7xZHs9kq/vxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2015-05-20 21:26           ` ira.weiny

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.