]> git.baikalelectronics.ru Git - kernel.git/commit
mptcp: fix race in overlapping signal events
authorPaolo Abeni <pabeni@redhat.com>
Fri, 18 Feb 2022 21:35:40 +0000 (13:35 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 19 Feb 2022 12:28:00 +0000 (12:28 +0000)
commit7f351042caed2d14295032eb17edba36f07080c0
tree8e36b327a277eed125c350307009a284df796d11
parentd4d8b9292d25a02299a4baf087a6a2fca71ed5c9
mptcp: fix race in overlapping signal events

After commit 50839b6d97c8 ("mptcp: do not block subflows
creation on errors"), if a signal address races with a failing
subflow creation, the subflow creation failure control path
can trigger the selection of the next address to be announced
while the current announced is still pending.

The above will cause the unintended suppression of the ADD_ADDR
announce.

Fix the issue skipping the to-be-suppressed announce before it
will mark an endpoint as already used. The relevant announce
will be triggered again when the current one will complete.

Fixes: 50839b6d97c8 ("mptcp: do not block subflows creation on errors")
Reviewed-by: Matthieu Baerts <matthieu.baerts@tessares.net>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/mptcp/pm_netlink.c