Received: from eggs.gnu.org ([2001:4830:134:3::10]:51974) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bKRn7-0003rT-MP for qemu-devel@nongnu.org; Tue, 05 Jul 2016 10:57:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bKRn6-0001k6-MI for qemu-devel@nongnu.org; Tue, 05 Jul 2016 10:57:37 -0400 References: <1467296007-12252-1-git-send-email-kwolf@redhat.com> <1467296007-12252-6-git-send-email-kwolf@redhat.com> <7b9f7996-dd79-f393-fcb7-97751cfa6dd0@redhat.com> <20160704105030.GD5399@noname.redhat.com> From: Max Reitz Message-ID: Date: Tue, 5 Jul 2016 16:57:07 +0200 MIME-Version: 1.0 In-Reply-To: <20160704105030.GD5399@noname.redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="8dinAxE5hX5jsxLoK9eoPGtXLmXW5TJuT" Subject: Re: [Qemu-devel] [PATCH v2 5/6] qemu-iotests: Test setting WCE with qdev List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: qemu-block@nongnu.org, eblake@redhat.com, qemu-devel@nongnu.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --8dinAxE5hX5jsxLoK9eoPGtXLmXW5TJuT From: Max Reitz To: Kevin Wolf Cc: qemu-block@nongnu.org, eblake@redhat.com, qemu-devel@nongnu.org Message-ID: Subject: Re: [PATCH v2 5/6] qemu-iotests: Test setting WCE with qdev References: <1467296007-12252-1-git-send-email-kwolf@redhat.com> <1467296007-12252-6-git-send-email-kwolf@redhat.com> <7b9f7996-dd79-f393-fcb7-97751cfa6dd0@redhat.com> <20160704105030.GD5399@noname.redhat.com> In-Reply-To: <20160704105030.GD5399@noname.redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 04.07.2016 12:50, Kevin Wolf wrote: > Am 02.07.2016 um 18:15 hat Max Reitz geschrieben: >> On 30.06.2016 16:13, Kevin Wolf wrote: >>> + echo "info block" \ >>> + | run_qemu -drive "$drive,cache=3D$cache" \ >>> + -device "ide-hd,drive=3Dnone0$wce" \ >>> + | grep -e "Testing" -e "Cache mode" >> >> Something interesting: If you'd specify the drive through a node name,= >> then the BDS tree has two BBs, one implicitly created with -drive (thi= s >> one is named (automatically) and owned by the monitor) and an anonymou= s >> one for the device. If the device then overrides the cache mode, this >> will not be reflected in the monitor-owned BB. "info block" (and >> query-block) use the monitor BBs, however, so they'll report the BB on= >> top of the BDS tree in question to be in whatever mode has been >> specified in -drive, whereas the mode the device uses for accessing th= at >> BDS tree actually has nothing to do with that. >> >> So the user has no way of inquiring the cache mode used by the device,= >> and they actually get presented misleading information. >=20 > Yes, I know. Originally I wanted to add test cases that use node-name, > but then it occurred to me that this would be pretty pointless. >=20 > I'm not sure yet what the conclusion is. Change query-block to include > anonymous BBs that are owned by devices? A new query command? Add the > information to info qtree and whatever the QMP version of it is (if it > even exists)? Well, since you are basically trying to purge the BB from the user's field of view, it would probably make sense to display all the BB-level information (like the writethrough mode) as part of the device information; that is, probably in info qtree. That information should then probably also include the node name of the root BDS, and the user/management application can find out all about that with query-named-block-nodes (although it'd probably makes sense to add a query-block-node command for a single node). Max --8dinAxE5hX5jsxLoK9eoPGtXLmXW5TJuT 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 iQEvBAEBCAAZBQJXe8rDEhxtcmVpdHpAcmVkaGF0LmNvbQAKCRA7sUIC6DisrXW9 B/42juw6aeMDw1EhnXe7bCYybMKorsJ3JQoCiLeLutsd4FFnlIdC735G/Vj09r19 ki1KfuC9KKqCNgEpi1DK0lvN2WCP1H0W7eeHcQ8aQ+SXy//uAZvP4xY3oNiMGLmW crXsUW+gdMEL67i2TuKuKbSfGVDmcO/mpHZUDE4fBpA2yC6viavuUQU8dWna/vBD U1d37pJxCAdCrnUPjOPF4hfutT1XSbS9gid+Unv3MAEmgDmEbX+BhGY3LNUHRnPx LyN7uG/p2FaohJHAhEe5Avlk+7io7OubjESQB6q5wZCZkiVNqr5acEc3lyPJ9IRP nem7nU7F6dYuIHBUn4cpFx4Y =0hAw -----END PGP SIGNATURE----- --8dinAxE5hX5jsxLoK9eoPGtXLmXW5TJuT--