Commit d9dc444
iavf: stop removing VLAN filters from PF on interface down
[ Upstream commit f2ce65b ]
When a VF goes down, the driver currently sends DEL_VLAN to the PF for
every VLAN filter (ACTIVE -> DISABLE -> send DEL -> INACTIVE), then
re-adds them all on UP (INACTIVE -> ADD -> send ADD -> ADDING ->
ACTIVE). This round-trip is unnecessary because:
1. The PF disables the VF's queues via VIRTCHNL_OP_DISABLE_QUEUES,
which already prevents all RX/TX traffic regardless of VLAN filter
state.
2. The VLAN filters remaining in PF HW while the VF is down is
harmless - packets matching those filters have nowhere to go with
queues disabled.
3. The DEL+ADD cycle during down/up creates race windows where the
VLAN filter list is incomplete. With spoofcheck enabled, the PF
enables TX VLAN filtering on the first non-zero VLAN add, blocking
traffic for any VLANs not yet re-added.
Remove the entire DISABLE/INACTIVE state machinery:
- Remove IAVF_VLAN_DISABLE and IAVF_VLAN_INACTIVE enum values
- Remove iavf_restore_filters() and its call from iavf_open()
- Remove VLAN filter handling from iavf_clear_mac_vlan_filters(),
rename it to iavf_clear_mac_filters()
- Remove DEL_VLAN_FILTER scheduling from iavf_down()
- Remove all DISABLE/INACTIVE handling from iavf_del_vlans()
VLAN filters now stay ACTIVE across down/up cycles. Only explicit
user removal (ndo_vlan_rx_kill_vid) or PF/VF reset triggers VLAN
filter deletion/re-addition.
Fixes: ed1f5b5 ("i40evf: remove VLAN filters on close")
Signed-off-by: Petr Oros <poros@redhat.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Tested-by: Rafal Romanowski <rafal.romanowski@intel.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Link: https://patch.msgid.link/20260427-jk-iwl-net-petr-oros-fixes-v1-2-cdcb48303fd8@intel.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent 611d500 commit d9dc444
3 files changed
Lines changed: 12 additions & 66 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
159 | 159 | | |
160 | 160 | | |
161 | 161 | | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | | - | |
| 162 | + | |
| 163 | + | |
166 | 164 | | |
167 | 165 | | |
168 | 166 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
818 | 818 | | |
819 | 819 | | |
820 | 820 | | |
821 | | - | |
822 | | - | |
823 | | - | |
824 | | - | |
825 | | - | |
826 | | - | |
827 | | - | |
828 | | - | |
829 | | - | |
830 | | - | |
831 | | - | |
832 | | - | |
833 | | - | |
834 | | - | |
835 | | - | |
836 | | - | |
837 | | - | |
838 | | - | |
839 | | - | |
840 | | - | |
841 | | - | |
842 | 821 | | |
843 | 822 | | |
844 | 823 | | |
| |||
1257 | 1236 | | |
1258 | 1237 | | |
1259 | 1238 | | |
1260 | | - | |
1261 | | - | |
| 1239 | + | |
| 1240 | + | |
1262 | 1241 | | |
1263 | 1242 | | |
1264 | | - | |
| 1243 | + | |
1265 | 1244 | | |
1266 | | - | |
1267 | 1245 | | |
1268 | 1246 | | |
1269 | 1247 | | |
| |||
1282 | 1260 | | |
1283 | 1261 | | |
1284 | 1262 | | |
1285 | | - | |
1286 | | - | |
1287 | | - | |
1288 | | - | |
1289 | | - | |
1290 | 1263 | | |
1291 | 1264 | | |
1292 | 1265 | | |
| |||
1382 | 1355 | | |
1383 | 1356 | | |
1384 | 1357 | | |
1385 | | - | |
| 1358 | + | |
1386 | 1359 | | |
1387 | 1360 | | |
1388 | 1361 | | |
| |||
1399 | 1372 | | |
1400 | 1373 | | |
1401 | 1374 | | |
1402 | | - | |
1403 | | - | |
1404 | 1375 | | |
1405 | 1376 | | |
1406 | 1377 | | |
| |||
4363 | 4334 | | |
4364 | 4335 | | |
4365 | 4336 | | |
4366 | | - | |
4367 | | - | |
4368 | 4337 | | |
4369 | 4338 | | |
4370 | 4339 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
799 | 799 | | |
800 | 800 | | |
801 | 801 | | |
802 | | - | |
803 | | - | |
804 | | - | |
805 | | - | |
806 | | - | |
807 | | - | |
808 | 802 | | |
809 | 803 | | |
810 | 804 | | |
811 | 805 | | |
812 | 806 | | |
813 | | - | |
814 | | - | |
815 | | - | |
816 | | - | |
817 | | - | |
| 807 | + | |
818 | 808 | | |
819 | 809 | | |
820 | 810 | | |
| |||
846 | 836 | | |
847 | 837 | | |
848 | 838 | | |
849 | | - | |
850 | | - | |
851 | | - | |
852 | | - | |
853 | | - | |
854 | | - | |
855 | | - | |
| 839 | + | |
856 | 840 | | |
857 | 841 | | |
858 | 842 | | |
| |||
893 | 877 | | |
894 | 878 | | |
895 | 879 | | |
896 | | - | |
897 | | - | |
| 880 | + | |
898 | 881 | | |
899 | 882 | | |
900 | 883 | | |
| |||
908 | 891 | | |
909 | 892 | | |
910 | 893 | | |
911 | | - | |
912 | | - | |
913 | | - | |
914 | | - | |
915 | | - | |
916 | | - | |
917 | | - | |
| 894 | + | |
| 895 | + | |
| 896 | + | |
918 | 897 | | |
919 | 898 | | |
920 | 899 | | |
| |||
0 commit comments