From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53221) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zoy5E-0000BL-T1 for qemu-devel@nongnu.org; Wed, 21 Oct 2015 14:25:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zoy5E-0007MD-2k for qemu-devel@nongnu.org; Wed, 21 Oct 2015 14:25:56 -0400 Date: Wed, 21 Oct 2015 14:25:48 -0400 From: Jeff Cody Message-ID: <20151021182548.GI6466@localhost.localdomain> References: <1445393209-26545-1-git-send-email-famz@redhat.com> <1445393209-26545-11-git-send-email-famz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1445393209-26545-11-git-send-email-famz@redhat.com> Subject: Re: [Qemu-devel] [Qemu-block] [PATCH v5 10/12] block: Introduce BlockDriver.bdrv_drain callback List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: kwolf@redhat.com, pbonzini@redhat.com, qemu-block@nongnu.org, qemu-devel@nongnu.org, stefanha@redhat.com On Wed, Oct 21, 2015 at 10:06:47AM +0800, Fam Zheng wrote: > Drivers can have internal request sources that generate IO, like the > need_check_timer in QED. Since we want quiesced periods that contain > nested event loops in block layer, we need to have a way to disable such > event sources. > > Block drivers must implement the "bdrv_drain" callback if it has any > internal sources that can generate I/O activity, like a timer or a > worker thread (even in a library) that can schedule QEMUBH in an > asynchronous callback. > > Update the comments of bdrv_drain and bdrv_drained_begin accordingly. > > Signed-off-by: Fam Zheng Reviewed-by: Jeff Cody