Skip to content

Commit f9c961e

Browse files
rsalvaterraanguy11
authored andcommitted
igc: enable HW vlan tag insertion/stripping by default
This is enabled by default in other Intel drivers I've checked (e1000, e1000e, iavf, igb and ice). Fixes an out-of-the-box performance issue when running OpenWrt on typical mini-PCs with igc-supported Ethernet controllers and 802.1Q VLAN configurations, as ethtool isn't part of the default packages and sane defaults are expected. In my specific case, with an Intel N100-based machine with four I226-V Ethernet controllers, my upload performance increased from under 30 Mb/s to the expected ~1 Gb/s. Signed-off-by: Rui Salvaterra <[email protected]> Reviewed-by: Simon Horman <[email protected]> Reviewed-by: Vitaly Lifshits <[email protected]> Reviewed-by: Kurt Kanzenbach <[email protected]> Tested-by: Mor Bar-Gabay <[email protected]> Signed-off-by: Tony Nguyen <[email protected]>
1 parent cdcb380 commit f9c961e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/net/ethernet/intel/igc/igc_main.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7125,6 +7125,9 @@ static int igc_probe(struct pci_dev *pdev,
71257125
netdev->xdp_features = NETDEV_XDP_ACT_BASIC | NETDEV_XDP_ACT_REDIRECT |
71267126
NETDEV_XDP_ACT_XSK_ZEROCOPY;
71277127

7128+
/* enable HW vlan tag insertion/stripping by default */
7129+
netdev->features |= NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_RX;
7130+
71287131
/* MTU range: 68 - 9216 */
71297132
netdev->min_mtu = ETH_MIN_MTU;
71307133
netdev->max_mtu = MAX_STD_JUMBO_FRAME_SIZE;

0 commit comments

Comments
 (0)