Thread (4 messages) 4 messages, 2 authors, 2026-01-17

Re: [PATCH net v3] net: stmmac: fix transmit queue timed out after resume for tso

From: Tao Wang <hidden>
Date: 2026-01-17 07:59:49
Also in: linux-doc, lkml

Rather than using tx_q->tx_skbuff_dma[].last_segment to determine
whether the first descriptor entry is the only segment, calculate the
number of descriptor entries used. If there is only one descriptor,
then the first is also the last, so mark it as such.
This is a good idea. tx_q->tx_skbuff_dma[].last_segment no longer carries
 much meaning and can indeed be removed altogether.
+       is_last_segment = ((tx_q->cur_tx - first_entry) &
+                          (priv->dma_conf.dma_tx_size - 1)) == 1;
Since tx_q->cur_tx may wrap around and become smaller than first_entry,
the following statement is more concise:
is_last_segment = (tx_q->cur_tx == first_entry);
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help