[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 15:50:00 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 09.02.2018 15:27, Eduardo Habkost wrote:
[...]
>> I'm keeping it mainly for s390. Viktor, libvirt is still using
>> this field in s390, no?
>>
>> Dropping halted and having management software still using query-cpus
>> because of halted would be a total failure of query-cpus-fast.
>
> If I understood correctly, the CpuInfoS390::cpu_state field added
> by Viktor in another patch[1] would replace "halted" for the s390
> case.
Right, CPUState.halted is derived from CPUS390XState.cpu_state on s390:
A cpu_state of CPU_STATE_STOPPED or CPU_STATE_CHECK_STOPPED results in
halted = true. This derivation can be done by libvirt for s390.
>
> I'm assuming QEMU will be able to return that field without
> interrupting the VCPUs. Viktor, is that correct?
>
> [1] https://lists.gnu.org/archive/html/qemu-devel/2018-02/msg02032.html
>
That's correct.
>>
>>>> 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.
>>
>> I checked the code and had the impression it was enough, but
>> I don't have experience with other archs. So, would be nice
>> if other archs maintainers could review this. I'll try to ping them.
>
> I think we need to take a step back and rethink:
>
> 1) What the field is supposed to mean? The semantics of "halted"
> are completely unclear. What exactly we want to communicate
> to libvirt/management?
> 2) On which cases the information (whatever it means) is really
> useful/important? If you are excluding cases with in-kernel
> irqchip, you are already excluding most users.
>
>
Given that nobody (including myself) sees a need for halted we can
remove it for the fast version of query-cpus without surprising anyone.
[...]
--
Regards,
Viktor Mihajlovski