Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'intel-wired-lan-driver-updates-2026-04-14-ice-i40e-iavf-idpf-e1000e'

Jacob Keller says:

====================
Intel Wired LAN Driver Updates 2026-04-14 (ice, i40e, iavf, e1000e)

Grzegorz updates the logic for adjusting the PTP hardware clock on E830,
fixing a bug that prevented adjustments below S32_MAX/MIN nanoseconds.

Grzegorz and Zoli update the PCS latency settings for E825 devices at 10GbE
and 25GbE, improving the accuracy of timestamps based on data from
production hardware.

Michal Schmidt fixes a double-free that could happen if a particular error
path is taken in ice_xmit_frame_ring().

Guangshuo fixes a double-free that could happen during error paths in the
ice_sf_eth_activate() function.

Paul Greenwalt fixes the PHY link configuration when the link-down-on-close
driver parameter is enabled and new media is inserted.

Paul Greenwalt fixes the ICE_AQ_LINK_SPEED_M macro for 200G, enabling 200G
link speed advertisement.

Keita Morisaki fixes a race condition in the ice Tx timestamp ring cleanup,
preventing a possible NULL pointer dereference.

Kohei Enju fixes a potential NULL pointer dereference in ice_set_ring_param().

Kohei Enju fixes i40e to stop advertising IFF_SUPP_NOFCS, when the driver
does not actually support the feature.

Petr fixes the VLAN L2TAG2 mask when the iAVF VF and a PF negotiate use of
the legacy Rx descriptor format.

Matt fixes the unrolling logic for PTP when the e1000e probe fails after
the PTP clock has been registered.

**A note to stable backports**

The patches [7/12] ("ice: fix race condition in TX timestamp ring
cleanup") and [8/12] ("ice: fix potential NULL pointer deref in error
path of ice_set_ringparam()") must be backported together. Otherwise the
fix in patch 8 will not work properly.
====================

Link: https://patch.msgid.link/20260416-iwl-net-submission-2026-04-14-v2-0-686c33c9828d@intel.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

+77 -126
+1
drivers/net/ethernet/intel/e1000e/netdev.c
··· 7706 7706 err_register: 7707 7707 if (!(adapter->flags & FLAG_HAS_AMT)) 7708 7708 e1000e_release_hw_control(adapter); 7709 + e1000e_ptp_remove(adapter); 7709 7710 err_eeprom: 7710 7711 if (hw->phy.ops.check_reset_block && !hw->phy.ops.check_reset_block(hw)) 7711 7712 e1000_phy_hw_reset(&adapter->hw);
-1
drivers/net/ethernet/intel/i40e/i40e_main.c
··· 13783 13783 netdev->neigh_priv_len = sizeof(u32) * 4; 13784 13784 13785 13785 netdev->priv_flags |= IFF_UNICAST_FLT; 13786 - netdev->priv_flags |= IFF_SUPP_NOFCS; 13787 13786 /* Setup netdev TC information */ 13788 13787 i40e_vsi_config_netdev_tc(vsi, vsi->tc_config.enabled_tc); 13789 13788
+1 -1
drivers/net/ethernet/intel/iavf/iavf_type.h
··· 277 277 /* L2 Tag 2 Presence */ 278 278 #define IAVF_RXD_LEGACY_L2TAG2P_M BIT(0) 279 279 /* Stripped S-TAG VLAN from the receive packet */ 280 - #define IAVF_RXD_LEGACY_L2TAG2_M GENMASK_ULL(63, 32) 280 + #define IAVF_RXD_LEGACY_L2TAG2_M GENMASK_ULL(63, 48) 281 281 /* Stripped S-TAG VLAN from the receive packet */ 282 282 #define IAVF_RXD_FLEX_L2TAG2_2_M GENMASK_ULL(63, 48) 283 283 /* The packet is a UDP tunneled packet */
+2 -2
drivers/net/ethernet/intel/ice/ice.h
··· 753 753 754 754 static inline void ice_set_ring_xdp(struct ice_tx_ring *ring) 755 755 { 756 - ring->flags |= ICE_TX_FLAGS_RING_XDP; 756 + set_bit(ICE_TX_RING_FLAGS_XDP, ring->flags); 757 757 } 758 758 759 759 /** ··· 778 778 */ 779 779 static inline bool ice_is_txtime_cfg(const struct ice_tx_ring *ring) 780 780 { 781 - return !!(ring->flags & ICE_TX_FLAGS_TXTIME); 781 + return test_bit(ICE_TX_RING_FLAGS_TXTIME, ring->flags); 782 782 } 783 783 784 784 /**
+1 -1
drivers/net/ethernet/intel/ice/ice_adminq_cmd.h
··· 1252 1252 #define ICE_AQ_LINK_PWR_QSFP_CLASS_3 2 1253 1253 #define ICE_AQ_LINK_PWR_QSFP_CLASS_4 3 1254 1254 __le16 link_speed; 1255 - #define ICE_AQ_LINK_SPEED_M 0x7FF 1255 + #define ICE_AQ_LINK_SPEED_M GENMASK(11, 0) 1256 1256 #define ICE_AQ_LINK_SPEED_10MB BIT(0) 1257 1257 #define ICE_AQ_LINK_SPEED_100MB BIT(1) 1258 1258 #define ICE_AQ_LINK_SPEED_1000MB BIT(2)
+1 -1
drivers/net/ethernet/intel/ice/ice_dcb_lib.c
··· 943 943 /* if this is not already set it means a VLAN 0 + priority needs 944 944 * to be offloaded 945 945 */ 946 - if (tx_ring->flags & ICE_TX_FLAGS_RING_VLAN_L2TAG2) 946 + if (test_bit(ICE_TX_RING_FLAGS_VLAN_L2TAG2, tx_ring->flags)) 947 947 first->tx_flags |= ICE_TX_FLAGS_HW_OUTER_SINGLE_VLAN; 948 948 else 949 949 first->tx_flags |= ICE_TX_FLAGS_HW_VLAN;
+1
drivers/net/ethernet/intel/ice/ice_ethtool.c
··· 3290 3290 tx_rings[i].desc = NULL; 3291 3291 tx_rings[i].tx_buf = NULL; 3292 3292 tx_rings[i].tstamp_ring = NULL; 3293 + clear_bit(ICE_TX_RING_FLAGS_TXTIME, tx_rings[i].flags); 3293 3294 tx_rings[i].tx_tstamps = &pf->ptp.port.tx; 3294 3295 err = ice_setup_tx_ring(&tx_rings[i]); 3295 3296 if (err) {
+2 -2
drivers/net/ethernet/intel/ice/ice_lib.c
··· 1412 1412 ring->count = vsi->num_tx_desc; 1413 1413 ring->txq_teid = ICE_INVAL_TEID; 1414 1414 if (dvm_ena) 1415 - ring->flags |= ICE_TX_FLAGS_RING_VLAN_L2TAG2; 1415 + set_bit(ICE_TX_RING_FLAGS_VLAN_L2TAG2, ring->flags); 1416 1416 else 1417 - ring->flags |= ICE_TX_FLAGS_RING_VLAN_L2TAG1; 1417 + set_bit(ICE_TX_RING_FLAGS_VLAN_L2TAG1, ring->flags); 1418 1418 WRITE_ONCE(vsi->tx_rings[i], ring); 1419 1419 } 1420 1420
+27 -94
drivers/net/ethernet/intel/ice/ice_main.c
··· 1923 1923 } 1924 1924 1925 1925 /** 1926 - * ice_force_phys_link_state - Force the physical link state 1927 - * @vsi: VSI to force the physical link state to up/down 1928 - * @link_up: true/false indicates to set the physical link to up/down 1929 - * 1930 - * Force the physical link state by getting the current PHY capabilities from 1931 - * hardware and setting the PHY config based on the determined capabilities. If 1932 - * link changes a link event will be triggered because both the Enable Automatic 1933 - * Link Update and LESM Enable bits are set when setting the PHY capabilities. 1934 - * 1935 - * Returns 0 on success, negative on failure 1936 - */ 1937 - static int ice_force_phys_link_state(struct ice_vsi *vsi, bool link_up) 1938 - { 1939 - struct ice_aqc_get_phy_caps_data *pcaps; 1940 - struct ice_aqc_set_phy_cfg_data *cfg; 1941 - struct ice_port_info *pi; 1942 - struct device *dev; 1943 - int retcode; 1944 - 1945 - if (!vsi || !vsi->port_info || !vsi->back) 1946 - return -EINVAL; 1947 - if (vsi->type != ICE_VSI_PF) 1948 - return 0; 1949 - 1950 - dev = ice_pf_to_dev(vsi->back); 1951 - 1952 - pi = vsi->port_info; 1953 - 1954 - pcaps = kzalloc_obj(*pcaps); 1955 - if (!pcaps) 1956 - return -ENOMEM; 1957 - 1958 - retcode = ice_aq_get_phy_caps(pi, false, ICE_AQC_REPORT_ACTIVE_CFG, pcaps, 1959 - NULL); 1960 - if (retcode) { 1961 - dev_err(dev, "Failed to get phy capabilities, VSI %d error %d\n", 1962 - vsi->vsi_num, retcode); 1963 - retcode = -EIO; 1964 - goto out; 1965 - } 1966 - 1967 - /* No change in link */ 1968 - if (link_up == !!(pcaps->caps & ICE_AQC_PHY_EN_LINK) && 1969 - link_up == !!(pi->phy.link_info.link_info & ICE_AQ_LINK_UP)) 1970 - goto out; 1971 - 1972 - /* Use the current user PHY configuration. The current user PHY 1973 - * configuration is initialized during probe from PHY capabilities 1974 - * software mode, and updated on set PHY configuration. 1975 - */ 1976 - cfg = kmemdup(&pi->phy.curr_user_phy_cfg, sizeof(*cfg), GFP_KERNEL); 1977 - if (!cfg) { 1978 - retcode = -ENOMEM; 1979 - goto out; 1980 - } 1981 - 1982 - cfg->caps |= ICE_AQ_PHY_ENA_AUTO_LINK_UPDT; 1983 - if (link_up) 1984 - cfg->caps |= ICE_AQ_PHY_ENA_LINK; 1985 - else 1986 - cfg->caps &= ~ICE_AQ_PHY_ENA_LINK; 1987 - 1988 - retcode = ice_aq_set_phy_cfg(&vsi->back->hw, pi, cfg, NULL); 1989 - if (retcode) { 1990 - dev_err(dev, "Failed to set phy config, VSI %d error %d\n", 1991 - vsi->vsi_num, retcode); 1992 - retcode = -EIO; 1993 - } 1994 - 1995 - kfree(cfg); 1996 - out: 1997 - kfree(pcaps); 1998 - return retcode; 1999 - } 2000 - 2001 - /** 2002 1926 * ice_init_nvm_phy_type - Initialize the NVM PHY type 2003 1927 * @pi: port info structure 2004 1928 * ··· 1990 2066 * first time media is available. The ICE_LINK_DEFAULT_OVERRIDE_PENDING state 1991 2067 * is used to indicate that the user PHY cfg default override is initialized 1992 2068 * and the PHY has not been configured with the default override settings. The 1993 - * state is set here, and cleared in ice_configure_phy the first time the PHY is 2069 + * state is set here, and cleared in ice_phy_cfg the first time the PHY is 1994 2070 * configured. 1995 2071 * 1996 2072 * This function should be called only if the FW doesn't support default ··· 2096 2172 } 2097 2173 2098 2174 /** 2099 - * ice_configure_phy - configure PHY 2175 + * ice_phy_cfg - configure PHY 2100 2176 * @vsi: VSI of PHY 2177 + * @link_en: true/false indicates to set link to enable/disable 2101 2178 * 2102 2179 * Set the PHY configuration. If the current PHY configuration is the same as 2103 - * the curr_user_phy_cfg, then do nothing to avoid link flap. Otherwise 2104 - * configure the based get PHY capabilities for topology with media. 2180 + * the curr_user_phy_cfg and link_en hasn't changed, then do nothing to avoid 2181 + * link flap. Otherwise configure the PHY based get PHY capabilities for 2182 + * topology with media and link_en. 2183 + * 2184 + * Return: 0 on success, negative on failure 2105 2185 */ 2106 - static int ice_configure_phy(struct ice_vsi *vsi) 2186 + static int ice_phy_cfg(struct ice_vsi *vsi, bool link_en) 2107 2187 { 2108 2188 struct device *dev = ice_pf_to_dev(vsi->back); 2109 2189 struct ice_port_info *pi = vsi->port_info; ··· 2127 2199 phy->link_info.topo_media_conflict == ICE_AQ_LINK_TOPO_UNSUPP_MEDIA) 2128 2200 return -EPERM; 2129 2201 2130 - if (test_bit(ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA, pf->flags)) 2131 - return ice_force_phys_link_state(vsi, true); 2132 - 2133 2202 pcaps = kzalloc_obj(*pcaps); 2134 2203 if (!pcaps) 2135 2204 return -ENOMEM; ··· 2140 2215 goto done; 2141 2216 } 2142 2217 2143 - /* If PHY enable link is configured and configuration has not changed, 2144 - * there's nothing to do 2145 - */ 2146 - if (pcaps->caps & ICE_AQC_PHY_EN_LINK && 2218 + /* Configuration has not changed. There's nothing to do. */ 2219 + if (link_en == !!(pcaps->caps & ICE_AQC_PHY_EN_LINK) && 2147 2220 ice_phy_caps_equals_cfg(pcaps, &phy->curr_user_phy_cfg)) 2148 2221 goto done; 2149 2222 ··· 2205 2282 */ 2206 2283 ice_cfg_phy_fc(pi, cfg, phy->curr_user_fc_req); 2207 2284 2208 - /* Enable link and link update */ 2209 - cfg->caps |= ICE_AQ_PHY_ENA_AUTO_LINK_UPDT | ICE_AQ_PHY_ENA_LINK; 2285 + /* Enable/Disable link and link update */ 2286 + cfg->caps |= ICE_AQ_PHY_ENA_AUTO_LINK_UPDT; 2287 + if (link_en) 2288 + cfg->caps |= ICE_AQ_PHY_ENA_LINK; 2289 + else 2290 + cfg->caps &= ~ICE_AQ_PHY_ENA_LINK; 2210 2291 2211 2292 err = ice_aq_set_phy_cfg(&pf->hw, pi, cfg, NULL); 2212 2293 if (err) ··· 2263 2336 test_bit(ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA, vsi->back->flags)) 2264 2337 return; 2265 2338 2266 - err = ice_configure_phy(vsi); 2339 + err = ice_phy_cfg(vsi, true); 2267 2340 if (!err) 2268 2341 clear_bit(ICE_FLAG_NO_MEDIA, pf->flags); 2269 2342 ··· 4819 4892 4820 4893 if (!test_bit(ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA, pf->flags)) { 4821 4894 struct ice_vsi *vsi = ice_get_main_vsi(pf); 4895 + struct ice_link_default_override_tlv *ldo; 4896 + bool link_en; 4897 + 4898 + ldo = &pf->link_dflt_override; 4899 + link_en = !(ldo->options & 4900 + ICE_LINK_OVERRIDE_AUTO_LINK_DIS); 4822 4901 4823 4902 if (vsi) 4824 - ice_configure_phy(vsi); 4903 + ice_phy_cfg(vsi, link_en); 4825 4904 } 4826 4905 } else { 4827 4906 set_bit(ICE_FLAG_NO_MEDIA, pf->flags); ··· 9640 9707 } 9641 9708 } 9642 9709 9643 - err = ice_configure_phy(vsi); 9710 + err = ice_phy_cfg(vsi, true); 9644 9711 if (err) { 9645 9712 netdev_err(netdev, "Failed to set physical link up, error %d\n", 9646 9713 err); ··· 9681 9748 } 9682 9749 9683 9750 if (test_bit(ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA, vsi->back->flags)) { 9684 - int link_err = ice_force_phys_link_state(vsi, false); 9751 + int link_err = ice_phy_cfg(vsi, false); 9685 9752 9686 9753 if (link_err) { 9687 9754 if (link_err == -ENOMEDIUM)
+6 -6
drivers/net/ethernet/intel/ice/ice_ptp_consts.h
··· 78 78 .blktime = 0x666, /* 3.2 */ 79 79 .tx_offset = { 80 80 .serdes = 0x234c, /* 17.6484848 */ 81 - .no_fec = 0x8e80, /* 71.25 */ 81 + .no_fec = 0x93d9, /* 73 */ 82 82 .fc = 0xb4a4, /* 90.32 */ 83 83 .sfd = 0x4a4, /* 2.32 */ 84 84 .onestep = 0x4ccd /* 38.4 */ 85 85 }, 86 86 .rx_offset = { 87 87 .serdes = 0xffffeb27, /* -10.42424 */ 88 - .no_fec = 0xffffcccd, /* -25.6 */ 88 + .no_fec = 0xffffc7b6, /* -28 */ 89 89 .fc = 0xfffc557b, /* -469.26 */ 90 90 .sfd = 0x4a4, /* 2.32 */ 91 91 .bs_ds = 0x32 /* 0.0969697 */ ··· 118 118 .mktime = 0x147b, /* 10.24, only if RS-FEC enabled */ 119 119 .tx_offset = { 120 120 .serdes = 0xe1e, /* 7.0593939 */ 121 - .no_fec = 0x3857, /* 28.17 */ 121 + .no_fec = 0x4266, /* 33 */ 122 122 .fc = 0x48c3, /* 36.38 */ 123 - .rs = 0x8100, /* 64.5 */ 123 + .rs = 0x8a00, /* 69 */ 124 124 .sfd = 0x1dc, /* 0.93 */ 125 125 .onestep = 0x1eb8 /* 15.36 */ 126 126 }, 127 127 .rx_offset = { 128 128 .serdes = 0xfffff7a9, /* -4.1697 */ 129 - .no_fec = 0xffffe71a, /* -12.45 */ 129 + .no_fec = 0xffffe700, /* -12 */ 130 130 .fc = 0xfffe894d, /* -187.35 */ 131 - .rs = 0xfffff8cd, /* -3.6 */ 131 + .rs = 0xfffff8cc, /* -3 */ 132 132 .sfd = 0x1dc, /* 0.93 */ 133 133 .bs_ds = 0x14 /* 0.0387879, RS-FEC 0 */ 134 134 }
+3 -3
drivers/net/ethernet/intel/ice/ice_ptp_hw.c
··· 5381 5381 */ 5382 5382 int ice_ptp_adj_clock(struct ice_hw *hw, s32 adj) 5383 5383 { 5384 + int err = 0; 5384 5385 u8 tmr_idx; 5385 - int err; 5386 5386 5387 5387 tmr_idx = hw->func_caps.ts_func_info.tmr_index_owned; 5388 5388 ··· 5399 5399 err = ice_ptp_prep_phy_adj_e810(hw, adj); 5400 5400 break; 5401 5401 case ICE_MAC_E830: 5402 - /* E830 sync PHYs automatically after setting GLTSYN_SHADJ */ 5403 - return 0; 5402 + /* E830 sync PHYs automatically after setting cmd register */ 5403 + break; 5404 5404 case ICE_MAC_GENERIC: 5405 5405 err = ice_ptp_prep_phy_adj_e82x(hw, adj); 5406 5406 break;
+2
drivers/net/ethernet/intel/ice/ice_sf_eth.c
··· 305 305 306 306 aux_dev_uninit: 307 307 auxiliary_device_uninit(&sf_dev->adev); 308 + return err; 309 + 308 310 sf_dev_free: 309 311 kfree(sf_dev); 310 312 xa_erase:
+20 -9
drivers/net/ethernet/intel/ice/ice_txrx.c
··· 190 190 void ice_free_tx_tstamp_ring(struct ice_tx_ring *tx_ring) 191 191 { 192 192 ice_free_tstamp_ring(tx_ring); 193 + clear_bit(ICE_TX_RING_FLAGS_TXTIME, tx_ring->flags); 194 + smp_wmb(); /* order flag clear before pointer NULL */ 193 195 kfree_rcu(tx_ring->tstamp_ring, rcu); 194 - tx_ring->tstamp_ring = NULL; 195 - tx_ring->flags &= ~ICE_TX_FLAGS_TXTIME; 196 + WRITE_ONCE(tx_ring->tstamp_ring, NULL); 196 197 } 197 198 198 199 /** ··· 406 405 tx_ring->tstamp_ring = tstamp_ring; 407 406 tstamp_ring->desc = NULL; 408 407 tstamp_ring->count = ice_calc_ts_ring_count(tx_ring); 409 - tx_ring->flags |= ICE_TX_FLAGS_TXTIME; 408 + set_bit(ICE_TX_RING_FLAGS_TXTIME, tx_ring->flags); 410 409 return 0; 411 410 } 412 411 ··· 1522 1521 return; 1523 1522 1524 1523 if (ice_is_txtime_cfg(tx_ring)) { 1525 - struct ice_tstamp_ring *tstamp_ring = tx_ring->tstamp_ring; 1526 - u32 tstamp_count = tstamp_ring->count; 1527 - u32 j = tstamp_ring->next_to_use; 1524 + struct ice_tstamp_ring *tstamp_ring; 1525 + u32 tstamp_count, j; 1528 1526 struct ice_ts_desc *ts_desc; 1529 1527 struct timespec64 ts; 1530 1528 u32 tstamp; 1529 + 1530 + smp_rmb(); /* order flag read before pointer read */ 1531 + tstamp_ring = READ_ONCE(tx_ring->tstamp_ring); 1532 + if (unlikely(!tstamp_ring)) 1533 + goto ring_kick; 1534 + 1535 + tstamp_count = tstamp_ring->count; 1536 + j = tstamp_ring->next_to_use; 1531 1537 1532 1538 ts = ktime_to_timespec64(first->skb->tstamp); 1533 1539 tstamp = ts.tv_nsec >> ICE_TXTIME_CTX_RESOLUTION_128NS; ··· 1563 1555 tstamp_ring->next_to_use = j; 1564 1556 writel_relaxed(j, tstamp_ring->tail); 1565 1557 } else { 1558 + ring_kick: 1566 1559 writel_relaxed(i, tx_ring->tail); 1567 1560 } 1568 1561 return; ··· 1823 1814 */ 1824 1815 if (skb_vlan_tag_present(skb)) { 1825 1816 first->vid = skb_vlan_tag_get(skb); 1826 - if (tx_ring->flags & ICE_TX_FLAGS_RING_VLAN_L2TAG2) 1817 + if (test_bit(ICE_TX_RING_FLAGS_VLAN_L2TAG2, tx_ring->flags)) 1827 1818 first->tx_flags |= ICE_TX_FLAGS_HW_OUTER_SINGLE_VLAN; 1828 1819 else 1829 1820 first->tx_flags |= ICE_TX_FLAGS_HW_VLAN; ··· 2167 2158 2168 2159 ice_trace(xmit_frame_ring, tx_ring, skb); 2169 2160 2161 + /* record the location of the first descriptor for this packet */ 2162 + first = &tx_ring->tx_buf[tx_ring->next_to_use]; 2163 + 2170 2164 count = ice_xmit_desc_count(skb); 2171 2165 if (ice_chk_linearize(skb, count)) { 2172 2166 if (__skb_linearize(skb)) ··· 2195 2183 2196 2184 offload.tx_ring = tx_ring; 2197 2185 2198 - /* record the location of the first descriptor for this packet */ 2199 - first = &tx_ring->tx_buf[tx_ring->next_to_use]; 2200 2186 first->skb = skb; 2201 2187 first->type = ICE_TX_BUF_SKB; 2202 2188 first->bytecount = max_t(unsigned int, skb->len, ETH_ZLEN); ··· 2259 2249 out_drop: 2260 2250 ice_trace(xmit_frame_ring_drop, tx_ring, skb); 2261 2251 dev_kfree_skb_any(skb); 2252 + first->type = ICE_TX_BUF_EMPTY; 2262 2253 return NETDEV_TX_OK; 2263 2254 } 2264 2255
+10 -6
drivers/net/ethernet/intel/ice/ice_txrx.h
··· 212 212 ICE_RX_DTYPE_SPLIT_ALWAYS = 2, 213 213 }; 214 214 215 + enum ice_tx_ring_flags { 216 + ICE_TX_RING_FLAGS_XDP, 217 + ICE_TX_RING_FLAGS_VLAN_L2TAG1, 218 + ICE_TX_RING_FLAGS_VLAN_L2TAG2, 219 + ICE_TX_RING_FLAGS_TXTIME, 220 + ICE_TX_RING_FLAGS_NBITS, 221 + }; 222 + 215 223 struct ice_pkt_ctx { 216 224 u64 cached_phctime; 217 225 __be16 vlan_proto; ··· 360 352 u16 count; /* Number of descriptors */ 361 353 u16 q_index; /* Queue number of ring */ 362 354 363 - u8 flags; 364 - #define ICE_TX_FLAGS_RING_XDP BIT(0) 365 - #define ICE_TX_FLAGS_RING_VLAN_L2TAG1 BIT(1) 366 - #define ICE_TX_FLAGS_RING_VLAN_L2TAG2 BIT(2) 367 - #define ICE_TX_FLAGS_TXTIME BIT(3) 355 + DECLARE_BITMAP(flags, ICE_TX_RING_FLAGS_NBITS); 368 356 369 357 struct xsk_buff_pool *xsk_pool; 370 358 ··· 402 398 403 399 static inline bool ice_ring_is_xdp(struct ice_tx_ring *ring) 404 400 { 405 - return !!(ring->flags & ICE_TX_FLAGS_RING_XDP); 401 + return test_bit(ICE_TX_RING_FLAGS_XDP, ring->flags); 406 402 } 407 403 408 404 enum ice_container_type {