Skip to content

Commit da93d29

Browse files
nirdotandavem330
authored andcommitted
mlxsw: spectrum_router: Relax GRE decap matching check
GRE decap offload is configured when local routes prefix correspond to the local address of one of the offloaded GRE tunnels. The matching check was found to be too strict, such that for a flat GRE configuration, in which the overlay and underlay traffic share the same non-default VRF, decap flow was not offloaded. Relax the check for decap flow offloading. A match occurs if the local address of the tunnel matches the local route address while both share the same VRF table. Fixes: 4607f6d ("mlxsw: spectrum_router: Support IPv4 underlay decap") Signed-off-by: Nir Dotan <[email protected]> Signed-off-by: Ido Schimmel <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent f58a83c commit da93d29

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1275,15 +1275,12 @@ mlxsw_sp_ipip_entry_matches_decap(struct mlxsw_sp *mlxsw_sp,
12751275
{
12761276
u32 ul_tb_id = l3mdev_fib_table(ul_dev) ? : RT_TABLE_MAIN;
12771277
enum mlxsw_sp_ipip_type ipipt = ipip_entry->ipipt;
1278-
struct net_device *ipip_ul_dev;
12791278

12801279
if (mlxsw_sp->router->ipip_ops_arr[ipipt]->ul_proto != ul_proto)
12811280
return false;
12821281

1283-
ipip_ul_dev = __mlxsw_sp_ipip_netdev_ul_dev_get(ipip_entry->ol_dev);
12841282
return mlxsw_sp_ipip_entry_saddr_matches(mlxsw_sp, ul_proto, ul_dip,
1285-
ul_tb_id, ipip_entry) &&
1286-
(!ipip_ul_dev || ipip_ul_dev == ul_dev);
1283+
ul_tb_id, ipip_entry);
12871284
}
12881285

12891286
/* Given decap parameters, find the corresponding IPIP entry. */

0 commit comments

Comments
 (0)