[PATCH net-next 02/15] net: stmmac: helpers for filling tx_q->tx_skbuff_dma
Andrew Lunn
andrew at lunn.ch
Wed Mar 11 07:57:13 PDT 2026
On Wed, Mar 11, 2026 at 09:52:14AM +0000, Russell King (Oracle) wrote:
> Add helpers to fill in the transmit queue metadata to ensure that all
> entries are initialised when preparing to transmit. This avoids clean
> up code running into surprises.
>
> For example, stmmac_clean_desc3() (which calls clean_desc3() in
> chain_mode.c or ring_mode.c) looks at the .last_segment, and in the
> latter case, .is_jumbo members.
>
> stmmac_tso_xmit() was also a problem. If the metadata is not fully
> cleared when cleaning dirty entries (or, in the case of resume,
> freeing all entries) then .last_segment may be left set, which then
> causes:
>
> stmmac_prepare_tso_tx_desc(priv, first, 1, proto_hdr_len, 0, 1,
> tx_q->tx_skbuff_dma[first_entry].last_segment+,
> hdr / 4, (skb->len - proto_hdr_len));
>
> to mark the
That sentence appear to be unfinished.
Andrew
More information about the linux-arm-kernel
mailing list