Re: [RFC PATCH 2/3] x86/cpufeatures: Combine word 11 and 12 into new scattered features word 11

From: Borislav Petkov
Date: Fri Jun 14 2019 - 10:26:36 EST


On Fri, Jun 14, 2019 at 07:14:24AM -0700, Sean Christopherson wrote:
> This is wrong. KVM isn't complaining about shuffling the order of feature
> words, it's complaining that code is trying to do a reverse CPUID lookup
> to a feature that isn't in the reverse_cpuid table. Filtering out
> checks dynamically is just hiding bugs.

No no, reverse_cpuid is hardcoding our feature leafs. This is wrong as
we want to be able to change those. And reverse_cpuid[] should be able
to handle that.

KVM is complaining because he removed one leaf. He adds it later in
patch 3 as a Linux-defined leaf.

All that doesn't matter for KVM - if KVM wants to do reverse lookup,
then it should handle Linux-defined leafs just fine.

--
Regards/Gruss,
Boris.

Good mailing practices for 400: avoid top-posting and trim the reply.