]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit - drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
net/mlx5e: Uninstantiate esw manager vport netdev on switchdev mode
authorOr Gerlitz <ogerlitz@mellanox.com>
Wed, 7 Nov 2018 14:34:52 +0000 (16:34 +0200)
committerSaeed Mahameed <saeedm@mellanox.com>
Mon, 17 Dec 2018 19:03:27 +0000 (11:03 -0800)
commitaec002f6f82cbfb39f92605614a88dd7a200a766
tree90343cc5c6e919693df6ad397902c96989253dad
parent13e509a4c1949855ddd5ef2e23bafdfb27b8337a
net/mlx5e: Uninstantiate esw manager vport netdev on switchdev mode

Now, when we have a dedicated uplink representor, the netdev instance
set over the esw manager vport (PF) is of no-use. As such, remove it
once we're on switchdev mode and get it back to life when off switchdev.

This is done by reloading the Ethernet interface as well (we already
do that for the IB interface) from the eswitch code while going in/out
of switchdev mode.

The Eth add/remove entries are modified to act differently when called in
switchdev mode. In this case we only deal with registration of the eth
vport representors. The rep netdevices are created from the eswitch call
to load the registered eth representors.

Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_main.c
drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
drivers/net/ethernet/mellanox/mlx5/core/en_rep.h
drivers/net/ethernet/mellanox/mlx5/core/eswitch.c