Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-07 Thread Eric Blake
On 06/06/2012 10:51 PM, Anthony Liguori wrote: >> Of course, being able to support hex from QMP would be a nice feature, >> but I'm not sure how to add it in. > > Why is it a nice feature? Because libvirt already allows users to pass in integers instead of symbolic names. Providing integer supp

Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-06 Thread Anthony Liguori
On 06/06/2012 07:58 PM, Eric Blake wrote: On 06/06/2012 01:13 AM, Amos Kong wrote: Ho, I found another bug in my code, key in decimal or hexadecimal format is not supported. I will fix it. How do you plan to support decimal in QMP? In old do_sendkey(), only key-name and hexadecimal were sup

Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-06 Thread Eric Blake
On 06/06/2012 01:13 AM, Amos Kong wrote: >>> Ho, I found another bug in my code, key in decimal or hexadecimal >>> format is not supported. I will fix it. >> >> How do you plan to support decimal in QMP? > > In old do_sendkey(), only key-name and hexadecimal were supported, > the description need

Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-06 Thread Amos Kong
On 05/06/12 23:05, Eric Blake wrote: On 06/05/2012 08:55 AM, Amos Kong wrote: +# @sendkey: +# +# Send keys to VM. +# +# @keys: key sequence +# @hold-time: time to delay key up events, milliseconds +# +# Returns: Nothing on success +# If key is unknown or redundant, QERR_INVALID_PARAMET

Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-05 Thread Eric Blake
On 06/05/2012 08:55 AM, Amos Kong wrote: >>> +# @sendkey: >>> +# >>> +# Send keys to VM. >>> +# >>> +# @keys: key sequence >>> +# @hold-time: time to delay key up events, milliseconds >>> +# >>> +# Returns: Nothing on success >>> +# If key is unknown or redundant, QERR_INVALID_PARAMETER >

Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-05 Thread Amos Kong
Hello Eric, Thanks for your comments. - Original Message - > On 06/01/2012 04:54 PM, Amos Kong wrote: > > Convert 'sendkey' to use QAPI. do_sendkey() depends on some > > variables/functions in monitor.c, so reserve qmp_sendkey() > > to monitor.c > > > > key_defs[] in monitor.c is the ma

Re: [Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-04 Thread Eric Blake
On 06/01/2012 04:54 PM, Amos Kong wrote: > Convert 'sendkey' to use QAPI. do_sendkey() depends on some > variables/functions in monitor.c, so reserve qmp_sendkey() > to monitor.c > > key_defs[] in monitor.c is the mapping of key name to keycode, > Keys' order in the enmu and key_defs[] is same. >

[Qemu-devel] [PATCH v2 6/6] qapi: convert sendkey

2012-06-01 Thread Amos Kong
Convert 'sendkey' to use QAPI. do_sendkey() depends on some variables/functions in monitor.c, so reserve qmp_sendkey() to monitor.c key_defs[] in monitor.c is the mapping of key name to keycode, Keys' order in the enmu and key_defs[] is same. Signed-off-by: Amos Kong --- hmp-commands.hx |2