Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1109217ybl; Thu, 12 Dec 2019 09:45:37 -0800 (PST) X-Google-Smtp-Source: APXvYqzK8SVKnvG4kWpTOMWk3QwdIUGM2VMZacwPtci606U7Ove9YynJTZZMk1Fyi0El3Ntud/zA X-Received: by 2002:a05:6830:1501:: with SMTP id k1mr9744086otp.209.1576172737717; Thu, 12 Dec 2019 09:45:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576172737; cv=none; d=google.com; s=arc-20160816; b=FaxIaqiuzoEaVbHeE/8EJfDSoTuAJpg/bgnyavp3YGAdnBvveuD5ZpjMqDRMgdT3Sr 8cQJ8LOv4Pnj0+dyMVHBGW56loiXXhoOsaaJI/YtW3JuAQf8uK4aksMCRkTDVu77t0QW wIYMrKr6omqkWd6gx4QSFE9zy9PW5FTQX2vZ1/ZS5sAAttqGaxodbYlYgp9kiEt37/qi I+Pkn91TJ8E9uTTCJsXYd7y38/AKsnf7Qgz+6YFI+T7PeWknNxhzRHn6E81yf6Q4/Pm5 tBGNfuHIVDIaum6JQVMVXMwQQX0hRpFeIrrs3lmgnGC8uzfx5qGJ2DNCsdsVmcftBNcl 9xug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=9NaHv54/LY1Yc2ptHmzPuoN5zpZwvLlYQ+y1taI5A50=; b=ICGUpqkP7XTGnrKi01ZK6B9xFZEoESKuh9o91oE/3yEZ5OdIH56RGeMnmX5xw7xAx+ KRMyQTSG6oxjpSLWlsdoUrTbxC8g/aIMt/yOltwft3LakpGsNCQSrB+0V56FE0YnBUOC M3/6o9JdnyoMS8cxBAuAuv/XOjs0ymqhnoufH7kAfmqXOZnmvZtSJvoe5SvR3v9hGklk KdPz8JfpmXE5oPqV2ysmlmG8ef0ZvhK7Pomajo8t52ua7dP2e6WEz9w/3hy68MLPcJ8X GzcPLugcVcreDlMUAKI/CDyICtuj/Zm9m40uHq0UPOCuMduTAzwCxABo73+NygRjeMAd /mfA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k138si3497195oih.175.2019.12.12.09.45.19; Thu, 12 Dec 2019 09:45:37 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730034AbfLLRoA (ORCPT + 99 others); Thu, 12 Dec 2019 12:44:00 -0500 Received: from mga18.intel.com ([134.134.136.126]:32104 "EHLO mga18.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730235AbfLLRn6 (ORCPT ); Thu, 12 Dec 2019 12:43:58 -0500 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Dec 2019 09:43:57 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,306,1571727600"; d="scan'208";a="216367838" Received: from sjchrist-coffee.jf.intel.com (HELO linux.intel.com) ([10.54.74.202]) by orsmga003.jf.intel.com with ESMTP; 12 Dec 2019 09:43:57 -0800 Date: Thu, 12 Dec 2019 09:43:57 -0800 From: Sean Christopherson To: Paolo Bonzini Cc: Liran Alon , Borislav Petkov , Thomas Gleixner , Ingo Molnar , x86@kernel.org, "H. Peter Anvin" , Peter Zijlstra , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Radim =?utf-8?B?S3LEjW3DocWZ?= , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , Tony Luck , Tony W Wang-oc , Len Brown , Shuah Khan , linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-edac@vger.kernel.org, linux-pm@vger.kernel.org, linux-kselftest@vger.kernel.org, Jarkko Sakkinen Subject: Re: [PATCH v4 11/19] x86/cpu: Print VMX flags in /proc/cpuinfo using VMX_FEATURES_* Message-ID: <20191212174357.GE3163@linux.intel.com> References: <20191128014016.4389-1-sean.j.christopherson@intel.com> <20191128014016.4389-12-sean.j.christopherson@intel.com> <20191212122646.GE4991@zn.tnic> <4A24DE75-4E68-4EC6-B3F3-4ACB0EE82BF0@oracle.com> <17c6569e-d0af-539c-6d63-f4c07367d8d1@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <17c6569e-d0af-539c-6d63-f4c07367d8d1@redhat.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Dec 12, 2019 at 04:57:10PM +0100, Paolo Bonzini wrote: > On 12/12/19 16:52, Liran Alon wrote: > >>> virt_apic_accesses -> vapic > >> apicv > > Frankly, I dislike APICv terminology. I prefer to enumerate the > > various VMX features which are collectively called APICv by KVM. > > APICv currently represents in KVM terminology the combination of > > APIC-register virtualization, virtual-interrupt-delivery and > > posted-interrupts (See cpu_has_vmx_apicv()). > > > > In fact, the coupling of “enable_apicv” module parameter have made me > > multiple times to need to disable entire APICv features when there > > for example was only a bug in posted-interrupts. > > > > Even you got confused as virtualize-apic-access is not part of KVM’s > > APICv terminology but rather it’s enablement depend on > > flexpriority_enabled (See cpu_need_virtualize_apic_accesses()). i.e. > > It can be used for faster intercept handling of accesses to guest > > xAPIC MMIO page. > > Right, I got confused with APIC-register virtualization. Virtualize > APIC accesses is another one I wouldn't bother putting in /proc/cpuinfo, > since it's usually present together with flexpriority. Key word being "usually". My intent in printing out partially redundant flags was to help users debug/understand why the combined feature isn't supported. E.g. userspace can already easily (relatively speaking) query flexpriority support via /sys/module/kvm_intel/parameters/flexpriority. But if that comes back "N", the user has no way to determine exactly why flexpriority is disabled.