From 7b5053ce2296e0fd96f162e308beb344b4ee654c Mon Sep 17 00:00:00 2001 From: Gleb Smirnoff Date: Fri, 16 Apr 2021 14:39:19 -0700 Subject: [PATCH] tcp_input: remove comments and assertions about tcpbinfo locking They aren't valid since d40c0d47cd2. --- sys/netinet/tcp_input.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c index 8592f3313725..cac67024705e 100644 --- a/sys/netinet/tcp_input.c +++ b/sys/netinet/tcp_input.c @@ -984,16 +984,6 @@ tcp_input_with_port(struct mbuf **mp, int *offp, int proto, uint16_t port) * or duplicate segments arriving late. If this segment was a * legitimate new connection attempt, the old INPCB gets removed and * we can try again to find a listening socket. - * - * At this point, due to earlier optimism, we may hold only an inpcb - * lock, and not the inpcbinfo write lock. If so, we need to try to - * acquire it, or if that fails, acquire a reference on the inpcb, - * drop all locks, acquire a global write lock, and then re-acquire - * the inpcb lock. We may at that point discover that another thread - * has tried to free the inpcb, in which case we need to loop back - * and try to find a new inpcb to deliver to. - * - * XXXRW: It may be time to rethink timewait locking. */ if (inp->inp_flags & INP_TIMEWAIT) { tcp_dooptions(&to, optp, optlen, @@ -1361,7 +1351,6 @@ tcp_input_with_port(struct mbuf **mp, int *offp, int proto, uint16_t port) * Entry added to syncache and mbuf consumed. * Only the listen socket is unlocked by syncache_add(). */ - INP_INFO_WUNLOCK_ASSERT(&V_tcbinfo); return (IPPROTO_DONE); } else if (tp->t_state == TCPS_LISTEN) { /* @@ -1414,7 +1403,6 @@ tcp_input_with_port(struct mbuf **mp, int *offp, int proto, uint16_t port) INP_UNLOCK(inp); drop: - INP_INFO_WUNLOCK_ASSERT(&V_tcbinfo); if (s != NULL) free(s, M_TCPLOG); if (m != NULL)