Re: [PATCH net v2] tcp: fix device binding after failed IPv6 connect

From: Xia Yan

Date: Tue Nov 03 2026 - 18:26:30 EST


Hi,

Thanks for the review. I agree that the deferred Fast Open send failure
is not covered. In that case, tcp_v6_connect() returns 0 and connect()
has already returned before tcp_sendmsg_fastopen() encounters the error.

v2 restores the binding on synchronous errors returned by
tcp_v6_connect(), as stated in the commit message. The later send failure
is a pre-existing issue. Covering it would mean keeping the original
binding beyond tcp_v6_connect() and handling any subsequent binding
changes. I'd prefer to handle that separately from this fix.

The datagram binding rollback has now been merged into net/main:
https://git.kernel.org/netdev/net/c/bc53aab4881adc134f495092034e9e7c0791d84c

Agreed on WRITE_ONCE() for the scope assignment. I'll include that if
another revision is needed.

Thanks,
Xia Yan