From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49102) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aaXNU-0002yX-VO for qemu-devel@nongnu.org; Mon, 29 Feb 2016 18:37:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aaXNT-0002fo-JL for qemu-devel@nongnu.org; Mon, 29 Feb 2016 18:37:24 -0500 References: <1456787973-19348-1-git-send-email-mreitz@redhat.com> <56D4D314.2070405@redhat.com> From: Max Reitz Message-ID: <56D4D62A.3060905@redhat.com> Date: Tue, 1 Mar 2016 00:37:14 +0100 MIME-Version: 1.0 In-Reply-To: <56D4D314.2070405@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="bPbTj7udm1upJihKec99ibf70kWFnS9id" Subject: Re: [Qemu-devel] [PATCH v2 00/16] qapi: Allow blockdev-add for NBD List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake , qemu-block@nongnu.org Cc: Kevin Wolf , Markus Armbruster , qemu-devel@nongnu.org, Luiz Capitulino , Paolo Bonzini This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --bPbTj7udm1upJihKec99ibf70kWFnS9id Content-Type: multipart/mixed; boundary="ChI9sv3KC8JItsD1iG4OCG46iJGV6i48n" From: Max Reitz To: Eric Blake , qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, Kevin Wolf , Paolo Bonzini , "Daniel P . Berrange" , Markus Armbruster , Luiz Capitulino Message-ID: <56D4D62A.3060905@redhat.com> Subject: Re: [PATCH v2 00/16] qapi: Allow blockdev-add for NBD References: <1456787973-19348-1-git-send-email-mreitz@redhat.com> <56D4D314.2070405@redhat.com> In-Reply-To: <56D4D314.2070405@redhat.com> --ChI9sv3KC8JItsD1iG4OCG46iJGV6i48n Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 01.03.2016 00:24, Eric Blake wrote: > On 02/29/2016 04:19 PM, Max Reitz wrote: >> Turns out NBD is not so simple to do if you do it right. Anyway, this >> series adds blockdev-add support for NBD clients. >> >> Patches 1 and 2 add one less and one more complicated QDict function, >> respectively, which I needed in later NBD patches: Patch 1 for handlin= g >> legacy options (move "host" to "address.data.host" etc.) and patch 2 >> because I'd like to use the input visitor for transforming the NBD >> options into a SocketAddress. Unfortunately, the block layer uses >> flattened QDicts everywhere, so we'll have to unflatten (erect?) them >> before we can use that visitor. >=20 > Dan had a patch proposal that called the operation "crumple"; I need to= > review both proposals and see which one I like. > https://lists.gnu.org/archive/html/qemu-devel/2016-02/msg04618.html Well, here I go again, not looking at patches on the list... Looking at the design, I like his idea of having an escape sequence; also, his qdict_crumple() can return boths lists and dicts where my qdict_unflatten() only returns dicts (then again, this is what qdict_flatten() always works on). And his patch doesn't suffer from as much indentation as mine does. What I like more about my patch, however, is that I'm reusing qdict_array_split() and qdict_array_entries(). That is mostly because my function modifies the given QDict, where Dan's does not. >> >> Patch 3 adds a test for qdict_unflatten(). >> >> Patches 4, 5, 6, and 7 are minor patches with no functional relation t= o >> this series, other than later patches will touch the code they touch, >> too. >> >> Patches 8 and 9 prepare the code for the addition of a new option >> prefix, which is "address.". >> >> Patch 10 makes the NBD client accept a SocketAddress under the "addres= s" >> option (or rather, a flattened SocketAddress QDict with its keys >> prefixed by "address."). The old options "host", "port", and "path" ar= e >> supported as legacy options and translated to the respective >> SocketAddress representation. >> >> Patch 11 drops usage of "host", "port", and "path" outside of >> nbd_has_filename_options_conflict(), >> nbd_process_legacy_socket_options(), and nbd_refresh_filename(), makin= g >> those options nothing but legacy. >> >> Patch 12, the goal of this series, is again not very complicated. >> >> Patches 13, 14, and 15 are required for the iotest added in patch 16. = It >> will invoke qemu-nbd, so patch 13 is required. Besides qemu-nbd, it wi= ll >> launch an NBD server VM concurrently to the client VM, which is why >> patch 14 is required. And finally, it will test whether we can add an >> NBD BDS by passing it a file descriptor, which patch 15 is needed for >> (so we use the socket_scm_helper to pass sockets to qemu). >> >> Patch 16 then adds the iotest for NBD's blockdev-add interface. >> >> >> Note on the relation to v1: As you can see, most of this series is >> completely new. Patch 5 was patch 1 in v1, and the only thing that has= >> changed is that I removed the full stop at the end of the error messag= e; >> consequently I kept Eric's R-b. >=20 > Looks like my review queue is getting longer because I (like several > other people) are trying to post last-minute series before soft freeze.= So is mine. :-) Yes, during the last week I had to prioritize patches over reviewing. Max --ChI9sv3KC8JItsD1iG4OCG46iJGV6i48n-- --bPbTj7udm1upJihKec99ibf70kWFnS9id Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJW1NYqAAoJEDuxQgLoOKytw8sH/2KtmWY41j8+j33K5e3cUrjx ID8KtZfWYL3Znc7KnoAlyjDtgyrmA3TkhiXTRUD6t9MiOLgbp4KBPjzeclEVHi/e PEMwN3JmWRHsfLZSiSZpyAGK6Z26V7sIG9IQmHu9rTBg/Y29sy/D4f4VTuoVeSU1 wY4ge/ZPkue/doMmPD77Vritf5/Fv9bPEcf2AM1AfHdQinRGXk8dn81sSsTbZ8Yh Ge4MrMfnFuyECGljJ3hFEZ8sKfYWsMGjCkO5rpyDDwtb2/3LRoKTpGx2k07cIsXY 5oh3wayEYRJzhnglHklyVo4Sku0yAo8U1KgSVHYWuYxMkeGiLjyX4BOc8eyB8U8= =j1pt -----END PGP SIGNATURE----- --bPbTj7udm1upJihKec99ibf70kWFnS9id--