]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Verify encapsulation is supported
authorEli Cohen <eli@mellanox.com>
Thu, 27 Jun 2019 05:34:41 +0000 (08:34 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Mon, 15 Jul 2019 20:04:04 +0000 (13:04 -0700)
commit847b2753cd5a5bfaa4ff5dde4906fabf8ab56626
treefa9b5f66349dfee6fd9707de0a3d7b0a457410d3
parent18dbae4d8bdbb64cab3f6ed623b6297a2ecab6a6
net/mlx5e: Verify encapsulation is supported

When mlx5e_attach_encap() calls mlx5e_get_tc_tun() to get the tunnel
info data struct, check that returned value is not NULL, as would be in
the case of unsupported encapsulation.

Fixes: 42d8ef953d439 ("net/mlx5e: Rearrange tc tunnel code in a modular way")
Signed-off-by: Eli Cohen <eli@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c