From: Radim Krcmar <rkrcmar@redhat.com>
To: Janakarajan Natarajan <Janakarajan.Natarajan@amd.com>
Cc: kvm@vger.kernel.org, x86@kernel.org,
linux-kernel@vger.kernel.org,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, "H . Peter Anvin" <hpa@zytor.com>,
Paolo Bonzini <pbonzini@redhat.com>,
Len Brown <len.brown@intel.com>, Kyle Huey <me@kylehuey.com>,
Tom Lendacky <thomas.lendacky@amd.com>,
Borislav Petkov <bp@suse.de>,
Grzegorz Andrejczuk <grzegorz.andrejczuk@intel.com>,
Kan Liang <Kan.liang@intel.com>
Subject: Re: [PATCH v4 3/3] x86/kvm: Expose AMD Core Perf Extension flag to guests
Date: Mon, 5 Feb 2018 14:43:24 +0100 [thread overview]
Message-ID: <20180205134321.GD27896@flask> (raw)
In-Reply-To: <f481ade083edd15c0f5850babaeef378ab06ffce.1517333237.git.Janakarajan.Natarajan@amd.com>
2018-01-30 11:32-0600, Janakarajan Natarajan:
> Expose the AMD Core Perf Extension flag to the guests.
>
> Signed-off-by: Janakarajan Natarajan <Janakarajan.Natarajan@amd.com>
> ---
> diff --git a/arch/x86/kvm/cpuid.c b/arch/x86/kvm/cpuid.c
> @@ -365,7 +371,7 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function,
> F(LAHF_LM) | F(CMP_LEGACY) | 0 /*SVM*/ | 0 /* ExtApicSpace */ |
> F(CR8_LEGACY) | F(ABM) | F(SSE4A) | F(MISALIGNSSE) |
> F(3DNOWPREFETCH) | F(OSVW) | 0 /* IBS */ | F(XOP) |
> - 0 /* SKINIT, WDT, LWP */ | F(FMA4) | F(TBM);
> + 0 /* SKINIT, WDT, LWP */ | F(FMA4) | F(TBM) | f_perfext;
You can just say F(PERFCTR_CORE) here. The conditional features are
needed when there is a runtime config option for them. We are
automatically masking features that the host doesn't support,
thanks.
>
> /* cpuid 0xC0000001.edx */
> const u32 kvm_cpuid_C000_0001_edx_x86_features =
> --
> 2.7.4
>
next prev parent reply other threads:[~2018-02-05 13:43 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-30 17:32 [PATCH v4 0/3] Support Perf Extensions on AMD KVM guests Janakarajan Natarajan
2018-01-30 17:32 ` [PATCH v4 1/3] x86/msr: Add AMD Core Perf Extension MSRs Janakarajan Natarajan
2018-01-30 17:32 ` [PATCH v4 2/3] x86/kvm: Add support for AMD Core Perf Extension in guest Janakarajan Natarajan
2018-01-30 17:32 ` [PATCH v4 3/3] x86/kvm: Expose AMD Core Perf Extension flag to guests Janakarajan Natarajan
2018-02-02 20:03 ` [RFC PATCH] x86/kvm: perf_ext_supported() can be static kbuild test robot
2018-02-02 20:03 ` [PATCH v4 3/3] x86/kvm: Expose AMD Core Perf Extension flag to guests kbuild test robot
2018-02-02 23:26 ` Natarajan, Janakarajan
2018-02-05 13:43 ` Radim Krcmar [this message]
2018-02-05 17:48 ` Natarajan, Janakarajan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180205134321.GD27896@flask \
--to=rkrcmar@redhat.com \
--cc=Janakarajan.Natarajan@amd.com \
--cc=Kan.liang@intel.com \
--cc=bp@suse.de \
--cc=grzegorz.andrejczuk@intel.com \
--cc=hpa@zytor.com \
--cc=kvm@vger.kernel.org \
--cc=len.brown@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=me@kylehuey.com \
--cc=mingo@redhat.com \
--cc=pbonzini@redhat.com \
--cc=tglx@linutronix.de \
--cc=thomas.lendacky@amd.com \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox