]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_router: Use nexthop group type in hash table key
authorIdo Schimmel <idosch@nvidia.com>
Fri, 13 Nov 2020 16:05:47 +0000 (18:05 +0200)
committerJakub Kicinski <kuba@kernel.org>
Sun, 15 Nov 2020 00:55:03 +0000 (16:55 -0800)
commitdaad058372845f681f1e04251c04e38f50a10c20
tree04015492b9451774b9f8427ac319a0c884310984
parent37fdddecbf6cc015a27cf9ad6cdae02e8d2ce18a
mlxsw: spectrum_router: Use nexthop group type in hash table key

Both IPv4 and IPv6 nexthop groups are hashed in the same table. The
protocol field is used to indicate how the hash should be computed for
each group.

When nexthop group objects are supported, the hash will be computed for
them based on the nexthop identifier.

To differentiate between all the nexthop group types, encode the type of
the group in the key instead of the protocol.

Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c