net/mlx4_en: Expose port number through sysfs
Initialize dev_port with port number (0 based) to be accessed through sysfs from user space. Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
3f85944fe2
commit
76a066f2a2
|
@ -2342,6 +2342,7 @@ int mlx4_en_init_netdev(struct mlx4_en_dev *mdev, int port,
|
|||
|
||||
SET_NETDEV_DEV(dev, &mdev->dev->pdev->dev);
|
||||
dev->dev_id = port - 1;
|
||||
dev->dev_port = port - 1;
|
||||
|
||||
/*
|
||||
* Initialize driver private data
|
||||
|
|
Loading…
Reference in New Issue