From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57857) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z866r-0008L5-4z for qemu-devel@nongnu.org; Thu, 25 Jun 2015 08:18:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z866q-0007D7-43 for qemu-devel@nongnu.org; Thu, 25 Jun 2015 08:18:25 -0400 Sender: Paolo Bonzini Message-ID: <558BF184.6090401@redhat.com> Date: Thu, 25 Jun 2015 14:18:12 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1432822629-25401-1-git-send-email-pbonzini@redhat.com> In-Reply-To: <1432822629-25401-1-git-send-email-pbonzini@redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] blockdev: no need to drain+flush in hmp_drive_del List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Kevin Wolf , armbru@redhat.com, Block layer core Ping? Paolo On 28/05/2015 16:17, Paolo Bonzini wrote: > bdrv_close already does that, and in fact hmp_drive_del would need > another drain after the flush (which bdrv_close does). So remove > the duplication. > > Signed-off-by: Paolo Bonzini > --- > blockdev.c | 3 --- > 1 file changed, 3 deletions(-) > > diff --git a/blockdev.c b/blockdev.c > index 5eaf77e..d506a70 100644 > --- a/blockdev.c > +++ b/blockdev.c > @@ -2143,9 +2143,6 @@ int hmp_drive_del(Monitor *mon, const QDict *qdict, QObject **ret_data) > return -1; > } > > - /* quiesce block driver; prevent further io */ > - bdrv_drain_all(); > - bdrv_flush(bs); > bdrv_close(bs); > > /* if we have a device attached to this BlockDriverState >