mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-27 01:10:38 +01:00
l3cfg: wait for the address before configuring an MPTCP endpoint
Skip the configuration of the MPTCP endpoint when the address is in
the l3cd but is not yet configured in the platform. This typically
happens when IPv4 DAD is enabled and the address is being probed.
If we configure the endpoint without the address set, the kernel will
try to use the endpoint immediately but it will fail. Then, the
endpoint will not be used ever again after the address is added.
(cherry picked from commit 6bf859af79)
This commit is contained in:
parent
a301c259f2
commit
2c5a51201d
1 changed files with 12 additions and 0 deletions
|
|
@ -5051,6 +5051,8 @@ _l3_commit_mptcp_af(NML3Cfg *self,
|
|||
self->priv.p->combined_l3cd_commited,
|
||||
addr_family,
|
||||
(const NMPlatformIPAddress **) &addr) {
|
||||
const NMPObject *obj;
|
||||
|
||||
/* We want to evaluate the with-{loopback,link_local}-{4,6} flags based on the actual
|
||||
* ifa_scope that the address will have once we configure it.
|
||||
* "addr" is an address we want to configure, we expect that it will
|
||||
|
|
@ -5077,6 +5079,16 @@ _l3_commit_mptcp_af(NML3Cfg *self,
|
|||
break;
|
||||
}
|
||||
|
||||
obj = nm_platform_ip_address_get(self->priv.platform,
|
||||
addr_family,
|
||||
self->priv.ifindex,
|
||||
addr);
|
||||
if (!obj) {
|
||||
/* The address is not yet configured in platform, typically due to
|
||||
* IPv4 DAD; skip it for now otherwise the kernel will try to use
|
||||
* the endpoint, it will fail, and it will never try it again. */
|
||||
goto skip_addr;
|
||||
}
|
||||
a.addr = nm_ip_addr_init(addr_family, addr->ax.address_ptr);
|
||||
|
||||
/* We track the address with different priorities, that depends
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue