net/mlx5e: Lag, Only handle events from highest priority multipath entry
authorRoi Dayan <roid@nvidia.com>
Wed, 16 Feb 2022 11:56:57 +0000 (13:56 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 16 Mar 2022 13:23:39 +0000 (14:23 +0100)
commita2355333cf186853b201ccb9101a8ee6a8552c82
treec6161c46031f0cfde7fc8d90bd4b18cfb3a4f300
parent7c519f769f555ff7d9d4ccba3497bbb589df360a
net/mlx5e: Lag, Only handle events from highest priority multipath entry

[ Upstream commit ad11c4f1d8fd1f03639460e425a36f7fd0ea83f5 ]

There could be multiple multipath entries but changing the port affinity
for each one doesn't make much sense and there should be a default one.
So only track the entry with lowest priority value.
The commit doesn't affect existing users with a single entry.

Fixes: 544fe7c2e654 ("net/mlx5e: Activate HW multipath and handle port affinity based on FIB events")
Signed-off-by: Roi Dayan <roid@nvidia.com>
Reviewed-by: Maor Dickman <maord@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/lag_mp.c