Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Aug 2016 00:43:23 +0200
From:      Gary Jennejohn <gljennjohn@gmail.com>
To:        Gleb Smirnoff <glebius@FreeBSD.org>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r304244 - head/sys/kern
Message-ID:  <20160817004323.5383bf7f@ernst.home>
In-Reply-To: <201608162155.u7GLtYp4091232@repo.freebsd.org>
References:  <201608162155.u7GLtYp4091232@repo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 16 Aug 2016 21:55:34 +0000 (UTC)
Gleb Smirnoff <glebius@FreeBSD.org> wrote:

> Author: glebius
> Date: Tue Aug 16 21:55:34 2016
> New Revision: 304244
> URL: https://svnweb.freebsd.org/changeset/base/304244
> 
> Log:
>   We should not be allowing a timeout to reset when a drain is in progress on
>   it (either async or sync drain).
>   
>   At this moment the only user of drain is TCP, but TCP wouldn't reschedule a
>   callout after it has drained it, since it drains only when a tcpcb is closed.
>   This for now the problem isn't observed.
>   
>   Submitted by:	rrs
> 
> Modified:
>   head/sys/kern/kern_timeout.c
> 
> Modified: head/sys/kern/kern_timeout.c
> ==============================================================================
> --- head/sys/kern/kern_timeout.c	Tue Aug 16 21:32:05 2016	(r304243)
> +++ head/sys/kern/kern_timeout.c	Tue Aug 16 21:55:34 2016	(r304244)
> @@ -1061,7 +1061,7 @@ callout_reset_sbt_on(struct callout *c, 
>  		 */
>  		if (c->c_lock != NULL && !cc_exec_cancel(cc, direct))
>  			cancelled = cc_exec_cancel(cc, direct) = true;
> -		if (cc_exec_waiting(cc, direct)) {
> +		if (cc_exec_waiting(cc, direct) || cc_exec_drain(cc, dir)) { <== dir in this line should really be direct.
>  			/*
>  			 * Someone has called callout_drain to kill this
>  			 * callout.  Don't reschedule.

-- 
Gary Jennejohn



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20160817004323.5383bf7f>