[PATCH v4 5/9] target/i386/kvm: Drop workaround for KVM_X86_DISABLE_EXITS_HTL typo

Zhao Liu posted 9 patches 2 months ago
Maintainers: "Michael S. Tsirkin" <mst@redhat.com>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, Paolo Bonzini <pbonzini@redhat.com>, Richard Henderson <richard.henderson@linaro.org>, Eduardo Habkost <eduardo@habkost.net>, Marcelo Tosatti <mtosatti@redhat.com>
[PATCH v4 5/9] target/i386/kvm: Drop workaround for KVM_X86_DISABLE_EXITS_HTL typo
Posted by Zhao Liu 2 months ago
The KVM_X86_DISABLE_EXITS_HTL typo has been fixed in commit
77d361b13c19 ("linux-headers: Update to kernel mainline commit
b357bf602").

Drop the related workaround.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
---
 target/i386/kvm/kvm.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
index 64e54beac7b3..4aae4ffc9ccd 100644
--- a/target/i386/kvm/kvm.c
+++ b/target/i386/kvm/kvm.c
@@ -2728,10 +2728,6 @@ int kvm_arch_init(MachineState *ms, KVMState *s)
 
     if (enable_cpu_pm) {
         int disable_exits = kvm_check_extension(s, KVM_CAP_X86_DISABLE_EXITS);
-/* Work around for kernel header with a typo. TODO: fix header and drop. */
-#if defined(KVM_X86_DISABLE_EXITS_HTL) && !defined(KVM_X86_DISABLE_EXITS_HLT)
-#define KVM_X86_DISABLE_EXITS_HLT KVM_X86_DISABLE_EXITS_HTL
-#endif
         if (disable_exits) {
             disable_exits &= (KVM_X86_DISABLE_EXITS_MWAIT |
                               KVM_X86_DISABLE_EXITS_HLT |
-- 
2.34.1
Re: [PATCH v4 5/9] target/i386/kvm: Drop workaround for KVM_X86_DISABLE_EXITS_HTL typo
Posted by Chen, Zide 1 month, 4 weeks ago

On 7/16/2024 9:10 AM, Zhao Liu wrote:
> The KVM_X86_DISABLE_EXITS_HTL typo has been fixed in commit
> 77d361b13c19 ("linux-headers: Update to kernel mainline commit
> b357bf602").
> 
> Drop the related workaround.
> 
> Signed-off-by: Zhao Liu <zhao1.liu@intel.com>

Reviewed-by: Zide Chen <zide.chen@intel.com>

> ---
>  target/i386/kvm/kvm.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
> index 64e54beac7b3..4aae4ffc9ccd 100644
> --- a/target/i386/kvm/kvm.c
> +++ b/target/i386/kvm/kvm.c
> @@ -2728,10 +2728,6 @@ int kvm_arch_init(MachineState *ms, KVMState *s)
>  
>      if (enable_cpu_pm) {
>          int disable_exits = kvm_check_extension(s, KVM_CAP_X86_DISABLE_EXITS);
> -/* Work around for kernel header with a typo. TODO: fix header and drop. */
> -#if defined(KVM_X86_DISABLE_EXITS_HTL) && !defined(KVM_X86_DISABLE_EXITS_HLT)
> -#define KVM_X86_DISABLE_EXITS_HLT KVM_X86_DISABLE_EXITS_HTL
> -#endif
>          if (disable_exits) {
>              disable_exits &= (KVM_X86_DISABLE_EXITS_MWAIT |
>                                KVM_X86_DISABLE_EXITS_HLT |