qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH 2/9] block/qapi: Add qdev device name to query-b


From: Eric Blake
Subject: Re: [Qemu-block] [PATCH 2/9] block/qapi: Add qdev device name to query-block
Date: Wed, 12 Jul 2017 10:06:20 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

On 07/12/2017 07:57 AM, Kevin Wolf wrote:
> With -blockdev/-device, users can indirectly create anonymous
> BlockBackends, in the state of which they are still interested. As a

Reads awkwardly.  Maybe:

BlockBackends, although it is still of interest to learn the state of
such backends.

> preparation for making such BBs visible in query-block, make sure that
> they can be identified even without a name by adding the ID/QOM path of
> their qdev device to BlockInfo.
> 
> Signed-off-by: Kevin Wolf <address@hidden>
> ---

> +++ b/qapi/block-core.json
> @@ -433,6 +433,9 @@
>  #
>  # @device: The device name associated with the virtual device.
>  #
> +# @qdev: The qdev ID, or if no ID is assigned the QOM path, of the block

s/assigned the QOM path, of/assigned, the QOM path of/

> +#        device.

Missing a (since 2.10) tag.

> +#
>  # @type: This field is returned only for compatibility reasons, it should
>  #        not be used (always returns 'unknown')
>  #
> @@ -458,7 +461,7 @@
>  # Since:  0.14.0
>  ##
>  { 'struct': 'BlockInfo',
> -  'data': {'device': 'str', 'type': 'str', 'removable': 'bool',
> +  'data': {'device': 'str', '*qdev': 'str', 'type': 'str', 'removable': 
> 'bool',
>             'locked': 'bool', '*inserted': 'BlockDeviceInfo',
>             '*tray_open': 'bool', '*io-status': 'BlockDeviceIoStatus',
>             '*dirty-bitmaps': ['BlockDirtyInfo'] } }

Besides the testsuite, are there any example outputs that need to be
adjusted?

> diff --git a/tests/qemu-iotests/067.out b/tests/qemu-iotests/067.out
> index 782eae2..e3c4496 100644
> --- a/tests/qemu-iotests/067.out
> +++ b/tests/qemu-iotests/067.out
> @@ -57,6 +57,7 @@ Testing: -drive 
> file=TEST_DIR/t.qcow2,format=qcow2,if=none,id=disk -device virti
>                  "file": "TEST_DIR/t.qcow2",
>                  "encryption_key_missing": false
>              },
> +            "qdev": "/machine/peripheral/virtio0/virtio-backend",
>              "type": "unknown"
>          }
>      ]
> 

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]