Re: [PATCH net v2] tcp: fix device binding after failed IPv6 connect
From: Xia Yan
Date: Wed Nov 11 2026 - 06:35:12 EST
Hi Jakub,
> Just restore the old_bound_dev_if,
Done in v3. It restores the old binding unconditionally on native IPv6
errors, before TCP_CLOSE and the bind2 cleanup. It avoids restoring
again after the close callback.
The UML tests reproduce the stale binding and VRF warning on the
baseline. With v3, the reconnect and both VRF cases pass without kernel
warnings. I also checked the CONNECT/CLOSE sock_ops callbacks and
IPv4-mapped failures.
Deferred TCP_FASTOPEN_CONNECT failures after connect() returns success
are unchanged. I'll reproduce those separately and prepare a follow-up.
I'll send v3 as a separate thread.
Thanks,
Xia