mlxsw: spectrum_router: mlxsw_sp_router_fini(): Extract a helper variable
authorPetr Machata <petrm@nvidia.com>
Fri, 9 Jun 2023 17:32:06 +0000 (19:32 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 12 Jun 2023 08:49:29 +0000 (09:49 +0100)
commit50f6c3d57e9a7d11ff935198c1d55d37975c2fa4
treef0d214cba946b9dac7a456db997b45722c7cbf8b
parente069ba07e6c7af69e119316bc87ff44869095f49
mlxsw: spectrum_router: mlxsw_sp_router_fini(): Extract a helper variable

Make mlxsw_sp_router_fini() more similar to the _init() function (and more
concise) by extracting the `router' handle to a named variable and using
that throughout. The availability of a dedicated `router' variable will
come in handy in following patches.

Signed-off-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Amit Cohen <amcohen@nvidia.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c