Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-16 Thread Jason Gunthorpe
On Thu, Mar 16, 2017 at 05:17:55PM +0200, Erez Shitrit wrote: > The QP as a part of the HW resources, it is created in the low-level > driver, and used by the upper ipoib for few reasons, (for example the > mac of the ipoib interface includes from the qp_num) > Now, if we want to use the ndo's in

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-16 Thread Erez Shitrit
On Mon, Mar 13, 2017 at 10:01 PM, Jason Gunthorpe wrote: > On Mon, Mar 13, 2017 at 08:31:15PM +0200, Erez Shitrit wrote: > >> diff --git a/include/rdma/ib_ipoib_accel_ops.h >> b/include/rdma/ib_ipoib_accel_ops.h >> new file mode 100644 >> index ..148a5529a559 >> +++ b/include/rdma/ib_

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-15 Thread Vishwanathapura, Niranjana
On Wed, Mar 15, 2017 at 08:30:43AM +0200, Leon Romanovsky wrote: On Tue, Mar 14, 2017 at 10:11:49AM -0600, Jason Gunthorpe wrote: On Tue, Mar 14, 2017 at 12:01:09AM -0700, Vishwanathapura, Niranjana wrote: > On Mon, Mar 13, 2017 at 02:01:36PM -0600, Jason Gunthorpe wrote: > >>+ /* multicast */

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-14 Thread Leon Romanovsky
On Tue, Mar 14, 2017 at 10:11:49AM -0600, Jason Gunthorpe wrote: > On Tue, Mar 14, 2017 at 12:01:09AM -0700, Vishwanathapura, Niranjana wrote: > > On Mon, Mar 13, 2017 at 02:01:36PM -0600, Jason Gunthorpe wrote: > > >>+ /* multicast */ > > >>+ int (*attach_mcast)(struct net_device *dev, struct ib_d

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-14 Thread Jason Gunthorpe
On Tue, Mar 14, 2017 at 12:01:09AM -0700, Vishwanathapura, Niranjana wrote: > On Mon, Mar 13, 2017 at 02:01:36PM -0600, Jason Gunthorpe wrote: > >>+ /* multicast */ > >>+ int (*attach_mcast)(struct net_device *dev, struct ib_device *hca, > >>+ union ib_gid *gid, u16 lid, i

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-14 Thread Erez Shitrit
On Tue, Mar 14, 2017 at 9:01 AM, Vishwanathapura, Niranjana wrote: > On Mon, Mar 13, 2017 at 02:01:36PM -0600, Jason Gunthorpe wrote: >>> >>> + /* multicast */ >>> + int (*attach_mcast)(struct net_device *dev, struct ib_device >>> *hca, >>> + union ib_gid *gid

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-14 Thread Vishwanathapura, Niranjana
On Mon, Mar 13, 2017 at 02:01:36PM -0600, Jason Gunthorpe wrote: + /* multicast */ + int (*attach_mcast)(struct net_device *dev, struct ib_device *hca, + union ib_gid *gid, u16 lid, int set_qkey); + int (*detach_mcast)(struct net_device *dev, struct ib_

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-13 Thread Vishwanathapura, Niranjana
On Mon, Mar 13, 2017 at 08:31:15PM +0200, Erez Shitrit wrote: +struct ipoib_rdma_netdev { + struct rdma_netdev rn; /* keep this first */ + /* followed by device private data */ + char *dev_priv[0]; +}; + +static inline void *ipoib_priv(const struct net_device *dev) +{ + s

Re: [RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-13 Thread Jason Gunthorpe
On Mon, Mar 13, 2017 at 08:31:15PM +0200, Erez Shitrit wrote: > diff --git a/include/rdma/ib_ipoib_accel_ops.h > b/include/rdma/ib_ipoib_accel_ops.h > new file mode 100644 > index ..148a5529a559 > +++ b/include/rdma/ib_ipoib_accel_ops.h Both patches need a better naming scheme for th

[RFC v1 for accelerated IPoIB 04/25] IB/verb: Add ipoib_options struct and API

2017-03-13 Thread Erez Shitrit
The idea is to allow vendors to optimize IPoIB data path. New struct that includes functions and data member is exposed. It exposes set of callback functions for handling data path flows in IPoIB driver. Each vendor can support these set of functions in order to optimize its specific data path, a