]> git.karo-electronics.de Git - linux-beck.git/commit
mlxsw: Make devlink port instances independent of spectrum/switchx2 port instances
authorJiri Pirko <jiri@mellanox.com>
Fri, 28 Oct 2016 19:35:55 +0000 (21:35 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sun, 30 Oct 2016 20:50:17 +0000 (16:50 -0400)
commit67963a33b4fde8f77b046f80daf83afc6e126991
treecfc60a14421cde82d9081dff8a1ec6d1f1899383
parent7136793e4a44651b273a457e31f00a51751dd123
mlxsw: Make devlink port instances independent of spectrum/switchx2 port instances

Currently, devlink register/unregister is done directly from
spectrum/switchx2 port create/remove functions. With a need to
introduce a port type change, the devlink port instances have to be
persistent across type changes, therefore across port create/remove
function calls. So do a bit of reshuffling to achieve that.

Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Elad Raz <eladr@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/core.c
drivers/net/ethernet/mellanox/mlxsw/core.h
drivers/net/ethernet/mellanox/mlxsw/spectrum.c
drivers/net/ethernet/mellanox/mlxsw/spectrum.h
drivers/net/ethernet/mellanox/mlxsw/switchx2.c