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

Re: [Xen-devel] APIC MSRs query


  • To: Jan Beulich <JBeulich@xxxxxxxxxx>, Ian Campbell <Ian.Campbell@xxxxxxxxxx>
  • From: Keir Fraser <keir.xen@xxxxxxxxx>
  • Date: Tue, 17 May 2011 15:53:46 +0100
  • Cc: Andrew Cooper <Andrew.Cooper3@xxxxxxxxxx>, xen devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Tue, 17 May 2011 07:54:59 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=user-agent:date:subject:from:to:cc:message-id:thread-topic :thread-index:in-reply-to:mime-version:content-type :content-transfer-encoding; b=WsEQ+Olalco0cfEKiHMFk9XFFA06IE2TYtk8AKO39P4mV7xFh5ZYfgvHx1/QLzZRa3 KWyCceG1LjRGew5CcsjRLc8Qji+zcZAcP5a6IWLDZqeRnhDADOkNwdLeUTjIvgNh8Seo DcKPvOM6Rj2RTIeJukv7l5Y9z4OI6ilhc37tA=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>
  • Thread-index: AcwUojj4Eq8vPhYccEqF4pr+Q0ucfg==
  • Thread-topic: [Xen-devel] APIC MSRs query

On 17/05/2011 15:08, "Jan Beulich" <JBeulich@xxxxxxxxxx> wrote:

>>> I think this is a benign mistake. Benign because I don't think there is
>>> a meaningful (to Xen at least) number of systems that would not
>>> have their LAPIC at the default address (which fits in 32 bits).
>> 
>> That "msr_content = (uint32_t)msr_content;" seems to be pretty
>> deliberate, what else would it be trying to do?
>> 
>> FWIW enable_x2apic in Linux seems to have a similar construct which
>> throws away the top half of the MSR:
> 
> Surely the Xen code got cloned from the Linux one.

If you actually look at the change in 21669:b622e411, you can see that the
above line is deliberate. The old code did wrmsr(msr, lo, 0), and clearing
upper 32 bits before calling wrmsrl() is the equivalent of that.

So this should not be 'cleaned up' without understanding that old code
(which almost certainly itself comes from Linux).

And I should also warn that I will simply ignore gratuitous cleanups in the
APIC code. The code is mostly Linux sourced, I'd rather we synced again than
diverge further.

 -- Keir



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

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