qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v13 3/5] i386: Enable TOPOEXT feature on AMD EPY


From: Moger, Babu
Subject: Re: [Qemu-devel] [PATCH v13 3/5] i386: Enable TOPOEXT feature on AMD EPYC CPU
Date: Mon, 11 Jun 2018 21:01:07 +0000


> -----Original Message-----
> From: Eduardo Habkost [mailto:address@hidden
> Sent: Monday, June 11, 2018 3:51 PM
> To: Moger, Babu <address@hidden>
> Cc: address@hidden; address@hidden; address@hidden;
> address@hidden; address@hidden; address@hidden;
> address@hidden; address@hidden; address@hidden
> Subject: Re: [PATCH v13 3/5] i386: Enable TOPOEXT feature on AMD EPYC
> CPU
> 
> On Fri, Jun 08, 2018 at 06:56:19PM -0400, Babu Moger wrote:
> > Enable TOPOEXT feature on EPYC CPU. This is required to support
> > hyperthreading on VM guests. Also extend xlevel to 0x8000001E.
> >
> > TOPOEXT feature is disabled for legacy machines.
> >
> > Signed-off-by: Babu Moger <address@hidden>
> > ---
> >  target/i386/cpu.c | 7 +++++++
> >  1 file changed, 7 insertions(+)
> >
> > diff --git a/target/i386/cpu.c b/target/i386/cpu.c
> > index d3411ed..4dd9a82 100644
> > --- a/target/i386/cpu.c
> > +++ b/target/i386/cpu.c
> > @@ -2574,6 +2574,7 @@ static X86CPUDefinition builtin_x86_defs[] = {
> >          .xlevel = 0x8000000A,
> >          .model_id = "AMD EPYC Processor",
> >          .cache_info = &epyc_cache_info,
> > +        .auto_topoext = 1,
> >      },
> >      {
> >          .name = "EPYC-IBPB",
> > @@ -2621,6 +2622,7 @@ static X86CPUDefinition builtin_x86_defs[] = {
> >          .xlevel = 0x8000000A,
> >          .model_id = "AMD EPYC Processor (with IBPB)",
> >          .cache_info = &epyc_cache_info,
> > +        .auto_topoext = 1,
> >      },
> >  };
> >
> > @@ -4672,6 +4674,11 @@ static void x86_cpu_expand_features(X86CPU
> *cpu, Error **errp)
> >              x86_cpu_adjust_level(cpu, &env->cpuid_min_xlevel, 0x8000000A);
> >          }
> >
> > +        /* TOPOEXT feature requires 0x8000001E */
> > +        if (env->features[FEAT_8000_0001_ECX] & CPUID_EXT3_TOPOEXT) {
> > +            x86_cpu_adjust_level(cpu, &env->cpuid_min_xlevel, 0x8000001E);
> > +        }
> 
> I suggest moving this hunk to a separate patch.  I'm not 100%

Sure. Will move it to separate patch.

> sure yet if this will require compat_props code to disable
> auto-xlevel-increase on older machine-types.
> 
> --
> Eduardo



reply via email to

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