qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC 4/5] qmp: add query-acpi-ospm-status command


From: Eric Blake
Subject: Re: [Qemu-devel] [RFC 4/5] qmp: add query-acpi-ospm-status command
Date: Fri, 30 May 2014 09:22:56 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0

On 05/28/2014 08:57 AM, Igor Mammedov wrote:
> ... to get ACPI OSPM status reported by ACPI devices
> via _OST method.
> 
> Signed-off-by: Igor Mammedov <address@hidden>
> ---
>  qapi-schema.json |    9 +++++++++
>  qmp-commands.hx  |   22 ++++++++++++++++++++++
>  qmp.c            |   20 ++++++++++++++++++++
>  3 files changed, 51 insertions(+), 0 deletions(-)

Interface review:


> +Example:
> +-> { "execute": "query-acpi-ospm-status" }
> +<- { 'return': [ { 'device': 'd1', 'slot': 0, 'source': 1, 'status': 0},

Should 'status' be represented as an enum type, rather than an
open-coded integer?

> +                 { 'device': '', 'slot': 1, 'source': 0, 'status': 0},
> +                 { 'device': '', 'slot': 2, 'source': 0, 'status': 0},

Why not make 'device' optional, and omit it when there is no associated
device string?

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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