Skip to content

Commit

Permalink
RDMA/ipoib: implement ethtool .get_link() callback
Browse files Browse the repository at this point in the history
Add support for reporting link state for ipoib net devices.

$ ip l set dev mlx4_ib0 up
$ ethtool mlx4_ib0 | grep Link
	Link detected: yes
$ ip l set dev mlx4_ib0 down
$ ethtool mlx4_ib0 | grep Link
	Link detected: no

Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
  • Loading branch information
Kamal Heib authored and Jason Gunthorpe committed Jun 7, 2019
1 parent 97545b1 commit 633fbb0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/infiniband/ulp/ipoib/ipoib_ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@ static const struct ethtool_ops ipoib_ethtool_ops = {
.get_strings = ipoib_get_strings,
.get_ethtool_stats = ipoib_get_ethtool_stats,
.get_sset_count = ipoib_get_sset_count,
.get_link = ethtool_op_get_link,
};

void ipoib_set_ethtool_ops(struct net_device *dev)
Expand Down

0 comments on commit 633fbb0

Please sign in to comment.