Received: from eggs.gnu.org ([2001:4830:134:3::10]:56162) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1an28E-0004pM-83 for qemu-devel@nongnu.org; Mon, 04 Apr 2016 06:53:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1an28B-0007Pn-1p for qemu-devel@nongnu.org; Mon, 04 Apr 2016 06:53:18 -0400 Received: from mx1.redhat.com ([209.132.183.28]:45966) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1an28A-0007Pi-SZ for qemu-devel@nongnu.org; Mon, 04 Apr 2016 06:53:14 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 103094620B for ; Mon, 4 Apr 2016 10:53:14 +0000 (UTC) Date: Mon, 4 Apr 2016 12:53:11 +0200 From: Kevin Wolf Message-ID: <20160404105311.GB5651@noname.redhat.com> References: <1459429663-1230-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1459429663-1230-1-git-send-email-pbonzini@redhat.com> Subject: Re: [Qemu-devel] [PATCH] block: forbid x-blockdev-del from acting on DriveInfo List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: armbru@redhat.com, qemu-devel@nongnu.org, mreitz@redhat.com Am 31.03.2016 um 15:07 hat Paolo Bonzini geschrieben: > Failing on -drive/drive_add created BlockBackends was a > requirement for x-blockdev-del, but it sneaked through > the patch review. Let's fix it now. > > Example: > > $ x86_64-softmmu/qemu-system-x86_64 -drive if=none,file=null-co://,id=null -qmp stdio > >> {'execute':'qmp_capabilities'} > << {"return": {}} > >> {'execute':'x-blockdev-del','arguments':{'id':'null'}} > << {"error": {"class": "GenericError", "desc": "Deleting block backend added with drive-add is not supported"}} > > And without a DriveInfo: > > >> { "execute": "blockdev-add", "arguments": { "options": { "driver":"null-co", "id":"null2"}}} > << {"return": {}} > >> {'execute':'x-blockdev-del','arguments':{'id':'null2'}} > << {"return": {}} > > Suggested-by: Kevin Wolf > Signed-off-by: Paolo Bonzini Thanks, applied to the block branch. Kevin