]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum: Distinguish between unsplittable and split port
authorJiri Pirko <jiri@mellanox.com>
Thu, 31 Oct 2019 09:42:10 +0000 (11:42 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 31 Oct 2019 17:54:47 +0000 (10:54 -0700)
commit17d28c0d840ea08679a3f25e9a7af637feffb08c
tree42e2fb04323116907ff4359dfa6d6ac66e35b737
parenta8cc46ca27631ee5f80187541de20cb0d76bb70a
mlxsw: spectrum: Distinguish between unsplittable and split port

Currently when user does split, he is not able to distinguish if the
port cannot be split because it is already split, or because it cannot
be split at all. Add another check for split flag to distinguish this.
Also add check forbidding split when maximal width is 1.

Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Reviewed-by: Shalom Toledo <shalomt@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum.c