WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Porting of Guest OS

Ronald G. Minnich wrote:
On Fri, 31 Dec 2004, David Hopwood wrote:

It should be possible to make it work by using the hypervisor interface
equivalents of rdmsr/wrmsr. See section 9.11 of the IA32 architecture
manual Volume 3.

<http://developer.intel.com/design/pentium4/manuals/index_new.htm>
<ftp://download.intel.com/design/Pentium4/manuals/25366814.pdf>

interesting. Part of the microcode upgrade process is pointing the CPU at a chunk of memory that it ingests as the new microcode. I found the whole business a bit dicey to think about from ring 1, but I guess it ought to be fine.

I really shouldn't post at that time of the morning. First, it should have
been obvious that DOM0 only runs on a single CPU, since multiprocessor
guests aren't supported yet. Second, the architecture manual only gives
sample code for doing the update in real mode; it seems to imply that this
will also work from protected mode, but it's not quite clear what the
requirements are. Based on the code of the Linux kernel driver:

  <http://lxr.linux.no/source/arch/i386/kernel/microcode.c#L288>

it looks like EAX just has to contain a linear address when Linux is
running on bare hardware (the driver casts a pointer in the data segment,
which is zero-based, to an unsigned int). In order to use a generic
wrmsr hypercall, DOM0 would have to calculate what linear address Xen
should use, which although possible (I think), is a horrible layering
violation that would depend on implementation details of Xen.

It would be much cleaner to either:

 - add a privileged hypercall specifically to allow DOM0 to update the
   microcode on all processors (essentially just copy the Linux driver
   into Xen),
 - compile the latest microcode into Xen and have it do the update at
   boot. This would require people to upgrade Xen in order to upgrade the
   microcode.

--
David Hopwood <david.nospam.hopwood@xxxxxxxxxxxxxxxx>



-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • Re: [Xen-devel] Porting of Guest OS, David Hopwood <=