Message ID | 20201113160559.22148-1-idosch@idosch.org (mailing list archive) |
---|---|
Headers | show |
Series | mlxsw: Preparations for nexthop objects support - part 1/2 | expand |
On Fri, 13 Nov 2020 18:05:44 +0200 Ido Schimmel wrote: > From: Ido Schimmel <idosch@nvidia.com> > > This patch set contains small and non-functional changes aimed at making > it easier to support nexthop objects in mlxsw. Follow up patches can be > found here [1]. > > Patches #1-#4 add a type field to the nexthop group struct instead of > the existing protocol field. This will be used later on to add a nexthop > object type, which can contain both IPv4 and IPv6 nexthops. > > Patches #5-#7 move the IPv4 FIB info pointer (i.e., 'struct fib_info') > from the nexthop group struct to the route. The pointer will not be > available when the nexthop group is a nexthop object, but it needs to be > accessible to routes regardless. > > Patch #8 is the biggest change, but it is an entirely cosmetic change > and should therefore be easy to review. The motivation and the change > itself are explained in detail in the commit message. > > Patches #9-#12 perform small changes so that two functions that are > currently split between IPv4 and IPv6 could be consolidated in patches > #13 and #14. The functions will be reused for nexthop objects. > > Patch #15 removes an outdated comment. Pleasant read, applied, thanks!
From: Ido Schimmel <idosch@nvidia.com> This patch set contains small and non-functional changes aimed at making it easier to support nexthop objects in mlxsw. Follow up patches can be found here [1]. Patches #1-#4 add a type field to the nexthop group struct instead of the existing protocol field. This will be used later on to add a nexthop object type, which can contain both IPv4 and IPv6 nexthops. Patches #5-#7 move the IPv4 FIB info pointer (i.e., 'struct fib_info') from the nexthop group struct to the route. The pointer will not be available when the nexthop group is a nexthop object, but it needs to be accessible to routes regardless. Patch #8 is the biggest change, but it is an entirely cosmetic change and should therefore be easy to review. The motivation and the change itself are explained in detail in the commit message. Patches #9-#12 perform small changes so that two functions that are currently split between IPv4 and IPv6 could be consolidated in patches #13 and #14. The functions will be reused for nexthop objects. Patch #15 removes an outdated comment. [1] https://github.com/idosch/linux/tree/submit/nexthop_objects Ido Schimmel (15): mlxsw: spectrum_router: Compare key with correct object type mlxsw: spectrum_router: Add nexthop group type field mlxsw: spectrum_router: Use nexthop group type in hash table key mlxsw: spectrum_router: Associate neighbour table with nexthop instead of group mlxsw: spectrum_router: Store FIB info in route mlxsw: spectrum_router: Remove unused field 'prio' from IPv4 FIB entry struct mlxsw: spectrum_router: Move IPv4 FIB info into a union in nexthop group struct mlxsw: spectrum_router: Split nexthop group configuration to a different struct mlxsw: spectrum_ipip: Remove overlay protocol from can_offload() callback mlxsw: spectrum_router: Pass nexthop netdev to mlxsw_sp_nexthop6_type_init() mlxsw: spectrum_router: Pass nexthop netdev to mlxsw_sp_nexthop4_type_init() mlxsw: spectrum_router: Remove unused argument from mlxsw_sp_nexthop6_type_init() mlxsw: spectrum_router: Consolidate mlxsw_sp_nexthop{4, 6}_type_init() mlxsw: spectrum_router: Consolidate mlxsw_sp_nexthop{4, 6}_type_fini() mlxsw: spectrum_router: Remove outdated comment .../ethernet/mellanox/mlxsw/spectrum_ipip.c | 3 +- .../ethernet/mellanox/mlxsw/spectrum_ipip.h | 3 +- .../ethernet/mellanox/mlxsw/spectrum_router.c | 580 +++++++++--------- 3 files changed, 300 insertions(+), 286 deletions(-)