All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net] net/tls: Fix connection stall on partial tls record
@ 2018-05-07  2:24 Andre Tomt
  2018-05-08  3:49 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Andre Tomt @ 2018-05-07  2:24 UTC (permalink / raw)
  To: David S . Miller, netdev, borisp, Aviad Yehezkel, Dave Watson; +Cc: Andre Tomt

In the case of writing a partial tls record we forgot to clear the
ctx->in_tcp_sendpages flag, causing some connections to stall.

Fixes: c212d2c7fc47 ("net/tls: Don't recursively call push_record during tls_write_space callbacks")
Signed-off-by: Andre Tomt <andre@tomt.net>
---
 net/tls/tls_main.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/tls/tls_main.c b/net/tls/tls_main.c
index cc03e00785c7..a02ebdfa0675 100644
--- a/net/tls/tls_main.c
+++ b/net/tls/tls_main.c
@@ -135,6 +135,7 @@ int tls_push_sg(struct sock *sk,
 			offset -= sg->offset;
 			ctx->partially_sent_offset = offset;
 			ctx->partially_sent_record = (void *)sg;
+			ctx->in_tcp_sendpages = false;
 			return ret;
 		}
 
-- 
2.17.0

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

* Re: [PATCH net] net/tls: Fix connection stall on partial tls record
  2018-05-07  2:24 [PATCH net] net/tls: Fix connection stall on partial tls record Andre Tomt
@ 2018-05-08  3:49 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2018-05-08  3:49 UTC (permalink / raw)
  To: andre; +Cc: netdev, borisp, aviadye, davejwatson

From: Andre Tomt <andre@tomt.net>
Date: Mon,  7 May 2018 04:24:39 +0200

> In the case of writing a partial tls record we forgot to clear the
> ctx->in_tcp_sendpages flag, causing some connections to stall.
> 
> Fixes: c212d2c7fc47 ("net/tls: Don't recursively call push_record during tls_write_space callbacks")
> Signed-off-by: Andre Tomt <andre@tomt.net>

Applied, thanks Andre.

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

end of thread, other threads:[~2018-05-08  3:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-07  2:24 [PATCH net] net/tls: Fix connection stall on partial tls record Andre Tomt
2018-05-08  3:49 ` 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.