Re: [PATCH net-next v3 1/6] net: bcmgenet: convert RX path to page_pool

Nicolai Buchwitz
2026-03-30T21:03:17Z

On 30.3.2026 20:15, Mohsin Bashir wrote:
>> if (priv->crc_fwd_en) {
>> - skb_trim(skb, len - ETH_FCS_LEN);
>> + skb_trim(skb, skb->len - ETH_FCS_LEN);
>> len -= ETH_FCS_LEN;
>
> Looks like 'len' update here is unnecessary since we are overwriting it
> later anyway?

Good catch, the len = skb->len assignment added in this patch makes len
-= ETH_FCS_LEN dead code since skb_trim already removed the FCS. Will
fix in v6.

Thanks
Nicolai

>
>> }
>> + /* Set up checksum offload */
>> + if (dev->features & NETIF_F_RXCSUM) {
>> + rx_csum = (__force __be16)(status->rx_csum & 0xffff);
>> + if (rx_csum) {
>> + skb->csum = (__force __wsum)ntohs(rx_csum);
>> + skb->ip_summed = CHECKSUM_COMPLETE;
>> + }
>> + }
>> +
>> + len = skb->len;