* [PATCH] tcp: fix regression in urgent data handling
@ 2012-09-17 22:51 Eric Dumazet
2012-09-18 7:54 ` [PATCH v2] " Eric Dumazet
2012-09-18 20:26 ` [PATCH] " David Miller
0 siblings, 2 replies; 4+ messages in thread
From: Eric Dumazet @ 2012-09-17 22:51 UTC (permalink / raw)
To: David Miller; +Cc: netdev, Stephan Springl, Alexander Duyck
From: Eric Dumazet <edumazet@google.com>
Stephan Springl found that commit 1402d366019fed "tcp: introduce
tcp_try_coalesce" introduced a regression for rlogin
It turns out problem comes from TCP urgent data handling and
a change in behavior in input path.
rlogin sends two one-byte packets with URG ptr set, and when next data
frame is coalesced, we lack sk_data_ready() calls to wakeup consumer.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Stephan Springl <springl-k@lar.bfw.de>
Cc: Alexander Duyck <alexander.h.duyck@intel.com>
---
net/ipv4/tcp_input.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
index 6e38c6c..d377f48 100644
--- a/net/ipv4/tcp_input.c
+++ b/net/ipv4/tcp_input.c
@@ -4661,7 +4661,7 @@ queue_and_out:
if (eaten > 0)
kfree_skb_partial(skb, fragstolen);
- else if (!sock_flag(sk, SOCK_DEAD))
+ if (!sock_flag(sk, SOCK_DEAD))
sk->sk_data_ready(sk, 0);
return;
}
@@ -5556,8 +5556,7 @@ no_ack:
#endif
if (eaten)
kfree_skb_partial(skb, fragstolen);
- else
- sk->sk_data_ready(sk, 0);
+ sk->sk_data_ready(sk, 0);
return 0;
}
}
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH v2] tcp: fix regression in urgent data handling
2012-09-17 22:51 [PATCH] tcp: fix regression in urgent data handling Eric Dumazet
@ 2012-09-18 7:54 ` Eric Dumazet
2012-09-18 8:00 ` Stephan Springl
2012-09-18 20:26 ` [PATCH] " David Miller
1 sibling, 1 reply; 4+ messages in thread
From: Eric Dumazet @ 2012-09-18 7:54 UTC (permalink / raw)
To: David Miller; +Cc: netdev, Stephan Springl, Alexander Duyck
From: Eric Dumazet <edumazet@google.com>
Stephan Springl found that commit 1402d366019fed "tcp: introduce
tcp_try_coalesce" introduced a regression for rlogin
It turns out problem comes from TCP urgent data handling and
a change in behavior in input path.
rlogin sends two one-byte packets with URG ptr set, and when next data
frame is coalesced, we lack sk_data_ready() calls to wakeup consumer.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Stephan Springl <springl-k@bfw-online.de>
Cc: Alexander Duyck <alexander.h.duyck@intel.com>
---
v2: Changed Stephan Springl email address in changelog/CC
net/ipv4/tcp_input.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
index 6e38c6c..d377f48 100644
--- a/net/ipv4/tcp_input.c
+++ b/net/ipv4/tcp_input.c
@@ -4661,7 +4661,7 @@ queue_and_out:
if (eaten > 0)
kfree_skb_partial(skb, fragstolen);
- else if (!sock_flag(sk, SOCK_DEAD))
+ if (!sock_flag(sk, SOCK_DEAD))
sk->sk_data_ready(sk, 0);
return;
}
@@ -5556,8 +5556,7 @@ no_ack:
#endif
if (eaten)
kfree_skb_partial(skb, fragstolen);
- else
- sk->sk_data_ready(sk, 0);
+ sk->sk_data_ready(sk, 0);
return 0;
}
}
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v2] tcp: fix regression in urgent data handling
2012-09-18 7:54 ` [PATCH v2] " Eric Dumazet
@ 2012-09-18 8:00 ` Stephan Springl
0 siblings, 0 replies; 4+ messages in thread
From: Stephan Springl @ 2012-09-18 8:00 UTC (permalink / raw)
To: Eric Dumazet; +Cc: David Miller, netdev, Alexander Duyck
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1980 bytes --]
Works here on top of 3.5.4, so
Tested-by: Stephan Springl <springl-k@bfw-online.de>
On Tue, 18 Sep 2012, Eric Dumazet wrote:
> From: Eric Dumazet <edumazet@google.com>
>
> Stephan Springl found that commit 1402d366019fed "tcp: introduce
> tcp_try_coalesce" introduced a regression for rlogin
>
> It turns out problem comes from TCP urgent data handling and
> a change in behavior in input path.
>
> rlogin sends two one-byte packets with URG ptr set, and when next data
> frame is coalesced, we lack sk_data_ready() calls to wakeup consumer.
>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> Reported-by: Stephan Springl <springl-k@bfw-online.de>
> Cc: Alexander Duyck <alexander.h.duyck@intel.com>
> ---
> v2: Changed Stephan Springl email address in changelog/CC
>
> net/ipv4/tcp_input.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
> index 6e38c6c..d377f48 100644
> --- a/net/ipv4/tcp_input.c
> +++ b/net/ipv4/tcp_input.c
> @@ -4661,7 +4661,7 @@ queue_and_out:
>
> if (eaten > 0)
> kfree_skb_partial(skb, fragstolen);
> - else if (!sock_flag(sk, SOCK_DEAD))
> + if (!sock_flag(sk, SOCK_DEAD))
> sk->sk_data_ready(sk, 0);
> return;
> }
> @@ -5556,8 +5556,7 @@ no_ack:
> #endif
> if (eaten)
> kfree_skb_partial(skb, fragstolen);
> - else
> - sk->sk_data_ready(sk, 0);
> + sk->sk_data_ready(sk, 0);
> return 0;
> }
> }
>
>
>
Freundliche Grüße
BFW Werner Völk GmbH
ppa. Stephan Springl
--
Stephan Springl BFW Werner Völk GmbH
Tel.: +49 89 82917-452 Energiemesstechnik & Service
Fax: +49 89 82917-599 Pasinger Str. 20 - 22
Mail: springl@bfw-online.de D-82166 Gräfelfing
Web: http://www.novamess.de Geschäftsführer: Georg F. Völk
HRB 44779 Amtsgericht München
USt.-ID: DE129301566
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] tcp: fix regression in urgent data handling
2012-09-17 22:51 [PATCH] tcp: fix regression in urgent data handling Eric Dumazet
2012-09-18 7:54 ` [PATCH v2] " Eric Dumazet
@ 2012-09-18 20:26 ` David Miller
1 sibling, 0 replies; 4+ messages in thread
From: David Miller @ 2012-09-18 20:26 UTC (permalink / raw)
To: eric.dumazet; +Cc: netdev, springl-k, alexander.h.duyck
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Tue, 18 Sep 2012 00:51:39 +0200
> From: Eric Dumazet <edumazet@google.com>
>
> Stephan Springl found that commit 1402d366019fed "tcp: introduce
> tcp_try_coalesce" introduced a regression for rlogin
>
> It turns out problem comes from TCP urgent data handling and
> a change in behavior in input path.
>
> rlogin sends two one-byte packets with URG ptr set, and when next data
> frame is coalesced, we lack sk_data_ready() calls to wakeup consumer.
>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> Reported-by: Stephan Springl <springl-k@lar.bfw.de>
> Cc: Alexander Duyck <alexander.h.duyck@intel.com>
Applied, thanks Eric.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-09-18 20:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-17 22:51 [PATCH] tcp: fix regression in urgent data handling Eric Dumazet
2012-09-18 7:54 ` [PATCH v2] " Eric Dumazet
2012-09-18 8:00 ` Stephan Springl
2012-09-18 20:26 ` [PATCH] " David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).