net/mlx5e: Fix erroneous freeing of encap header buffer
authorPaul Blakey <paulb@mellanox.com>
Tue, 5 Sep 2017 12:05:51 +0000 (15:05 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Thu, 28 Sep 2017 04:23:09 +0000 (07:23 +0300)
commitace743214ea205c7d433562c5fa24e33bdfda7ab
tree24b0e11cd1f38b74d43c361472ceb2a0118f70b3
parent16f1c5bb3ed75b3cf3ced537db40f7e1a244debe
net/mlx5e: Fix erroneous freeing of encap header buffer

In case the neighbour for the tunnel destination isn't valid,
we send a neighbour update request but we free the encap
header buffer. This is wrong, because we still need it for
allocating a HW encap entry once the neighbour is available.

Fix that by skipping freeing it if we wait for neighbour.

Fixes: 232c001398ae ('net/mlx5e: Add support to neighbour update flow')
Signed-off-by: Paul Blakey <paulb@mellanox.com>
Reviewed-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c