IB/IPoIB: Separate control from HW operation on ipoib_open/stop ndo
authorErez Shitrit <erezsh@mellanox.com>
Mon, 10 Apr 2017 08:22:27 +0000 (11:22 +0300)
committerDoug Ledford <dledford@redhat.com>
Thu, 20 Apr 2017 19:19:43 +0000 (15:19 -0400)
commit7ce1a3ee02642a9677662d0786732027ff729cda
tree6c7f854de90306fc356cc983ee180fc32799a925
parent515ed4f3aab4e8a0855d0cdfd9753a419ccfb297
IB/IPoIB: Separate control from HW operation on ipoib_open/stop ndo

This patch is preparing the netdev part at the IPoIB driver to be able
to use the ipoib_options.

It deals with the two flows from the .ndo: ipoib_open and ipoib_stop.

The code is rearranged as follows:
 * All operations which deal with the hardware resources, (for example
   change QP state, post-receive etc.) are performed in one place.
 * All operations that are control oriented (like restart multicast task,
   start the reap_ah etc.) are performed in separate place.

The functions that deal with the hardware resources now located at
__ipoib_ib_dev_open for the ipoib_open flow and __ipoib_ib_dev_stop
for ipoib_stop.

Signed-off-by: Erez Shitrit <erezsh@mellanox.com>
Reviewed-by: Alex Vesker <valex@mellanox.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/ulp/ipoib/ipoib.h
drivers/infiniband/ulp/ipoib/ipoib_ib.c
drivers/infiniband/ulp/ipoib/ipoib_main.c