]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_router: Add nexthop bucket replacement support
authorIdo Schimmel <idosch@nvidia.com>
Wed, 24 Mar 2021 20:14:18 +0000 (22:14 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Mar 2021 23:34:57 +0000 (16:34 -0700)
commit73c9850adeb5fb7256921e17a444d9a8fa22b1b1
treee03252b0827166da22fe6b837433fcec93560a97
parent061c442b500315d196604af906240eed514e8040
mlxsw: spectrum_router: Add nexthop bucket replacement support

Replace a single nexthop bucket upon receiving a
'NEXTHOP_EVENT_BUCKET_REPLACE' notification.

When the 'force' parameter is not set, instruct the device to only
overwrite an adjacency entry if its activity is cleared, so as not to
break existing flows using the adjacency entry. The device does not
provide feedback if the replacement was successful in this case, so the
contents of the adjacency entry after the replacement are compared with
the replacement request.

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/spectrum_router.c