qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] i386: Enable NPT and NRIPSAVE for AMD CPUs


From: Eduardo Habkost
Subject: Re: [Qemu-devel] [PATCH] i386: Enable NPT and NRIPSAVE for AMD CPUs
Date: Fri, 18 Jan 2019 14:38:56 -0200
User-agent: Mutt/1.10.1 (2018-07-13)

On Thu, Jan 03, 2019 at 11:02:34AM +0100, Vitaly Kuznetsov wrote:
> Modern AMD CPUs support NPT and NRIPSAVE features and KVM exposes these
> when present. NRIPSAVE apeared somewhere in Opteron_G3 lifetime (e.g.
> QuadCore AMD Opteron 2378 has is but QuadCore AMD Opteron HE 2344 doesn't),
> NPT was introduced a bit earlier.
> 
> Add the FEAT_SVM leaf to Opteron_G4/G5 and EPYC/EPYC-IBPB cpu models.
> 
> Signed-off-by: Vitaly Kuznetsov <address@hidden>
> ---
>  target/i386/cpu.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/target/i386/cpu.c b/target/i386/cpu.c
> index 677a3bd5fb..eb8f9079a6 100644
> --- a/target/i386/cpu.c
> +++ b/target/i386/cpu.c
> @@ -2766,6 +2766,8 @@ static X86CPUDefinition builtin_x86_defs[] = {
>              CPUID_EXT3_3DNOWPREFETCH | CPUID_EXT3_MISALIGNSSE |
>              CPUID_EXT3_SSE4A | CPUID_EXT3_ABM | CPUID_EXT3_SVM |
>              CPUID_EXT3_LAHF_LM,
> +        .features[FEAT_SVM] =
> +            CPUID_SVM_NPT | CPUID_SVM_NRIPSAVE,

Same issue as the previous EPYC patch: you need npt=off and
nrip-save=off on pc_compat_3_1.

(Sorry again for taking so long to review this)

> [...]

-- 
Eduardo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]