From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52587) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V6gmG-0007RP-QJ for qemu-devel@nongnu.org; Tue, 06 Aug 2013 08:54:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V6gmE-00021g-3D for qemu-devel@nongnu.org; Tue, 06 Aug 2013 08:54:16 -0400 Received: from mail.avalus.com ([2001:41c8:10:1dd::10]:58717) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V6gmD-0001zr-Jy for qemu-devel@nongnu.org; Tue, 06 Aug 2013 08:54:13 -0400 Date: Tue, 06 Aug 2013 13:54:04 +0100 From: Alex Bligh Message-ID: <3416A47729F09779B011B735@nimrod.local> In-Reply-To: <20130806124000.GF30812@stefanha-thinkpad.redhat.com> References: <1375639805-1943-1-git-send-email-alex@alex.org.uk> <1375780592-22842-1-git-send-email-alex@alex.org.uk> <1375780592-22842-11-git-send-email-alex@alex.org.uk> <20130806124000.GF30812@stefanha-thinkpad.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: Re: [Qemu-devel] [RFC] [PATCHv6 10/16] aio / timers: aio_ctx_prepare sets timeout from AioContext timers Reply-To: Alex Bligh List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: Kevin Wolf , Anthony Liguori , qemu-devel@nongnu.org, liu ping fan , Alex Bligh , Paolo Bonzini , MORITA Kazutaka , rth@twiddle.net Stefan, --On 6 August 2013 14:40:00 +0200 Stefan Hajnoczi wrote: > On Tue, Aug 06, 2013 at 10:16:26AM +0100, Alex Bligh wrote: >> @@ -180,7 +189,7 @@ aio_ctx_check(GSource *source) >> return true; >> } >> } >> - return aio_pending(ctx); >> + return aio_pending(ctx) || (timerlistgroup_deadline_ns(ctx->tlg) >= >> 0); > > Now we always dispatch if there is a timer? Should this comparison be > timerlistgroup_deadline_ns(ctx->tlg) == 0 instead to only dispatch > expired timers? I think you are right. -- Alex Bligh