android_kernel_asus_sm8350/net
Jiri Bohac 09c6629531 Revert "xfrm: xfrm_state_mtu should return at least 1280 for ipv6"
This reverts commit b515d2637276a3810d6595e10ab02c13bfd0b63a.

Commit b515d2637276a3810d6595e10ab02c13bfd0b63a ("xfrm: xfrm_state_mtu
should return at least 1280 for ipv6") in v5.14 breaks the TCP MSS
calculation in ipsec transport mode, resulting complete stalls of TCP
connections. This happens when the (P)MTU is 1280 or slighly larger.

The desired formula for the MSS is:
MSS = (MTU - ESP_overhead) - IP header - TCP header

However, the above commit clamps the (MTU - ESP_overhead) to a
minimum of 1280, turning the formula into
MSS = max(MTU - ESP overhead, 1280) -  IP header - TCP header

With the (P)MTU near 1280, the calculated MSS is too large and the
resulting TCP packets never make it to the destination because they
are over the actual PMTU.

The above commit also causes suboptimal double fragmentation in
xfrm tunnel mode, as described in
https://lore.kernel.org/netdev/20210429202529.codhwpc7w6kbudug@dwarf.suse.cz/

The original problem the above commit was trying to fix is now fixed
by commit 6596a0229541270fb8d38d989f91b78838e5e9da ("xfrm: fix MTU
regression").

Change-Id: Iefabad76eb1870f74b819f45e9d3a51cbc94549c
Signed-off-by: Jiri Bohac <jbohac@suse.cz>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Git-commit: a6d95c5a628a09be129f25d5663a7e9db8261f51
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git
Signed-off-by: Sharath Chandra Vurukala<quic_sharathv@quicinc.com>
2022-03-12 15:15:37 +05:30
..
6lowpan 6lowpan: iphc: Fix an off-by-one check of array index 2021-09-15 09:47:31 +02:00
9p 9p/net: fix missing error check in p9_check_errors 2021-11-17 09:48:49 +01:00
802 net/802/garp: fix memleak in garp_request_join() 2021-07-31 08:19:38 +02:00
8021q net: vlan: fix a UAF in vlan_dev_real_dev() 2021-11-17 09:48:47 +01:00
appletalk appletalk: Fix skb allocation size in loopback case 2021-04-07 14:47:41 +02:00
atm atm: fix a memory leak of vcc->user_back 2020-10-01 13:17:58 +02:00
ax25 AX.25: Prevent integer overflows in connect and sendmsg 2020-07-31 18:39:31 +02:00
batman-adv net: batman-adv: fix error handling 2021-11-02 19:46:14 +01:00
bluetooth Bluetooth: fix init and cleanup of sco_conn.timeout_work 2021-11-17 09:48:33 +01:00
bpf
bpfilter bpfilter: Specify the log level for the kmsg message 2021-07-14 16:53:33 +02:00
bridge Merge android11-5.4.161+ (b9d179c) into msm-5.4 2022-02-07 22:29:21 +05:30
caif This is the 5.4.148 stable release 2021-09-25 14:41:58 +02:00
can This is the 5.4.160 stable release 2021-11-17 10:19:21 +01:00
ceph libceph: clear con->out_msg on Policy::stateful_server faults 2020-11-05 11:43:34 +01:00
core Merge android11-5.4.161+ (5d7a491) into msm-5.4 2022-03-01 10:32:54 +05:30
dcb net: dcb: Accept RTM_GETDCB messages carrying set-like DCB commands 2021-01-23 15:57:59 +01:00
dccp dccp: don't duplicate ccid when cloning dccp sock 2021-09-22 12:26:40 +02:00
decnet net: decnet: Fix sleeping inside in af_decnet 2021-07-28 13:30:56 +02:00
dns_resolver
dsa net: dsa: destroy the phylink instance on any error in dsa_slave_phy_setup 2021-09-22 12:26:42 +02:00
embms_kernel net/embms-kernel : EMBMS Tunneling Module 2020-10-16 18:23:27 +05:30
ethernet
hsr hsr: use netdev_err() instead of WARN_ONCE() 2021-05-14 09:44:10 +02:00
ieee802154 net: Fix memory leak in ieee802154_raw_deliver 2021-08-18 08:57:00 +02:00
ife
ipv4 Revert "xfrm: xfrm_state_mtu should return at least 1280 for ipv6" 2022-03-12 15:15:37 +05:30
ipv6 Revert "xfrm: xfrm_state_mtu should return at least 1280 for ipv6" 2022-03-12 15:15:37 +05:30
iucv net/af_iucv: remove WARN_ONCE on malformed RX packets 2021-03-07 12:20:42 +01:00
kcm
key af_key: relax availability checks for skb size calculation 2021-02-13 13:52:54 +01:00
l2tp net/l2tp: Fix reference count leak in l2tp_udp_recv_core 2021-09-22 12:26:41 +02:00
l3mdev
lapb net: lapb: Copy the skb before sending a packet 2021-02-10 09:25:28 +01:00
llc net: llc: fix skb_over_panic 2021-08-04 12:27:39 +02:00
mac80211 Merge android11-5.4.161+ (b9d179c) into msm-5.4 2022-02-07 22:29:21 +05:30
mac802154 net: mac802154: Fix general protection fault 2021-04-14 08:24:18 +02:00
mpls net: avoid infinite loop in mpls_gso_segment when mpls_hlen == 0 2021-03-17 17:03:31 +01:00
ncsi net/ncsi: Avoid channel_monitor hrtimer deadlock 2021-04-14 08:24:15 +02:00
netfilter Merge android11-5.4.161+ (b9d179c) into msm-5.4 2022-02-07 22:29:21 +05:30
netlabel net: fix NULL pointer reference in cipso_v4_doi_free 2021-09-22 12:26:36 +02:00
netlink netlink: annotate data races around nlk->bound 2021-10-13 10:08:19 +02:00
netrom netrom: Decrease sock refcount when sock timers expire 2021-07-28 13:30:56 +02:00
neuron net: neuron: channel: Move waitq init 2021-01-29 13:15:21 -08:00
nfc nfc: nci: fix the UAF of rf_conn_info object 2021-10-27 09:54:28 +02:00
nsh
openvswitch ovs: clear skb->tstamp in forwarding path 2021-08-26 08:36:19 -04:00
packet net/packet: annotate accesses to po->ifindex 2021-06-30 08:47:48 -04:00
phonet
psample
qrtr Merge android11-5.4.147+ (dc8c919) into msm-5.4 2021-11-05 17:27:33 +05:30
rds net/rds: dma_map_sg is entitled to merge entries 2021-09-03 10:08:15 +02:00
rfkill rfkill: Fix use-after-free in rfkill_resume() 2020-11-24 13:29:05 +01:00
rose rose: Fix Null pointer dereference in rose_send_frame() 2020-12-08 10:40:23 +01:00
rxrpc rxrpc: Fix _usecs_to_jiffies() by using usecs_to_jiffies() 2021-11-17 09:48:34 +01:00
sched Revert "net: sched: update default qdisc visibility after Tx queue cnt changes" 2021-11-19 13:42:39 +01:00
sctp This is the 5.4.157 stable release 2021-11-02 20:04:52 +01:00
smc net/smc: fix sk_refcnt underflow on linkdown and fallback 2021-11-17 09:48:48 +01:00
strparser bpf: sockmap, strparser, and tls are reusing qdisc_skb_cb and colliding 2021-11-17 09:48:48 +01:00
sunrpc SUNRPC: Partial revert of commit 6f9f17287e78 2021-11-17 09:48:50 +01:00
switchdev net: switchdev: do not propagate bridge updates across bridges 2021-10-27 09:54:24 +02:00
tipc UPSTREAM: tipc: improve size validations for received domain records 2022-02-11 12:14:30 +00:00
tls net/tls: Fix flipped sign in async_wait.err assignment 2021-11-02 19:46:14 +01:00
unix af_unix: fix races in sk_peer_pid and sk_peer_cred accesses 2021-10-06 15:42:35 +02:00
vmw_vsock This is the 5.4.160 stable release 2021-11-17 10:19:21 +01:00
wimax
wireless Merge android11-5.4.161+ (b9d179c) into msm-5.4 2022-02-07 22:29:21 +05:30
x25 net/x25: Return the correct errno code 2021-06-18 09:59:00 +02:00
xdp xsk: Simplify detection of empty and full rings 2021-05-22 11:38:27 +02:00
xfrm Revert "xfrm: xfrm_state_mtu should return at least 1280 for ipv6" 2022-03-12 15:15:37 +05:30
compat.c net: Return the correct errno code 2021-06-18 09:59:00 +02:00
Kconfig net: Kernel changes for Generic Software Bridge(GSB) 2021-02-14 20:36:58 -08:00
Makefile
OWNERS ANDROID: Add OWNERS files referring to the respective android-mainline OWNERS 2021-04-01 13:45:14 +00:00
socket.c This is the 5.4.144 stable release 2021-09-03 10:17:46 +02:00
sysctl_net.c