diff options
author | Olof Johansson <olof@lixom.net> | 2015-04-03 20:20:42 (GMT) |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2015-04-03 20:20:42 (GMT) |
commit | 5602d12a861340e9ed2c17cdefc500fa12b52446 (patch) | |
tree | 2d2776ce7d159a3381b54034e51d36eb7007e50e /net/ipv4 | |
parent | 0a47acfa16a5043f5fad562abb8e3e4b53367a43 (diff) | |
parent | 27842bb18b004a2802f4b3221c79ce638c4bf6ee (diff) | |
download | linux-5602d12a861340e9ed2c17cdefc500fa12b52446.tar.xz |
Merge tag 'qcom-cleanup-for-4.1' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/linux-qcom into next/cleanup
Merge "qcom cleanup changes for 4.1" from Kumar Gala:
General cleanups for MSM/QCOM for 4.1
* Removal of mach-msm and associated drivers cleanups that have been
ack'd by associated maintainers
* tag 'qcom-cleanup-for-4.1' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/linux-qcom:
mmc: Remove msm_sdcc driver
gpio: Remove gpio-msm-v1 driver
ARM: Remove mach-msm and associated ARM architecture code
+ Linux 4.0-rc3
Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/ip_fragment.c | 2 | ||||
-rw-r--r-- | net/ipv4/ip_output.c | 3 | ||||
-rw-r--r-- | net/ipv4/tcp_input.c | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/net/ipv4/ip_fragment.c b/net/ipv4/ip_fragment.c index e5b6d0d..2c8d98e 100644 --- a/net/ipv4/ip_fragment.c +++ b/net/ipv4/ip_fragment.c @@ -664,7 +664,7 @@ struct sk_buff *ip_check_defrag(struct sk_buff *skb, u32 user) if (skb->protocol != htons(ETH_P_IP)) return skb; - if (!skb_copy_bits(skb, 0, &iph, sizeof(iph))) + if (skb_copy_bits(skb, 0, &iph, sizeof(iph)) < 0) return skb; if (iph.ihl < 5 || iph.version != 4) diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c index d68199d..a7aea20 100644 --- a/net/ipv4/ip_output.c +++ b/net/ipv4/ip_output.c @@ -888,7 +888,8 @@ static int __ip_append_data(struct sock *sk, cork->length += length; if (((length > mtu) || (skb && skb_is_gso(skb))) && (sk->sk_protocol == IPPROTO_UDP) && - (rt->dst.dev->features & NETIF_F_UFO) && !rt->dst.header_len) { + (rt->dst.dev->features & NETIF_F_UFO) && !rt->dst.header_len && + (sk->sk_type == SOCK_DGRAM)) { err = ip_ufo_append_data(sk, queue, getfrag, from, length, hh_len, fragheaderlen, transhdrlen, maxfraglen, flags); diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 8fdd27b..fb4cf8b 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c @@ -4770,7 +4770,7 @@ static bool tcp_should_expand_sndbuf(const struct sock *sk) return false; /* If we filled the congestion window, do not expand. */ - if (tp->packets_out >= tp->snd_cwnd) + if (tcp_packets_in_flight(tp) >= tp->snd_cwnd) return false; return true; |