提交 76a066f2 编写于 作者: A Amir Vadai 提交者: David S. Miller

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: NAmir Vadai <amirv@mellanox.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 3f85944f
...@@ -2342,6 +2342,7 @@ int mlx4_en_init_netdev(struct mlx4_en_dev *mdev, int port, ...@@ -2342,6 +2342,7 @@ int mlx4_en_init_netdev(struct mlx4_en_dev *mdev, int port,
SET_NETDEV_DEV(dev, &mdev->dev->pdev->dev); SET_NETDEV_DEV(dev, &mdev->dev->pdev->dev);
dev->dev_id = port - 1; dev->dev_id = port - 1;
dev->dev_port = port - 1;
/* /*
* Initialize driver private data * Initialize driver private data
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册