Skip to content

Commit f0d7519

Browse files
committed
eth: ixgbe: fix the wake condition
Flip the netif_carrier_ok() condition in queue wake logic. When I moved it to inside __netif_txq_completed_wake() I missed negating it. This made the condition ineffective and could probably lead to crashes. Fixes: 301f227 ("net: piggy back on the memory barrier in bql when waking queues") Reviewed-by: Tony Nguyen <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 649c3fe commit f0d7519

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/intel/ixgbe/ixgbe_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1256,7 +1256,7 @@ static bool ixgbe_clean_tx_irq(struct ixgbe_q_vector *q_vector,
12561256
if (!__netif_txq_completed_wake(txq, total_packets, total_bytes,
12571257
ixgbe_desc_unused(tx_ring),
12581258
TX_WAKE_THRESHOLD,
1259-
netif_carrier_ok(tx_ring->netdev) &&
1259+
!netif_carrier_ok(tx_ring->netdev) ||
12601260
test_bit(__IXGBE_DOWN, &adapter->state)))
12611261
++tx_ring->tx_stats.restart_queue;
12621262

0 commit comments

Comments
 (0)