HomeFreeBSD

tcp: close two minor races with debug messages

Description

tcp: close two minor races with debug messages

The syncache entry is locked by the hash bucket lock. After running
SCH_UNLOCK(), we have no guarantee that the syncache entry still
exists.

Resolve the race by moving SCH_UNLOCK() after the log() call which
reads variables from the syncache entry.

Reviewed by: rrs, tuexen, Nick Banks
Sponsored by: Netflix
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D52868

(cherry picked from commit ad38f6a0b466bf05a0d40ce1daa8c7bce0936271)

Details

Provenance
jtlAuthored on Thu, Oct 2, 5:26 PM
Reviewer
rrs
Differential Revision
D52868: tcp: close two minor races with debug messages
Parents
rGa7dcd4c2a9fb: tcp: improve segment validation in SYN-RECEIVED
Branches
Unknown
Tags
Unknown