qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH V5 09/12] NUMA: add qmp command set-mem-policy t


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH V5 09/12] NUMA: add qmp command set-mem-policy to set memory policy for NUMA node
Date: Wed, 17 Jul 2013 06:36:11 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130625 Thunderbird/17.0.7

On 07/17/2013 03:29 AM, Wanlong Gao wrote:
> This QMP command allows user set guest node's memory policy
> through the QMP protocol. The qmp-shell command is like:
>     set-mem-policy nodeid=0 policy=membind host-nodes=0-1
> 
> Signed-off-by: Wanlong Gao <address@hidden>
> ---
>  numa.c           | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  qapi-schema.json | 19 +++++++++++++++++++
>  qmp-commands.hx  | 35 +++++++++++++++++++++++++++++++++++
>  3 files changed, 109 insertions(+)
> 

> +++ b/qapi-schema.json
> @@ -3729,3 +3729,22 @@
>     '*size':          'size',
>     '*policy':                'str',
>     '*host-nodes':    'str' }}
> +
> +##
> +# @set-mem-policy:
> +#
> +# Set the host memory binding policy for guest NUMA node.
> +#
> +# @nodeid: The node ID of guest NUMA node to set memory policy to.
> +#
> +# @policy: #optional The memory policy to be set (default 'default').

Needs to be an enum type, not an open-coded 'str'.  Probably the same
enum type as you add for patch 6/12.

> +#
> +# @host-nodes: #optional The host nodes range for memory policy.

Again, how is this string interpreted; and should it be an array?

> +#
> +# Returns: Nothing on success
> +#
> +# Since: 1.6
> +##
> +{ 'command': 'set-mem-policy',
> +  'data': {'nodeid': 'int', '*policy': 'str',
> +           '*host-nodes': 'str'} }

-- 
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]