All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] bnx2x: record rx queue for LRO packets
@ 2013-10-12 21:08 Eric Dumazet
  2013-10-13  6:23 ` Dmitry Kravkov
  0 siblings, 1 reply; 3+ messages in thread
From: Eric Dumazet @ 2013-10-12 21:08 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, Eilon Greenstein, Willem de Bruijn

From: Eric Dumazet <edumazet@google.com>

RPS support is kind of broken on bnx2x, because only non LRO packets
get proper rx queue information. This triggers reorders, as it seems
bnx2x like to generate a non LRO packet for segment including TCP PUSH
flag : (this might be pure coincidence, but all the reorders I've
seen involve segments with a PUSH)

11:13:34.335847 IP A > B: . 415808:447136(31328) ack 1 win 457 <nop,nop,timestamp 3789336 3985797>
11:13:34.335992 IP A > B: . 447136:448560(1424) ack 1 win 457 <nop,nop,timestamp 3789336 3985797>
11:13:34.336391 IP A > B: . 448560:479888(31328) ack 1 win 457 <nop,nop,timestamp 3789337 3985797>
11:13:34.336425 IP A > B: P 511216:512640(1424) ack 1 win 457 <nop,nop,timestamp 3789337 3985798>
11:13:34.336423 IP A > B: . 479888:511216(31328) ack 1 win 457 <nop,nop,timestamp 3789337 3985798>
11:13:34.336924 IP A > B: . 512640:543968(31328) ack 1 win 457 <nop,nop,timestamp 3789337 3985798>
11:13:34.336963 IP A > B: . 543968:575296(31328) ack 1 win 457 <nop,nop,timestamp 3789337 3985798>

We must call skb_record_rx_queue() to properly give to RPS (and more
generally for TX queue selection on forward path) the receive queue
information.

Similar fix is needed for skb_mark_napi_id(), but will be handled
in a separate patch to ease stable backports.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Willem de Bruijn <willemb@google.com>
Cc: Eilon Greenstein <eilong@broadcom.com>
---
 drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
index 0c64122..6e46cff 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
@@ -681,6 +681,7 @@ static void bnx2x_gro_receive(struct bnx2x *bp, struct bnx2x_fastpath *fp,
 		}
 	}
 #endif
+	skb_record_rx_queue(skb, fp->rx_queue);
 	napi_gro_receive(&fp->napi, skb);
 }
 

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [PATCH] bnx2x: record rx queue for LRO packets
  2013-10-12 21:08 [PATCH] bnx2x: record rx queue for LRO packets Eric Dumazet
@ 2013-10-13  6:23 ` Dmitry Kravkov
  2013-10-17 19:43   ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Kravkov @ 2013-10-13  6:23 UTC (permalink / raw)
  To: Eric Dumazet, David Miller; +Cc: netdev, Eilon Greenstein, Willem de Bruijn

> -----Original Message-----
> From: netdev-owner@vger.kernel.org [mailto:netdev-
> owner@vger.kernel.org] On Behalf Of Eric Dumazet
> Sent: Sunday, October 13, 2013 12:09 AM
> To: David Miller
> Cc: netdev; Eilon Greenstein; Willem de Bruijn
> Subject: [PATCH] bnx2x: record rx queue for LRO packets
> 
> From: Eric Dumazet <edumazet@google.com>
> 
> RPS support is kind of broken on bnx2x, because only non LRO packets get
> proper rx queue information. This triggers reorders, as it seems bnx2x like to
> generate a non LRO packet for segment including TCP PUSH flag : (this might
> be pure coincidence, but all the reorders I've seen involve segments with a
> PUSH)
> 
> 11:13:34.335847 IP A > B: . 415808:447136(31328) ack 1 win 457
> <nop,nop,timestamp 3789336 3985797>
> 11:13:34.335992 IP A > B: . 447136:448560(1424) ack 1 win 457
> <nop,nop,timestamp 3789336 3985797>
> 11:13:34.336391 IP A > B: . 448560:479888(31328) ack 1 win 457
> <nop,nop,timestamp 3789337 3985797>
> 11:13:34.336425 IP A > B: P 511216:512640(1424) ack 1 win 457
> <nop,nop,timestamp 3789337 3985798>
> 11:13:34.336423 IP A > B: . 479888:511216(31328) ack 1 win 457
> <nop,nop,timestamp 3789337 3985798>
> 11:13:34.336924 IP A > B: . 512640:543968(31328) ack 1 win 457
> <nop,nop,timestamp 3789337 3985798>
> 11:13:34.336963 IP A > B: . 543968:575296(31328) ack 1 win 457
> <nop,nop,timestamp 3789337 3985798>
> 
> We must call skb_record_rx_queue() to properly give to RPS (and more
> generally for TX queue selection on forward path) the receive queue
> information.
> 
> Similar fix is needed for skb_mark_napi_id(), but will be handled in a
> separate patch to ease stable backports.
> 
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> Cc: Willem de Bruijn <willemb@google.com>
> Cc: Eilon Greenstein <eilong@broadcom.com>
> ---
>  drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c |    1 +
>  1 file changed, 1 insertion(+)


Thanks!

Acked-by: Dmitry Kravkov <dmitry@broadcom.com>


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] bnx2x: record rx queue for LRO packets
  2013-10-13  6:23 ` Dmitry Kravkov
@ 2013-10-17 19:43   ` David Miller
  0 siblings, 0 replies; 3+ messages in thread
From: David Miller @ 2013-10-17 19:43 UTC (permalink / raw)
  To: dmitry; +Cc: eric.dumazet, netdev, eilong, willemb

From: "Dmitry Kravkov" <dmitry@broadcom.com>
Date: Sun, 13 Oct 2013 06:23:31 +0000

>> -----Original Message-----
>> From: netdev-owner@vger.kernel.org [mailto:netdev-
>> owner@vger.kernel.org] On Behalf Of Eric Dumazet
>> Sent: Sunday, October 13, 2013 12:09 AM
>> To: David Miller
>> Cc: netdev; Eilon Greenstein; Willem de Bruijn
>> Subject: [PATCH] bnx2x: record rx queue for LRO packets
>> 
>> From: Eric Dumazet <edumazet@google.com>
>> 
>> RPS support is kind of broken on bnx2x, because only non LRO packets get
>> proper rx queue information. This triggers reorders, as it seems bnx2x like to
>> generate a non LRO packet for segment including TCP PUSH flag : (this might
>> be pure coincidence, but all the reorders I've seen involve segments with a
>> PUSH)
>> 
>> 11:13:34.335847 IP A > B: . 415808:447136(31328) ack 1 win 457
>> <nop,nop,timestamp 3789336 3985797>
>> 11:13:34.335992 IP A > B: . 447136:448560(1424) ack 1 win 457
>> <nop,nop,timestamp 3789336 3985797>
>> 11:13:34.336391 IP A > B: . 448560:479888(31328) ack 1 win 457
>> <nop,nop,timestamp 3789337 3985797>
>> 11:13:34.336425 IP A > B: P 511216:512640(1424) ack 1 win 457
>> <nop,nop,timestamp 3789337 3985798>
>> 11:13:34.336423 IP A > B: . 479888:511216(31328) ack 1 win 457
>> <nop,nop,timestamp 3789337 3985798>
>> 11:13:34.336924 IP A > B: . 512640:543968(31328) ack 1 win 457
>> <nop,nop,timestamp 3789337 3985798>
>> 11:13:34.336963 IP A > B: . 543968:575296(31328) ack 1 win 457
>> <nop,nop,timestamp 3789337 3985798>
>> 
>> We must call skb_record_rx_queue() to properly give to RPS (and more
>> generally for TX queue selection on forward path) the receive queue
>> information.
>> 
>> Similar fix is needed for skb_mark_napi_id(), but will be handled in a
>> separate patch to ease stable backports.
>> 
>> Signed-off-by: Eric Dumazet <edumazet@google.com>
 ...
> Acked-by: Dmitry Kravkov <dmitry@broadcom.com>
> 

Applied, thanks everyone.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-10-17 19:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-12 21:08 [PATCH] bnx2x: record rx queue for LRO packets Eric Dumazet
2013-10-13  6:23 ` Dmitry Kravkov
2013-10-17 19:43   ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.