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

Re: [Xen-devel] [PATCH] xen: Add command line option to enable ASID support -- on by default



On Wed, 2012-03-07 at 18:07 +0000, Keir Fraser wrote:
> On 07/03/2012 17:58, "George Dunlap" <george.dunlap@xxxxxxxxxxxxx> wrote:
> 
> > Signed-off-by: George Dunlap <george.dunlap@xxxxxxxxxxxxx>
> 
> Why would you want to be able to disable the feature?

Well at very least to measure the performance benefit (or overhead) of
using the feature.  There may be hardware in the future where ASIDs may
cause problems; who knows.

AFAICT this isn't documented anywhere, so if you really don't want Yet
Another Option, we could probably get rid of it from the XenServer
patchqueue.  But I didn't see any harm in it; and you never know when
the flexibility of disabling something without recompiling will come in
handy.

 -George

> 
>  -- Keir
> 
> > diff --git a/xen/arch/x86/hvm/svm/asid.c b/xen/arch/x86/hvm/svm/asid.c
> > --- a/xen/arch/x86/hvm/svm/asid.c
> > +++ b/xen/arch/x86/hvm/svm/asid.c
> > @@ -24,12 +24,16 @@
> >  #include <asm/amd.h>
> >  #include <asm/hvm/nestedhvm.h>
> >  
> > +/* Xen command-line option to enable ASIDs */
> > +static int opt_asid_enabled = 1;
> > +boolean_param("asid", opt_asid_enabled);
> > +
> >  void svm_asid_init(struct cpuinfo_x86 *c)
> >  {
> >      int nasids = 0;
> >  
> >      /* Check for erratum #170, and leave ASIDs disabled if it's present. */
> > -    if ( !cpu_has_amd_erratum(c, AMD_ERRATUM_170) )
> > +    if ( opt_asid_enabled && !cpu_has_amd_erratum(c, AMD_ERRATUM_170) )
> >          nasids = cpuid_ebx(0x8000000A);
> >  
> >      hvm_asid_init(nasids);
> > 
> > _______________________________________________
> > Xen-devel mailing list
> > Xen-devel@xxxxxxxxxxxxx
> > http://lists.xen.org/xen-devel
> 
> 



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.