summaryrefslogtreecommitdiffstats
path: root/net/ipv6/tcp_ipv6.c
diff options
context:
space:
mode:
authorDavid S. Miller2016-08-30 06:54:02 +0200
committerDavid S. Miller2016-08-30 06:54:02 +0200
commit6abdd5f5935fff978f950561f3c5175eb34dad73 (patch)
tree6f3ed3a4f4af9e74436ec9355ebf8201357f1c40 /net/ipv6/tcp_ipv6.c
parentnet_sched: fix use of uninitialized ethertype variable in cls_flower (diff)
parentMerge tag 'hwmon-for-linus-v4.8-rc5' of git://git.kernel.org/pub/scm/linux/ke... (diff)
downloadkernel-qcow2-linux-6abdd5f5935fff978f950561f3c5175eb34dad73.tar.gz
kernel-qcow2-linux-6abdd5f5935fff978f950561f3c5175eb34dad73.tar.xz
kernel-qcow2-linux-6abdd5f5935fff978f950561f3c5175eb34dad73.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
All three conflicts were cases of simple overlapping changes. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
-rw-r--r--net/ipv6/tcp_ipv6.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
index 5bf460bd299f..04529a3d42cb 100644
--- a/net/ipv6/tcp_ipv6.c
+++ b/net/ipv6/tcp_ipv6.c
@@ -945,9 +945,15 @@ static void tcp_v6_reqsk_send_ack(const struct sock *sk, struct sk_buff *skb,
/* sk->sk_state == TCP_LISTEN -> for regular TCP_SYN_RECV
* sk->sk_state == TCP_SYN_RECV -> for Fast Open.
*/
+ /* RFC 7323 2.3
+ * The window field (SEG.WND) of every outgoing segment, with the
+ * exception of <SYN> segments, MUST be right-shifted by
+ * Rcv.Wind.Shift bits:
+ */
tcp_v6_send_ack(sk, skb, (sk->sk_state == TCP_LISTEN) ?
tcp_rsk(req)->snt_isn + 1 : tcp_sk(sk)->snd_nxt,
- tcp_rsk(req)->rcv_nxt, req->rsk_rcv_wnd,
+ tcp_rsk(req)->rcv_nxt,
+ req->rsk_rcv_wnd >> inet_rsk(req)->rcv_wscale,
tcp_time_stamp, req->ts_recent, sk->sk_bound_dev_if,
tcp_v6_md5_do_lookup(sk, &ipv6_hdr(skb)->daddr),
0, 0);