svn commit: r239983 - stable/8/sys/netinet

Mikolaj Golub at
Thu Sep 6 06:23:40 UTC 2012

On Wed, Sep 05, 2012 at 07:31:19PM +0100, Robert Watson wrote:
> On Wed, 5 Sep 2012, Bjoern A. Zeeb wrote:
> >> Log:
> >>  MFC r239075:
> >>
> >>  In tcp timers, check INP_DROPPED flag a little later, after
> >>  callout_deactivate(), so if INP_DROPPED is set we return with the
> >>  timer active flag cleared.
> >>
> >>  For me this fixes negative keep timer values reported by `netstat -x'
> >>  for connections in CLOSE state.
> >
> > panic: Lock tcp not read locked @ /w/src/sys/netinet/tcp_timer.c:497
> >
> > reproducable on the cluster.  Probably wrong all the way up to HEAD?
> This looks like a mis-merge -- in 8.x, read-locking of the inpcbinfo is not 
> used in the TCP timer code, whereas in 9.x and later it is.  There are 
> important and subtle differences between inpcb/inpcb/inpcbhash locking across 
> all supported major FreeBSD versions, as we have substantially refined our 
> approach to improve performance and stability over the years.  As a result, it 
> is generally not safe to MFC TCP/UDP locking changes without extreme care.  I 
> would recommend seeking at least one, if not multiple, reviewers for changes 
> and MFCs along these lines.  Even with you and others doing line-by-line 
> reviews of much of the original work, we ran into quite a few bugs due to the 
> complexity and difficulty in reviewing the code.
Thanks! I am going to direct commit this patch to fix the mis-merge.

Sorry, will be much more careful with such things next time.

Mikolaj Golub
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tcp_timer.c.stable8.diff
Type: text/x-diff
Size: 451 bytes
Desc: not available
Url :

More information about the svn-src-stable-8 mailing list