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

Re: [Xen-devel] [PATCH 2/2] x86/HVM: adjust feature checking in MSR intercept handling



> From: Jan Beulich [mailto:JBeulich@xxxxxxxx]
> Sent: Wednesday, September 07, 2016 3:59 PM
> 
> >>> On 07.09.16 at 07:36, <kevin.tian@xxxxxxxxx> wrote:
> >>  From: Jan Beulich [mailto:JBeulich@xxxxxxxx]
> >> Sent: Friday, September 02, 2016 6:22 PM
> >>
> >> Consistently consult hvm_cpuid(). With that, BNDCFGS gets better
> >> handled outside of VMX specific code, just like XSS. Don't needlessly
> >> check for MTRR support when the MSR being accessed clearly is not an
> >> MTRR one.
> >>
> >> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
> >>
> >
> > A nice cleanup. Just one comment:
> >
> >> @@ -3824,9 +3850,8 @@ int hvm_msr_write_intercept(unsigned int
> >>          break;
> >>
> >>      case MSR_MTRRcap:
> >> -        if ( !mtrr )
> >> -            goto gp_fault;
> >>          goto gp_fault;
> >> +
> >
> > what's point of removing above mtrr check?
> 
> Isn't that obvious: No matter what value "mtrr" has, we
> "goto gp_fault".
> 

you are right. Sorry I simply looked at same condition checks for
other MTRR registers while didn't think about its actual meaning here.

Acked-by: Kevin Tian <kevin.tian@xxxxxxxxx>

Thanks
Kevin

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

 


Rackspace

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