qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v2] hmp: allow cpu index for "info lapic"


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v2] hmp: allow cpu index for "info lapic"
Date: Wed, 19 Jul 2017 10:02:04 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

[adding libvirt]

On 07/19/2017 07:41 AM, Eduardo Habkost wrote:

>> virsh  qemu-monitor-command --domain rhel6.8 --hmp --cmd "cpu 1"
>> virsh  qemu-monitor-command --domain rhel6.8 --hmp --cmd "info lapic"
>> dumping local APIC state for CPU 0
> 
> Right, the "cpu" command is useless inside a
> 'human-monitor-command' QMP command.  The 'cpu-index' argument
> should be used instead. should make "cpu" print an error if ran
> inside 'human-monitor-command' instead of silently pretend it
> worked.
> 
> If virsh doesn't support the 'cpu-index' argument to
> 'human-monitor-command',

It doesn't.  Perhaps we should add that as a future libvirt-qemu.so API
addition, although it's probably easier to just use QMP than HMP when
using 'virsh qemu-monitor-command' if HMP doesn't do what you want.

> it's possible to work around that
> limitation by building your own QMP command.  e.g.:
> 
>   # virsh qemu-monitor-command f26test '{"execute":"human-monitor-command", 
> "arguments":{"command-line":"info lapic", "cpu-index":1}}' | jq -r '.return'

Indeed, there's the use of QMP to work around the HMP deficiency.

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