All of lore.kernel.org
 help / color / mirror / Atom feed
* VMX disabled by Feature Control MSR
@ 2006-06-14 11:45 Guillaume Thouvenin
  2006-06-14 12:35 ` Guillaume Thouvenin
  0 siblings, 1 reply; 5+ messages in thread
From: Guillaume Thouvenin @ 2006-06-14 11:45 UTC (permalink / raw)
  To: xen-devel; +Cc: LAURENT VIVIER, JEAN-PIERRE DION

Hello,

 I already posted a message about this problem on this mailing list but
I went more deeply in the analysis of the problem and I'd like to have
your opinion. 

 The problem is: I have a processor (pentium D) that supports the VT
technology but when I boot Xen I have the following message:

(XEN) VMX disabled by Feature Control MSR.

 Here is how I understand that. Xen is using the CPUID instruction to
identify the processor functionality. This is done in
arch/x86/hvm/vmx/vmx.c:start_vmx(). As VMXON is controlled by the
IA32_FEATURE_CONTROL we must test the lock bit (bit0) and the bit2. I
found in the intel documentation that if the bit2 is clear, VMXON
causes a general-protection exeption. In our case, we stop the
start_vmx() function and display the message VMX disabled by feature
control MSR. 

  Thus my question is: What to do to set the bit 2 of the
IA32_FEATURE_CONTROL to 1? Is it only possible by using the option in
the BIOS menu (and it's not present in mine) or is it possible to set it
to 1 before switching in protected mode when Xen is booting. For exemple
somwhere in arch/x86/boot/x86_64.S?


 Thanks for your help,

Guillaume

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: VMX disabled by Feature Control MSR
  2006-06-14 11:45 Guillaume Thouvenin
@ 2006-06-14 12:35 ` Guillaume Thouvenin
  2006-06-14 12:47   ` Keir Fraser
  0 siblings, 1 reply; 5+ messages in thread
From: Guillaume Thouvenin @ 2006-06-14 12:35 UTC (permalink / raw)
  To: xen-devel@lists.xensource.com; +Cc: LAURENT VIVIER, JEAN-PIERRE DION

On Wed, 14 Jun 2006 13:45:49 +0200
Guillaume Thouvenin <guillaume.thouvenin@bull.net> wrote:

>   Thus my question is: What to do to set the bit 2 of the
> IA32_FEATURE_CONTROL to 1? Is it only possible by using the option in
> the BIOS menu (and it's not present in mine) or is it possible to set it
> to 1 before switching in protected mode when Xen is booting. For exemple
> somwhere in arch/x86/boot/x86_64.S?

In fact the problem is how to set the lock bit to 0. In the following
code found in arch/x86/hvm/vmx/vmx.c :

start_vmx() {
...
   if (eax & IA32_FEATURE_CONTROL_MSR_LOCK) {
        if ((eax & IA32_FEATURE_CONTROL_MSR_ENABLE_VMXON) == 0x0) {
            printk("VMX disabled by Feature Control MSR.\n");
            return 0;
        }
    }
    else {
        wrmsr(IA32_FEATURE_CONTROL_MSR,
              IA32_FEATURE_CONTROL_MSR_LOCK |
              IA32_FEATURE_CONTROL_MSR_ENABLE_VMXON, 0);
    }
...

If the "VMX disabled..." message is displayed, it means that the lock
bit is set to 1. Otherwise we set bit2 to 1. If I try to clear it while
it is set it causes a general-protection fault. Is it possible to modify
before Xen switches from real mode to protected mode? 

I will try to modify the arch/x86/boot/x86_64.S

Regards,
Guillaume

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: VMX disabled by Feature Control MSR
  2006-06-14 12:35 ` Guillaume Thouvenin
@ 2006-06-14 12:47   ` Keir Fraser
  0 siblings, 0 replies; 5+ messages in thread
From: Keir Fraser @ 2006-06-14 12:47 UTC (permalink / raw)
  To: Guillaume Thouvenin
  Cc: LAURENT VIVIER, xen-devel@lists.xensource.com, JEAN-PIERRE DION


On 14 Jun 2006, at 13:35, Guillaume Thouvenin wrote:

> If the "VMX disabled..." message is displayed, it means that the lock
> bit is set to 1. Otherwise we set bit2 to 1. If I try to clear it while
> it is set it causes a general-protection fault. Is it possible to 
> modify
> before Xen switches from real mode to protected mode?
>
> I will try to modify the arch/x86/boot/x86_64.S

No, it's called a lock bit because it is sticky once set. The intention 
is presumably to allow OEMs an easy way (in their BIOS) to disable VMX 
on their systems if they don't want to have to support it.

  -- Keir

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: VMX disabled by Feature Control MSR
@ 2006-06-14 18:26 Kamble, Nitin A
  2006-06-15  9:11 ` Jean-Pierre Dion
  0 siblings, 1 reply; 5+ messages in thread
From: Kamble, Nitin A @ 2006-06-14 18:26 UTC (permalink / raw)
  To: Keir Fraser, Guillaume Thouvenin
  Cc: LAURENT VIVIER, xen-devel, JEAN-PIERRE DION

Yes, Keir is correct. Once it is locked you can not unlock it by just
clearing the bit. Probably what you need is, enabling of VMX feature in
the BIOS, and then hard reset the system.

Thanks & Regards,
Nitin
------------------------------------------------------------------------
-----------
Open Source Technology Center, Intel Corp

>-----Original Message-----
>From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-
>bounces@lists.xensource.com] On Behalf Of Keir Fraser
>Sent: Wednesday, June 14, 2006 5:47 AM
>To: Guillaume Thouvenin
>Cc: LAURENT VIVIER; xen-devel@lists.xensource.com; JEAN-PIERRE DION
>Subject: Re: [Xen-devel] VMX disabled by Feature Control MSR
>
>
>On 14 Jun 2006, at 13:35, Guillaume Thouvenin wrote:
>
>> If the "VMX disabled..." message is displayed, it means that the lock
>> bit is set to 1. Otherwise we set bit2 to 1. If I try to clear it
while
>> it is set it causes a general-protection fault. Is it possible to
>> modify
>> before Xen switches from real mode to protected mode?
>>
>> I will try to modify the arch/x86/boot/x86_64.S
>
>No, it's called a lock bit because it is sticky once set. The intention
>is presumably to allow OEMs an easy way (in their BIOS) to disable VMX
>on their systems if they don't want to have to support it.
>
>  -- Keir
>
>
>_______________________________________________
>Xen-devel mailing list
>Xen-devel@lists.xensource.com
>http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: VMX disabled by Feature Control MSR
  2006-06-14 18:26 VMX disabled by Feature Control MSR Kamble, Nitin A
@ 2006-06-15  9:11 ` Jean-Pierre Dion
  0 siblings, 0 replies; 5+ messages in thread
From: Jean-Pierre Dion @ 2006-06-15  9:11 UTC (permalink / raw)
  To: Kamble, Nitin A; +Cc: LAURENT VIVIER, Guillaume Thouvenin, xen-devel


[-- Attachment #1.1: Type: text/plain, Size: 1853 bytes --]

ok we will try get the right bios
for our platform.

thanks


jean-pierre


Kamble, Nitin A wrote:

>Yes, Keir is correct. Once it is locked you can not unlock it by just
>clearing the bit. Probably what you need is, enabling of VMX feature in
>the BIOS, and then hard reset the system.
>
>Thanks & Regards,
>Nitin
>------------------------------------------------------------------------
>-----------
>Open Source Technology Center, Intel Corp
>
>  
>
>>-----Original Message-----
>>From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-
>>bounces@lists.xensource.com] On Behalf Of Keir Fraser
>>Sent: Wednesday, June 14, 2006 5:47 AM
>>To: Guillaume Thouvenin
>>Cc: LAURENT VIVIER; xen-devel@lists.xensource.com; JEAN-PIERRE DION
>>Subject: Re: [Xen-devel] VMX disabled by Feature Control MSR
>>
>>
>>On 14 Jun 2006, at 13:35, Guillaume Thouvenin wrote:
>>
>>    
>>
>>>If the "VMX disabled..." message is displayed, it means that the lock
>>>bit is set to 1. Otherwise we set bit2 to 1. If I try to clear it
>>>      
>>>
>while
>  
>
>>>it is set it causes a general-protection fault. Is it possible to
>>>modify
>>>before Xen switches from real mode to protected mode?
>>>
>>>I will try to modify the arch/x86/boot/x86_64.S
>>>      
>>>
>>No, it's called a lock bit because it is sticky once set. The intention
>>is presumably to allow OEMs an easy way (in their BIOS) to disable VMX
>>on their systems if they don't want to have to support it.
>>
>> -- Keir
>>
>>
>>_______________________________________________
>>Xen-devel mailing list
>>Xen-devel@lists.xensource.com
>>http://lists.xensource.com/xen-devel
>>
>
>
>  
>

-- 
Jean-Pierre DION
Linux and Gnome projects manager
Bull, Architect of an Open World TM 
Tel : +33 (0)4 76 29 72 34
http://www.bull.com
http://www.bullopensource.org
http://gnome.bullfreeware.com/new_index.html


[-- Attachment #1.2: Type: text/html, Size: 3249 bytes --]

[-- Attachment #2: Type: text/plain, Size: 138 bytes --]

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-06-15  9:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-14 18:26 VMX disabled by Feature Control MSR Kamble, Nitin A
2006-06-15  9:11 ` Jean-Pierre Dion
  -- strict thread matches above, loose matches on Subject: below --
2006-06-14 11:45 Guillaume Thouvenin
2006-06-14 12:35 ` Guillaume Thouvenin
2006-06-14 12:47   ` Keir Fraser

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.