linux-stable/net/mptcp
Geliang Tang 208e8f6692 mptcp: receive checksum for MP_CAPABLE with data
This patch added a new member named csum in struct mptcp_options_received.

When parsing the MP_CAPABLE with data, if the checksum is enabled,
adjust the expected_opsize. If the receiving option length matches the
length with the data checksum, get the checksum value and save it in
mp_opt->csum. And in mptcp_incoming_options, pass it to mpext->csum.

We always parse any csum/nocsum combination and delay the presence check
to later code, to allow reset if missing.

Additionally, in the TX path, use the newly introduce ext field to avoid
MPTCP csum recomputation on TCP retransmission and unneeded csum update
on when setting the data fin_flag.

Co-developed-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2021-06-18 11:40:11 -07:00
..
crypto.c kunit: mptcp: adhere to KUNIT formatting standard 2021-04-16 17:10:40 -07:00
crypto_test.c mptcp: move crypto test to KUNIT 2020-06-26 16:21:39 -07:00
ctrl.c mptcp: restrict values of 'enabled' sysctl 2021-05-28 13:59:16 -07:00
diag.c mptcp: allow dumping subflow context to userspace 2020-03-29 22:14:48 -07:00
Kconfig kunit: mptcp: adhere to KUNIT formatting standard 2021-04-16 17:10:40 -07:00
Makefile kunit: mptcp: adhere to KUNIT formatting standard 2021-04-16 17:10:40 -07:00
mib.c mptcp: add active MPC mibs 2021-04-02 14:21:50 -07:00
mib.h mptcp: add active MPC mibs 2021-04-02 14:21:50 -07:00
mptcp_diag.c mptcp: add csum_enabled in mptcp_sock 2021-06-18 11:40:11 -07:00
options.c mptcp: receive checksum for MP_CAPABLE with data 2021-06-18 11:40:11 -07:00
pm.c mptcp: rename mptcp_pm_nl_add_addr_send_ack 2021-03-26 15:05:15 -07:00
pm_netlink.c mptcp: make sure flag signal is set when add addr with port 2021-05-28 13:59:16 -07:00
protocol.c mptcp: add csum_reqd in mptcp_options_received 2021-06-18 11:40:11 -07:00
protocol.h mptcp: receive checksum for MP_CAPABLE with data 2021-06-18 11:40:11 -07:00
sockopt.c mptcp: setsockopt: handle SOL_SOCKET in one place only 2021-06-04 14:08:09 -07:00
subflow.c mptcp: add csum_reqd in mptcp_options_received 2021-06-18 11:40:11 -07:00
syncookies.c mptcp: fix syncookie build error on UP 2020-08-01 11:52:55 -07:00
token.c mptcp: using TOKEN_MAX_RETRIES instead of magic number 2021-05-28 13:59:15 -07:00
token_test.c mptcp: introduce token KUNIT self-tests 2020-06-26 16:21:39 -07:00