From nobody Sun Feb 8 19:56:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1667912712; cv=none; d=zohomail.com; s=zohoarc; b=k8wS/4sCKzcRPFVOPm4zCXTmFmSQFsrGBQ+2zhdopTidIZJzDha1CnVrHIWFGCZ3r4BFtBwJj5RrQhblS/jVeN0FbXd/e2XjmtQMhqnjrsJHmve3cuaFoYiWWUF8gepDbl/RNKe0dOEKWpJk6JxbxgT3l+upi96XYCFO5Fjcs6c= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1667912712; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=MuL1DmEZ8gM8KRSRQ4XbQh4tIiYyvqaygrAC9cPrKyY=; b=Lcf7/pjckJcD0YfTNz0n4YFlvW1IP+fXpE8c52nnyyu6PbVJOTRpWgBLD2k8skgGjoBFi528WstUI1JykIZq4t7nscxFrjNCsE4BxQXgQ5pqWXuZgNaMywofxBg3HclfNy5fO4XNqA6t0OqaC0XesmGeM56ippOxWl7MiQH3wh8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1667912712064352.6964449389052; Tue, 8 Nov 2022 05:05:12 -0800 (PST) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-427-ZcK8A5UQMJuwdbNXZMEzgA-1; Tue, 08 Nov 2022 08:02:53 -0500 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B244F800B30; Tue, 8 Nov 2022 13:02:07 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (unknown [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9B3AE475063; Tue, 8 Nov 2022 13:02:07 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 84073193769A; Tue, 8 Nov 2022 13:02:07 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 1625C1926FFF for ; Tue, 8 Nov 2022 13:02:06 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 012084C819; Tue, 8 Nov 2022 13:02:06 +0000 (UTC) Received: from speedmetal.redhat.com (ovpn-208-16.brq.redhat.com [10.40.208.16]) by smtp.corp.redhat.com (Postfix) with ESMTP id 579067AE5 for ; Tue, 8 Nov 2022 13:02:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1667912711; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=MuL1DmEZ8gM8KRSRQ4XbQh4tIiYyvqaygrAC9cPrKyY=; b=Xxe0/3SMd57jr7XzGBgdqe7hkFoXpwlGsFzkLelIrl+cBiockRz1Cyq/nSI44tYHi4Dqtf izs3+tPLH52LeR4+S3NsuhInSIB528MRaqyEExUEhYCO4zN2RfLY7HbCvlc9o6++lfD+rG ithiTk+vr8kibZJPdsMNfBoiVqpXHiU= X-MC-Unique: ZcK8A5UQMJuwdbNXZMEzgA-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 3/4] cpu: x86: Introduce the 'hv-avic' feature Date: Tue, 8 Nov 2022 14:02:00 +0100 Message-Id: <1ede786bdc05c7d467978325f2742e3dda53dbe3.1667912490.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.9 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1667912734376100001 Content-Type: text/plain; charset="utf-8" Based on qemu commit e1f9a8e8c90ae54387922e33e5ac4fd759747d01 introduce the hv-avic feature in leaf 0x40000004, EAX 0x00000200 (1 << 9). Signed-off-by: Peter Krempa --- src/cpu/cpu_x86.c | 3 +++ src/cpu/cpu_x86_data.h | 1 + 2 files changed, 4 insertions(+) diff --git a/src/cpu/cpu_x86.c b/src/cpu/cpu_x86.c index 034d25bf60..b3f76f3d79 100644 --- a/src/cpu/cpu_x86.c +++ b/src/cpu/cpu_x86.c @@ -100,6 +100,8 @@ KVM_FEATURE_DEF(VIR_CPU_x86_HV_STIMER_DIRECT, KVM_FEATURE_DEF(VIR_CPU_x86_HV_TLBFLUSH, 0x40000004, 0x00000004, 0x0); +KVM_FEATURE_DEF(VIR_CPU_x86_HV_AVIC, + 0x40000004, 0x00000200, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_IPI, 0x40000004, 0x00000400, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_EVMCS, @@ -118,6 +120,7 @@ static virCPUx86Feature x86_kvm_features[] =3D KVM_FEATURE(VIR_CPU_x86_HV_FREQUENCIES), KVM_FEATURE(VIR_CPU_x86_HV_REENLIGHTENMENT), KVM_FEATURE(VIR_CPU_x86_HV_TLBFLUSH), + KVM_FEATURE(VIR_CPU_x86_HV_AVIC), KVM_FEATURE(VIR_CPU_x86_HV_IPI), KVM_FEATURE(VIR_CPU_x86_HV_EVMCS), KVM_FEATURE(VIR_CPU_x86_HV_STIMER_DIRECT), diff --git a/src/cpu/cpu_x86_data.h b/src/cpu/cpu_x86_data.h index 9a4333bf2b..d1ca63db6d 100644 --- a/src/cpu/cpu_x86_data.h +++ b/src/cpu/cpu_x86_data.h @@ -61,6 +61,7 @@ struct _virCPUx86MSR { #define VIR_CPU_x86_HV_TLBFLUSH "hv-tlbflush" #define VIR_CPU_x86_HV_IPI "hv-ipi" #define VIR_CPU_x86_HV_EVMCS "hv-evmcs" +#define VIR_CPU_x86_HV_AVIC "hv-avic" /* Hyper-V Synthetic Timer option */ #define VIR_CPU_x86_HV_STIMER_DIRECT "hv-stimer-direct" --=20 2.37.3