linux/net
Paolo Abeni 5969856ae8 mptcp: fix races between shutdown and recvmsg
The msk sk_shutdown flag is set by a workqueue, possibly
introducing some delay in user-space notification. If the last
subflow carries some data with the fin packet, the user space
can wake-up before RCV_SHUTDOWN is set. If it executes unblocking
recvmsg(), it may return with an error instead of eof.

Address the issue explicitly checking for eof in recvmsg(), when
no data is found.

Fixes: 59832e2465 ("mptcp: subflow: check parent mptcp socket on subflow state change")
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Reviewed-by: Matthieu Baerts <matthieu.baerts@tessares.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-06-10 13:34:14 -07:00
..
6lowpan
9p
802
8021q net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
appletalk
atm
ax25
batman-adv net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
bluetooth Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-06-03 16:27:18 -07:00
bpf
bpfilter
bridge net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
caif
can
ceph Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-06-03 16:27:18 -07:00
core net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
dcb
dccp dccp: Fix possible memleak in dccp_init and dccp_fini 2020-06-09 13:26:23 -07:00
decnet
dns_resolver
dsa net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
ethernet
ethtool ethtool: linkinfo: remove an unnecessary NULL check 2020-06-05 13:10:02 -07:00
hsr
ieee802154
ife
ipv4 nexthop: Fix fdb labeling for groups 2020-06-10 13:18:40 -07:00
ipv6 Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-06-07 17:27:45 -07:00
iucv
kcm
key
l2tp Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-05-31 17:48:46 -07:00
l3mdev
lapb
llc
mac80211 net: fix wiki website url mac80211 and wireless files 2020-06-08 10:06:05 +02:00
mac802154
mpls
mptcp mptcp: fix races between shutdown and recvmsg 2020-06-10 13:34:14 -07:00
ncsi
netfilter Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-06-03 16:27:18 -07:00
netlabel
netlink genetlink: fix memory leaks in genl_family_rcv_msg_dumpit() 2020-06-04 15:33:45 -07:00
netrom net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
nfc
nsh
openvswitch
packet
phonet
psample
qrtr Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-05-31 17:48:46 -07:00
rds RDMA 5.8 merge window pull request 2020-06-05 14:05:57 -07:00
rfkill
rose net: change addr_list_lock back to static key 2020-06-09 12:59:45 -07:00
rxrpc rxrpc fixes 2020-06-08 19:13:37 -07:00
sched net: sched: export __netdev_watchdog_up() 2020-06-09 13:14:31 -07:00
sctp Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-06-03 16:27:18 -07:00
smc RDMA 5.8 merge window pull request 2020-06-05 14:05:57 -07:00
strparser
sunrpc
switchdev
tipc tipc: fix NULL pointer dereference in streaming 2020-06-04 15:37:59 -07:00
tls bpf: Fix running sk_skb program types with ktls 2020-06-01 14:48:32 -07:00
unix
vmw_vsock vsock/vmci: make vmci_vsock_transport_cb() static 2020-06-05 13:18:26 -07:00
wimax
wireless net: fix wiki website url mac80211 and wireless files 2020-06-08 10:06:05 +02:00
x25
xdp net/xdp: use shift instead of 64 bit division 2020-06-04 16:02:58 -07:00
xfrm Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-05-31 17:48:46 -07:00
compat.c switch cmsghdr_from_user_compat_to_kern() to copy_from_user() 2020-06-01 12:05:45 -07:00
devres.c
Kconfig
Makefile
socket.c
sysctl_net.c