OpenCloudOS-Kernel/drivers/net/ethernet/mellanox
Petr Machata 4b7a632ac4 mlxsw: spectrum_cnt: Reorder counter pools
Both RIF and ACL flow counters use a 24-bit SW-managed counter address to
communicate which counter they want to bind.

In a number of Spectrum FW releases, binding a RIF counter is broken and
slices the counter index to 16 bits. As a result, on Spectrum-2 and above,
no more than about 410 RIF counters can be effectively used. This
translates to 205 netdevices for which L3 HW stats can be enabled. (This
does not happen on Spectrum-1, because there are fewer counters available
overall and the counter index never exceeds 16 bits.)

Binding counters to ACLs does not have this issue. Therefore reorder the
counter allocation scheme so that RIF counters come first and therefore get
lower indices that are below the 16-bit barrier.

Fixes: 98e60dce4d ("Merge branch 'mlxsw-Introduce-initial-Spectrum-2-support'")
Reported-by: Maksym Yaremchuk <maksymy@nvidia.com>
Signed-off-by: Petr Machata <petrm@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Link: https://lore.kernel.org/r/20220613125017.2018162-1-idosch@nvidia.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
2022-06-14 16:00:37 +02:00
..
mlx4 Networking fixes for 5.19-rc2, including fixes from bpf and netfilter. 2022-06-09 12:06:52 -07:00
mlx5/core mlx5-fixes-2022-06-08 2022-06-09 22:05:37 -07:00
mlxbf_gige net/mlxbf_gige: use eth_zero_addr() to clear mac address 2022-05-17 11:23:58 +02:00
mlxfw devlink: Reduce struct devlink exposure 2021-10-12 16:29:16 -07:00
mlxsw mlxsw: spectrum_cnt: Reorder counter pools 2022-06-14 16:00:37 +02:00
Kconfig Add Mellanox BlueField Gigabit Ethernet driver 2021-06-25 11:20:23 -07:00
Makefile Add Mellanox BlueField Gigabit Ethernet driver 2021-06-25 11:20:23 -07:00