From nobody Mon Feb 9 04:30:04 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 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=1565071099; cv=none; d=zoho.com; s=zohoarc; b=nFENsfeSHZuZaswIdkmWBqD3TplHIYwBFTXoxqfeHn+jXb10+Z3oH/eZfd4S/6hQT2WkBY79x/HDc+QWLsgk33vzZf9kMIQfdVO1c0fxN6mbMH/5zevknM3WyPw4K+FGrFPaCNZJd0NHvPMpvn7rN2drIZNHE5Hfez0ihc+zyqw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1565071099; h=Content-Type:Content-Transfer-Encoding:Cc: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:ARC-Authentication-Results; bh=NhqsF8fYA09CuDX2lc1dbjBuFr34GF79H94gQH07siM=; b=jIlMsi0ylO9lALt0iPOQv2zOb8WvSVsKeR/dUlGNET07fW5ttRDsYldnASSIVEEEabvlTe7zDR/i2T3QARa7Gume2RB8vtcs+tZJ5PKXuxDNf8g3sL4PxffKUPMFh7uSE4i6/0RfeFiRfQl89MZNU8GqdJutWsARPtdQQJJjZyk= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1565071099318327.25269601108755; Mon, 5 Aug 2019 22:58:19 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 1D3537FDFC; Tue, 6 Aug 2019 05:58:18 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id EB27557AA; Tue, 6 Aug 2019 05:58:17 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id B5BCF1800204; Tue, 6 Aug 2019 05:58:17 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x765qj2E028135 for ; Tue, 6 Aug 2019 01:52:45 -0400 Received: by smtp.corp.redhat.com (Postfix) id 54BE960610; Tue, 6 Aug 2019 05:52:45 +0000 (UTC) Received: from mx1.redhat.com (ext-mx10.extmail.prod.ext.phx2.redhat.com [10.5.110.39]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4EBEE60605 for ; Tue, 6 Aug 2019 05:52:43 +0000 (UTC) Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D0FD83C92D for ; Tue, 6 Aug 2019 05:52:42 +0000 (UTC) Received: by mail-wm1-f72.google.com with SMTP id f189so19759875wme.5 for ; Mon, 05 Aug 2019 22:52:42 -0700 (PDT) Received: from vitty.brq.redhat.com (ip-89-176-127-93.net.upcbroadband.cz. [89.176.127.93]) by smtp.gmail.com with ESMTPSA id i66sm156446020wmi.11.2019.08.05.22.52.39 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 05 Aug 2019 22:52:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=qOJBVqC8myFWjZkW0M4Rhj8XETnWM9XawTIJ7WtIO0g=; b=uSy0N1/lLgBoUJg5EPJy3XmRg997o//J0qYBXxi2wbuYP3eXReJtRBnIdwoTSDVIcY hrJeEIZDNqscMLJANmPrY9MRI6hU2SQHz8XZH2LdG0wyAL5swS4gJYgbKerhQNCnStwF d/0oxmfxL8V7zTmcEbk2p6m2+sXCakQKh13akR94yfRI6lv++HPBCgjVF+VNsL+pLMJB SKoxy/VAAqcNwHXSL+SIyv9/rlpH/veNddbl/L2u36lWFr+/BDheRhKXi/JXt8i342yV b80lGsKSAW1JbbBzO18RBW0o1O1htqI8GvMdQWEC7OD4qLfdmowkrJy6La+i9suhG03b n4sg== X-Gm-Message-State: APjAAAURQbQ2WcPMgDLCH4HNAdWQy+0RveqL89tZtqFEGFSRqV008N9W LDJKtiMSYnfXL7+9wIZuVTduRxtjQwBd1CnqpWdPoiCfakbLPOJLSV4fcedDTb+8JwnaKqcvaCn 6e1rw2ljGCfk22N3TclQ= X-Received: by 2002:adf:fdcc:: with SMTP id i12mr2291368wrs.88.1565070761251; Mon, 05 Aug 2019 22:52:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqyaDeWNqOlItaJwp01ZigzzVzQSBUBnYgGf48o4US5Z0UrmjXTmhHhBnciN101SagUJVYqMCw== X-Received: by 2002:adf:fdcc:: with SMTP id i12mr2291342wrs.88.1565070761021; Mon, 05 Aug 2019 22:52:41 -0700 (PDT) From: Vitaly Kuznetsov To: libvir-list@redhat.com Date: Tue, 6 Aug 2019 07:52:32 +0200 Message-Id: <20190806055236.31837-2-vkuznets@redhat.com> In-Reply-To: <20190806055236.31837-1-vkuznets@redhat.com> References: <20190806055236.31837-1-vkuznets@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: =?UTF-8?q?J=C3=A1n=20Tomko?= , Nikolay Shirokovskiy Subject: [libvirt] [PATCH v3 1/5] cpu_x86: add Edx to KVM_FEATURE_DEF() X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 06 Aug 2019 05:58:18 +0000 (UTC) Content-Type: text/plain; charset="utf-8" Some Hyper-V features (like the upcoming Direct Synthetic timers) are announced by feature bits in Edx but KVM_FEATURE_DEF() supports only Eax. Signed-off-by: Vitaly Kuznetsov Reviewed-by: J=C3=A1n Tomko --- src/cpu/cpu_x86.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/cpu/cpu_x86.c b/src/cpu/cpu_x86.c index b58eb2c9d8..d2d9537c32 100644 --- a/src/cpu/cpu_x86.c +++ b/src/cpu/cpu_x86.c @@ -59,9 +59,9 @@ struct _virCPUx86Feature { { .type =3D VIR_CPU_X86_DATA_CPUID, \ .data =3D { .cpuid =3D {__VA_ARGS__} } } =20 -#define KVM_FEATURE_DEF(Name, Eax_in, Eax) \ +#define KVM_FEATURE_DEF(Name, Eax_in, Eax, Edx) \ static virCPUx86DataItem Name ## _data[] =3D { \ - CPUID(.eax_in =3D Eax_in, .eax =3D Eax), \ + CPUID(.eax_in =3D Eax_in, .eax =3D Eax, .edx =3D Edx), \ } =20 #define KVM_FEATURE(Name) \ @@ -74,32 +74,32 @@ struct _virCPUx86Feature { } =20 KVM_FEATURE_DEF(VIR_CPU_x86_KVM_PV_UNHALT, - 0x40000001, 0x00000080); + 0x40000001, 0x00000080, 0x0); =20 KVM_FEATURE_DEF(VIR_CPU_x86_HV_RUNTIME, - 0x40000003, 0x00000001); + 0x40000003, 0x00000001, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_SYNIC, - 0x40000003, 0x00000004); + 0x40000003, 0x00000004, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_STIMER, - 0x40000003, 0x00000008); + 0x40000003, 0x00000008, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_RELAXED, - 0x40000003, 0x00000020); + 0x40000003, 0x00000020, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_VAPIC, - 0x40000003, 0x00000030); + 0x40000003, 0x00000030, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_VPINDEX, - 0x40000003, 0x00000040); + 0x40000003, 0x00000040, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_RESET, - 0x40000003, 0x00000080); + 0x40000003, 0x00000080, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_FREQUENCIES, - 0x40000003, 0x00000800); + 0x40000003, 0x00000800, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_REENLIGHTENMENT, - 0x40000003, 0x00002000); + 0x40000003, 0x00002000, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_TLBFLUSH, - 0x40000004, 0x00000004); + 0x40000004, 0x00000004, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_IPI, - 0x40000004, 0x00000400); + 0x40000004, 0x00000400, 0x0); KVM_FEATURE_DEF(VIR_CPU_x86_HV_EVMCS, - 0x40000004, 0x00004000); + 0x40000004, 0x00004000, 0x0); =20 static virCPUx86Feature x86_kvm_features[] =3D { --=20 2.20.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list