Commit 53eed8aa authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

revert "net: account for current skb length when deciding about UFO"

This reverts commit ef09c9ff which is
commit a5cb659b upstream as it causes
merge issues with later patches that are much more important...

Cc: Michal Kubecek <mkubecek@suse.cz>
Cc: Vlad Yasevich <vyasevic@redhat.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e5841355
...@@ -936,8 +936,7 @@ static int __ip_append_data(struct sock *sk, ...@@ -936,8 +936,7 @@ static int __ip_append_data(struct sock *sk,
csummode = CHECKSUM_PARTIAL; csummode = CHECKSUM_PARTIAL;
cork->length += length; cork->length += length;
if ((((length + (skb ? skb->len : fragheaderlen)) > mtu) || if ((((length + fragheaderlen) > mtu) || (skb && skb_is_gso(skb))) &&
(skb && skb_is_gso(skb))) &&
(sk->sk_protocol == IPPROTO_UDP) && (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) && !sk->sk_no_check_tx) { (sk->sk_type == SOCK_DGRAM) && !sk->sk_no_check_tx) {
......
...@@ -1372,7 +1372,7 @@ static int __ip6_append_data(struct sock *sk, ...@@ -1372,7 +1372,7 @@ static int __ip6_append_data(struct sock *sk,
*/ */
cork->length += length; cork->length += length;
if ((((length + (skb ? skb->len : headersize)) > mtu) || if ((((length + fragheaderlen) > mtu) ||
(skb && skb_is_gso(skb))) && (skb && skb_is_gso(skb))) &&
(sk->sk_protocol == IPPROTO_UDP) && (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 &&
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment