IB/mlx5: Support IB device's callback for getting its netdev
authorAchiad Shochat <achiad@mellanox.com>
Wed, 23 Dec 2015 16:47:17 +0000 (18:47 +0200)
committerDoug Ledford <dledford@redhat.com>
Wed, 23 Dec 2015 17:07:36 +0000 (12:07 -0500)
commitfc24fc5e9530a4fde7feddaa543f5885af013461
tree2d9ef10b2697f4e40da6889ff87c848f6ccc820d
parentebd61f68e1c79eab022c550f95cb8bf37cc925cb
IB/mlx5: Support IB device's callback for getting its netdev

For Eth ports only:
Maintain a net device pointer in mlx5_ib_device and update it
upon NETDEV_REGISTER and NETDEV_UNREGISTER events if the
net-device and IB device have the same PCI parent device.
Implement the get_netdev callback to return this net device.

Signed-off-by: Achiad Shochat <achiad@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/mlx5/main.c
drivers/infiniband/hw/mlx5/mlx5_ib.h