]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_router: Move multipath hash configuration to a bitmap
authorIdo Schimmel <idosch@nvidia.com>
Wed, 19 May 2021 12:08:20 +0000 (15:08 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 19 May 2021 19:47:47 +0000 (12:47 -0700)
commit644cda814001b62dc25dd7e24ebe91e4a4a3563a
tree3f5aa52cfe9d855f80994f0667fa2b2e4bf75d00
parent365c9184bd3de5779fce49756d8b5f88dd565395
mlxsw: spectrum_router: Move multipath hash configuration to a bitmap

Currently, the multipath hash configuration is written directly to the
register payload. While this is OK for the two currently supported
policies, it is going to be hard to follow when more policies and more
packet fields are added.

Instead, set the required headers and fields in a bitmap and then dump
it to the register payload.

Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Petr Machata <petrm@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/reg.h
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c