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 '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue

Tony Nguyen says:

====================
Intel Wired LAN Driver Updates 2023-01-13 (ixgbe)

This series contains updates to ixgbe driver only.

Jesse resolves warning for RCU pointer by no longer restoring old
pointer.

Sebastian adds waiting for updating of link info on devices utilizing
crosstalk fix to avoid false link state.
====================

Signed-off-by: David S. Miller <davem@davemloft.net>

+24 -10
+18 -3
drivers/net/ethernet/intel/ixgbe/ixgbe_common.c
··· 3292 3292 s32 ixgbe_check_mac_link_generic(struct ixgbe_hw *hw, ixgbe_link_speed *speed, 3293 3293 bool *link_up, bool link_up_wait_to_complete) 3294 3294 { 3295 + bool crosstalk_fix_active = ixgbe_need_crosstalk_fix(hw); 3295 3296 u32 links_reg, links_orig; 3296 3297 u32 i; 3297 3298 3298 3299 /* If Crosstalk fix enabled do the sanity check of making sure 3299 3300 * the SFP+ cage is full. 3300 3301 */ 3301 - if (ixgbe_need_crosstalk_fix(hw)) { 3302 + if (crosstalk_fix_active) { 3302 3303 u32 sfp_cage_full; 3303 3304 3304 3305 switch (hw->mac.type) { ··· 3347 3346 links_reg = IXGBE_READ_REG(hw, IXGBE_LINKS); 3348 3347 } 3349 3348 } else { 3350 - if (links_reg & IXGBE_LINKS_UP) 3349 + if (links_reg & IXGBE_LINKS_UP) { 3350 + if (crosstalk_fix_active) { 3351 + /* Check the link state again after a delay 3352 + * to filter out spurious link up 3353 + * notifications. 3354 + */ 3355 + mdelay(5); 3356 + links_reg = IXGBE_READ_REG(hw, IXGBE_LINKS); 3357 + if (!(links_reg & IXGBE_LINKS_UP)) { 3358 + *link_up = false; 3359 + *speed = IXGBE_LINK_SPEED_UNKNOWN; 3360 + return 0; 3361 + } 3362 + } 3351 3363 *link_up = true; 3352 - else 3364 + } else { 3353 3365 *link_up = false; 3366 + } 3354 3367 } 3355 3368 3356 3369 switch (links_reg & IXGBE_LINKS_SPEED_82599) {
+6 -7
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
··· 6647 6647 rx_ring->queue_index, ixgbe_rx_napi_id(rx_ring)) < 0) 6648 6648 goto err; 6649 6649 6650 - rx_ring->xdp_prog = adapter->xdp_prog; 6650 + WRITE_ONCE(rx_ring->xdp_prog, adapter->xdp_prog); 6651 6651 6652 6652 return 0; 6653 6653 err: ··· 10297 10297 synchronize_rcu(); 10298 10298 err = ixgbe_setup_tc(dev, adapter->hw_tcs); 10299 10299 10300 - if (err) { 10301 - rcu_assign_pointer(adapter->xdp_prog, old_prog); 10300 + if (err) 10302 10301 return -EINVAL; 10303 - } 10304 10302 } else { 10305 - for (i = 0; i < adapter->num_rx_queues; i++) 10306 - (void)xchg(&adapter->rx_ring[i]->xdp_prog, 10307 - adapter->xdp_prog); 10303 + for (i = 0; i < adapter->num_rx_queues; i++) { 10304 + WRITE_ONCE(adapter->rx_ring[i]->xdp_prog, 10305 + adapter->xdp_prog); 10306 + } 10308 10307 } 10309 10308 10310 10309 if (old_prog)