[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230208204230.1360502-1-seanjc@google.com>
Date: Wed, 8 Feb 2023 20:42:28 +0000
From: Sean Christopherson <seanjc@...gle.com>
To: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Sean Christopherson <seanjc@...gle.com>,
Paolo Bonzini <pbonzini@...hat.com>
Cc: Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...nel.org>,
Namhyung Kim <namhyung@...nel.org>,
linux-perf-users@...r.kernel.org, linux-kernel@...r.kernel.org,
kvm@...r.kernel.org, Jianfeng Gao <jianfeng.gao@...el.com>,
Andrew Cooper <Andrew.Cooper3@...rix.com>,
Kan Liang <kan.liang@...ux.intel.com>,
Andi Kleen <ak@...ux.intel.com>
Subject: [PATCH v2 0/2] perf/x86: KVM: Disable vPMU on hybrid CPUs
Disable vPMU support in KVM when running on hybrid CPUs to avoid inducing
#GPs and other issues in guests. This is intended to be a stopgap to
prevent unwitting KVM users from shooting themselves in the foot until KVM
KVM gets proper enabling for hybrid CPUs.
Effectively squash exporting PMU capabilities from perf until it too gets
proper enabling.
v2:
- Disable vPMU on hybrid CPUs in KVM _and_ in perf. [Like]
- Use X86_FEATURE_HYBRID_CPU instead of is_hybrid().
- Tweak comments/changelogs to more clearly state that there are options
beyond pinning vCPUs (though they still need KVM support). [Like]
v1: https://lore.kernel.org/all/20230120004051.2043777-1-seanjc@google.com
Sean Christopherson (2):
KVM: x86/pmu: Disable vPMU support on hybrid CPUs (host PMUs)
perf/x86: Refuse to export capabilities for hybrid PMUs
arch/x86/events/core.c | 14 ++++++++------
arch/x86/kvm/pmu.h | 26 +++++++++++++++++++-------
2 files changed, 27 insertions(+), 13 deletions(-)
base-commit: 7cb79f433e75b05d1635aefaa851cfcd1cb7dc4f
--
2.39.1.519.gcb327c4b5f-goog
Powered by blists - more mailing lists