From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43928) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xg8Ba-0004fn-Ht for qemu-devel@nongnu.org; Mon, 20 Oct 2014 04:19:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xg8BU-0008P2-D0 for qemu-devel@nongnu.org; Mon, 20 Oct 2014 04:19:26 -0400 Received: from mx1.redhat.com ([209.132.183.28]:12763) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xg8BU-0008Ot-5b for qemu-devel@nongnu.org; Mon, 20 Oct 2014 04:19:20 -0400 From: Markus Armbruster References: <1412683166-4934-1-git-send-email-armbru@redhat.com> <1412683166-4934-17-git-send-email-armbru@redhat.com> <20141017183126.GA23347@noname.redhat.com> Date: Mon, 20 Oct 2014 10:19:09 +0200 In-Reply-To: <20141017183126.GA23347@noname.redhat.com> (Kevin Wolf's message of "Fri, 17 Oct 2014 20:31:26 +0200") Message-ID: <8738aj8876.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH v6 16/24] hw: Convert from BlockDriverState to BlockBackend, mostly List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: benoit.canet@nodalink.com, qemu-devel@nongnu.org, stefanha@redhat.com, mreitz@redhat.com Kevin Wolf writes: > Am 07.10.2014 um 13:59 hat Markus Armbruster geschrieben: >> Device models should access their block backends only through the >> block-backend.h API. Convert them, and drop direct includes of >> inappropriate headers. >> >> Just four uses of BlockDriverState are left: >> >> * The Xen paravirtual block device backend (xen_disk.c) opens images >> itself when set up via xenbus, bypassing blockdev.c. I figure it >> should go through qmp_blockdev_add() instead. >> >> * Device model "usb-storage" prompts for keys. No other device model >> does, and this one probably shouldn't do it, either. >> >> * ide_issue_trim_cb() uses bdrv_aio_discard() instead of >> blk_aio_discard() because it fishes its backend out of a BlockAIOCB, >> which has only the BlockDriverState. >> >> * PC87312State has an unused BlockDriverState[] member. >> >> The next two commits take care of the latter two. >> >> Signed-off-by: Markus Armbruster > >> diff --git a/include/qemu/typedefs.h b/include/qemu/typedefs.h >> index 198da2e..8b3f352 100644 >> --- a/include/qemu/typedefs.h >> +++ b/include/qemu/typedefs.h >> @@ -37,6 +37,7 @@ typedef struct HCIInfo HCIInfo; >> typedef struct AudioState AudioState; >> typedef struct BlockBackend BlockBackend; >> typedef struct BlockDriverState BlockDriverState; >> +typedef struct BlockBackend BlockBackend; >> typedef struct DriveInfo DriveInfo; >> typedef struct DisplayState DisplayState; >> typedef struct DisplayChangeListener DisplayChangeListener; > > This is a duplicate typedef (the first definition is even in the context > of this hunk) and causes the build to fail on RHEL 6. I can drop the > hunk while applying if you don't object. Yes, please!