]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_buffers: Remove assumption about pool order
authorIdo Schimmel <idosch@mellanox.com>
Mon, 22 Apr 2019 12:08:50 +0000 (12:08 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 23 Apr 2019 05:09:32 +0000 (22:09 -0700)
commit72ed2a0e6571230aac9327581b30cb18b1905a5e
treeff7f99281f33bca561c3ba4e604a05f3654fc71b
parentcf7c0cc16c5f1625eca560cdc7385643adf44a9b
mlxsw: spectrum_buffers: Remove assumption about pool order

The code currently assumes that ingress pools have lower indices than
egress pools. This makes it impossible to add more ingress pools
without breaking user configuration that relies on a certain pool index
to correspond to an egress pool.

Remove such assumptions from the code, so that more ingress pools could
be added by subsequent patches.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Petr Machata <petrm@mellanox.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_buffers.c