aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/igc/igc_main.c
diff options
context:
space:
mode:
authorAndre Guedes <[email protected]>2020-04-24 20:16:20 +0000
committerJeff Kirsher <[email protected]>2020-05-23 01:21:51 +0000
commit1894df0ccb6ac7ba8b2c799e7d74b5db1180c518 (patch)
tree6f5f7dbd5e3deda65d5c36a28af87d9e389ffeea /drivers/net/ethernet/intel/igc/igc_main.c
parentigc: Fix NFC rules leak when driver is unloaded (diff)
downloadkernel-1894df0ccb6ac7ba8b2c799e7d74b5db1180c518.tar.gz
kernel-1894df0ccb6ac7ba8b2c799e7d74b5db1180c518.zip
igc: Fix NFC rule validation
If we try to overwrite an existing rule with the same filter but different action, we get EEXIST error as shown below. $ ethtool -N eth0 flow-type ether dst <MACADDR> action 1 loc 10 $ ethtool -N eth0 flow-type ether dst <MACADDR> action 2 loc 10 rmgr: Cannot insert RX class rule: File exists The second command is expected to overwrite the previous rule in location 10 and succeed. This patch fixes igc_ethtool_check_nfc_rule() so it also checks the rules location. In case they match, the rule under evaluation should not be considered invalid. Signed-off-by: Andre Guedes <[email protected]> Tested-by: Aaron Brown <[email protected]> Signed-off-by: Jeff Kirsher <[email protected]>
Diffstat (limited to 'drivers/net/ethernet/intel/igc/igc_main.c')
0 files changed, 0 insertions, 0 deletions