Re: [PATCH v6 3/3] KVM: selftests: Add self IPI HLT test

Manali Shukla
2025-02-28T15:05:30Z

Hi Sean,

Thank you for reviewing my patches.

On 2/26/2025 6:08 AM, Sean Christopherson wrote:
> On Tue, Jan 28, 2025, Manali Shukla wrote:
>> + if (kvm_cpu_has(X86_FEATURE_IDLE_HLT))
>
> Well, shoot. I gave you bad input, and we're stuck.
>
> this_cpu_has() isn't correct, because the part of my previous feedback about
> needing to check *KVM* support was 100% correct. But kvm_cpu_has() isn't right
> either, because that checks what KVM supports exposing to the guest, not what
> KVM itself supports/uses. E.g. even if we add full nested support, the test would
> fail if nested=0 due to KVM not "supporting" Idle HLT despite using it under the
> hood.
>
> The lack of a way for KVM to communicate support to the user has come up in the
> past, e.g. in discussion around /proc/cpuinfo. Sadly, AFAIK there are no (good)
> ideas on what that should look like.
>
> For now, I'll just skip this patch, even though doing so makes me quite sad.

I understand your point.

-Manali