Skip to content

Commit f5247a6

Browse files
Konstantin Taranovkuba-moo
Konstantin Taranov
authored andcommitted
net: mana: Use xdp_set_features_flag instead of direct assignment
This patch uses a helper function for assignment of xdp_features. This change simplifies backports. Signed-off-by: Konstantin Taranov <[email protected]> Signed-off-by: Haiyang Zhang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 6d90b64 commit f5247a6

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

drivers/net/ethernet/microsoft/mana/mana_en.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2687,8 +2687,9 @@ static int mana_probe_port(struct mana_context *ac, int port_idx,
26872687
ndev->features = ndev->hw_features | NETIF_F_HW_VLAN_CTAG_TX |
26882688
NETIF_F_HW_VLAN_CTAG_RX;
26892689
ndev->vlan_features = ndev->features;
2690-
ndev->xdp_features = NETDEV_XDP_ACT_BASIC | NETDEV_XDP_ACT_REDIRECT |
2691-
NETDEV_XDP_ACT_NDO_XMIT;
2690+
xdp_set_features_flag(ndev, NETDEV_XDP_ACT_BASIC |
2691+
NETDEV_XDP_ACT_REDIRECT |
2692+
NETDEV_XDP_ACT_NDO_XMIT);
26922693

26932694
err = register_netdev(ndev);
26942695
if (err) {

0 commit comments

Comments
 (0)