]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: Fix mlx5_add_flow_rules call with correct num of dests
authorPaul Blakey <paulb@mellanox.com>
Thu, 6 Jul 2017 13:40:34 +0000 (16:40 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Thu, 27 Jul 2017 13:40:17 +0000 (16:40 +0300)
commit704d8f374085a3e37ad5ef9ae014b694b7e0ff68
tree01bacc16c360108ecf9452b4d995eb17b679b986
parent966e1905342b50d8fc1e39e78c8845813a07abdf
net/mlx5: Fix mlx5_add_flow_rules call with correct num of dests

When adding ethtool steering rule with action DISCARD we wrongly
pass a NULL dest with dest_num 1 to mlx5_add_flow_rules().
What this error seems to have caused is sending VPORT 0
(MLX5_FLOW_DESTINATION_TYPE_VPORT) as the fte dest instead of no dests.
We have fte action correctly set to DROP so it might been ignored
anyways.

To reproduce use:
 # sudo ethtool --config-nfc <dev> flow-type ether \
   dst aa:bb:cc:dd:ee:ff action -1

Fixes: 761fc03d4813 ("net/mlx5: Add multi dest support")
Signed-off-by: Paul Blakey <paulb@mellanox.com>
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_fs_ethtool.c