On Sun, Apr 28, 2019 at 12:14:42PM +0300, Kamal Heib wrote: > > > On 4/28/19 10:34 AM, Leon Romanovsky wrote: > > On Sun, Apr 28, 2019 at 06:28:55AM +0000, Michal Kalderon wrote: > >>> From: Kamal Heib <kamalheib1@xxxxxxxxx> > >>> Sent: Saturday, April 27, 2019 12:39 PM > >>> > >>> External Email > >>> > >>> ---------------------------------------------------------------------- > >>> Integrate iw_cm_verbs data members into ib_device_ops and ib_device > >>> structs, this is don to achieve the following: > >>> > >>> 1- Avoid memory related bugs. > >>> 2- Make the code more cleaner. > >>> 3- Reduce code duplication. > >>> > >>> Signed-off-by: Kamal Heib <kamalheib1@xxxxxxxxx> > >>> --- > >>> drivers/infiniband/core/device.c | 8 +++++ > >>> drivers/infiniband/core/iwcm.c | 34 ++++++++++----------- > >>> drivers/infiniband/hw/cxgb3/iwch_provider.c | 32 +++++++------------ > >>> drivers/infiniband/hw/cxgb4/provider.c | 33 ++++++++------------ > >>> drivers/infiniband/hw/i40iw/i40iw_verbs.c | 30 ++++++------------ > >>> drivers/infiniband/hw/nes/nes_verbs.c | 27 ++++++---------- > >>> drivers/infiniband/hw/qedr/main.c | 25 ++++++--------- > >>> include/rdma/ib_verbs.h | 22 ++++++++++--- > >>> include/rdma/iw_cm.h | 25 --------------- > >>> 9 files changed, 96 insertions(+), 140 deletions(-) > >>> > >>> diff --git a/drivers/infiniband/core/device.c > >>> b/drivers/infiniband/core/device.c > >>> index fcbf2d4c865d..b47ba4863eed 100644 > >>> --- a/drivers/infiniband/core/device.c > >>> +++ b/drivers/infiniband/core/device.c > >>> @@ -2345,6 +2345,14 @@ void ib_set_device_ops(struct ib_device *dev, > >>> const struct ib_device_ops *ops) > >>> SET_DEVICE_OP(dev_ops, set_vf_guid); > >>> SET_DEVICE_OP(dev_ops, set_vf_link_state); > >>> SET_DEVICE_OP(dev_ops, unmap_fmr); > >>> + SET_DEVICE_OP(dev_ops, add_ref); > >>> + SET_DEVICE_OP(dev_ops, rem_ref); > >>> + SET_DEVICE_OP(dev_ops, get_qp); > >>> + SET_DEVICE_OP(dev_ops, connect); > >>> + SET_DEVICE_OP(dev_ops, accept); > >>> + SET_DEVICE_OP(dev_ops, reject); > >>> + SET_DEVICE_OP(dev_ops, create_listen); > >>> + SET_DEVICE_OP(dev_ops, destroy_listen); > >> Perhaps there's added value in differentiating these ops as iWARP? Perhaps a prefix will suffice ? but at the least I guess a comment ? > >> When they were in iw_cm it was very clear. > > > > Completely agree with request to add some prefix. > > > > Thanks > > > > OK, I'll send a V2 with iw_cm_{*} prefix. iw_* for all iWARP specific calls will be enough. Thanks > > Thanks, > Kamal