[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast
From: |
Viktor Mihajlovski |
Subject: |
Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast |
Date: |
Fri, 9 Feb 2018 08:56:19 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 08.02.2018 21:33, Eduardo Habkost wrote:
> On Thu, Feb 08, 2018 at 11:17:32AM -0500, Luiz Capitulino wrote:
> [...]
>> The "halted" field is somewhat controversial. On the one hand,
>> it offers a convenient way to know if a guest CPU is idle or
>> running. On the other hand, it's a field that can change many
>> times a second. In fact, the halted state can change even
>> before query-cpus-fast has returned. This makes one wonder if
>> this field should be dropped all together. Having the "halted"
>> field as optional gives a better option for dropping it in
>> the future, since we can just stop returning it.
>
> I'd just drop it, unless we find a use case where it's really
> useful.
>
> Also, the code that sets/clears cpu->halted is target-specific,
> so I wouldn't be so sure that simply checking for
> !kvm_irqchip_in_kernel() is enough on all targets.
>
Right, the present patch effectively disables halted anyway (including
s390). So it may be cleaner to just drop it right now.
Assuming the presence of architecure-specific data, libvirt can derive a
halted state (or an equivalent thereof) from query-cpus-fast returned
information.
--
Regards,
Viktor Mihajlovski
- [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Luiz Capitulino, 2018/02/08
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Eduardo Habkost, 2018/02/08
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast,
Viktor Mihajlovski <=
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Luiz Capitulino, 2018/02/09
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Viktor Mihajlovski, 2018/02/09
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Eduardo Habkost, 2018/02/09
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Viktor Mihajlovski, 2018/02/09
- Re: [Qemu-devel] [PATCH v2] qmp: add query-cpus-fast, Luiz Capitulino, 2018/02/09