RE: [PATCH] net: usb: r8152: fix transmit queue timeout

From: Hayes Wang

Date: Thu Jan 15 2026 - 22:12:04 EST


lu lu <insyelu@xxxxxxxxx>
> Sent: Friday, January 16, 2026 10:11 AM
[...]
> > netif_tx_lock(tp->netdev);
> >
> > - if (netif_queue_stopped(tp->netdev) &&
> > - skb_queue_len(&tp->tx_queue) < tp->tx_qlen)
> > + if (netif_queue_stopped(tp->netdev)) {
> > + if (skb_queue_len(&tp->tx_queue) < tp->tx_qlen)
> > netif_wake_queue(tp->netdev);
> > + else
> > + netif_trans_update(tp->netdev);
> > + }
> The queue was stopped because it exceeded the threshold. Attempting to
> refresh the time at this point is clearly too late.

Why would this be considered too late?
Based on RTL8152_TX_TIMEOUT, there are about 5 seconds to
wake the queue or update the timestamp before a TX timeout occurs.
I believe 5 seconds should be sufficient.

If there is no TX submission for 5 seconds after the driver stops the queue,
then something is already wrong.

Best Regards,
Hayes