Skip to contentSkip to conversation

idpf: fix handling rsc packet with a single segment

PATCH In review Samudrala, Sridhar 2 participants 2 messages Jan 10, 2025 – Jan 27, 2025

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 idpf: fix handling rsc packet with a single segment

Handle rsc packet with a single segment same as a multi segment rsc packet so that CHECKSUM_PARTIAL is set in the skb->ip_summed field. The current code is passing CHECKSUM_NONE resulting in TCP GRO layer doing checksum in SW and hiding the issue. This will fail when using dmabufs as payload buffers as skb frag would be unreadable.

Fixes 3a8845af66ed ("idpf: add RX splitq napi poll support")
---
 drivers/net/ethernet/intel/idpf/idpf_txrx.c | 2 --
 1 file changed, 2 deletions(-)
drivers/net/ethernet/intel/idpf/idpf_txrx.c +0 -2
index 2fa9c36e33c9..c9fcf8f4d736 100644
@@ -3008,8 +3008,6 @@ static int idpf_rx_rsc(struct idpf_rx_queue *rxq, struct sk_buff *skb,
 		return -EINVAL;
 
 	rsc_segments = DIV_ROUND_UP(skb->data_len, rsc_seg_len);
-	if (unlikely(rsc_segments == 1))
-		return 0;
 
 	NAPI_GRO_CB(skb)->count = rsc_segments;
 	skb_shinfo(skb)->gso_size = rsc_seg_len;
Signature · 1 line
2.46.2
Tested-by on v1 1/1
#1 lore raw
Quoted 17 lines

-----Original Message-----
From: Intel-wired-lan <[email protected]> On Behalf Of Samudrala, Sridhar
Sent: Friday, January 10, 2025 4:29 PM
To: [email protected]; [email protected]
Cc: Samudrala, Sridhar <[email protected]>; Kitszel, Przemyslaw <[email protected]>
Subject: [Intel-wired-lan] [PATCH iwl-net] idpf: fix handling rsc packet with a single segment

Handle rsc packet with a single segment same as a multi segment rsc packet so that CHECKSUM_PARTIAL is set in the
skb->ip_summed field. The current code is passing CHECKSUM_NONE resulting in TCP GRO layer doing checksum in SW and hiding the issue. This will fail when using dmabufs as payload buffers as skb frag would be unreadable.

Quoted 3 lines
Fixes 3a8845af66ed ("idpf: add RX splitq napi poll support")