Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 76a066f2 authored by Amir Vadai's avatar Amir Vadai Committed by David S. Miller
Browse files

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: default avatarAmir Vadai <amirv@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 3f85944f
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -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