Reporting the Identity of a Guest Operating System

The guest operating system that runs within a partition must identify itself to the hypervisor by writing its signature and version to a model-specific register (MSR) (for example, HV_X64_MSR_GUEST_OS_ID). This MSR is partition-wide and is shared among all virtual processors. For more information about virtual processors, see Hypervisor Virtual Processor Management.

By default, this MSR's value is zero. The guest operating system must write a nonzero value to the MSR before the hypervisor can enable the hypercall code page. For more information about how to enable the hypercall code page, see Establishing the Hypercall Interface. If the guest operating system later zeros this MSR, the hypervisor will disable the hypercall code page.

The value that the guest operating system writes to this MSR is ignored by the hypervisor but might be used in future hypervisor implementations to maintain compatibility with existing guest operating systems. The following constant defines the MSR for reporting the identity of a guest operating system:


#define HV_X64_MSR_GUEST_OS_ID 0x40000000

The following is the recommended encoding for the MSR that the guest operating system uses to identify itself to the hypervisor. The guest operating system uses the HV_X64_MSR_GUEST_OS_ID_CONTENTS union to encode the MSR. Some fields might not apply for some guest operating systems.

63:4847:4039:3231:2423:1615:0

Vendor ID

OS ID

Major Version

Minor Version

Service Version

Build Number

 

The following table provides meanings for the fields in the previous table.

BitsMeaningAttributes

63:48

Vendor ID

Indicates the vendor of the guest operating system. A value of 0 is reserved. A value of 1 indicates Microsoft.

Read/write

47:40

OS ID

Indicates the operating system variant. Encoding is unique to the vendor. Microsoft operating systems are encoded as follows:

0=Undefined, 1=Microsoft MS-DOS, 2=Microsoft Windows 3.x, 3=Windows 9x, 4=Windows NT (and derivatives), 5=Windows CE.

Read/write

39:32

Major Version

Indicates the major version of the operating system.

Read/write

31:24

Minor Version

Indicates the minor version of the operating system.

Read/write

23:16

Service Version

Indicates the service version (for example, the service pack number).

Read/write

15:0

Build Number

Indicates the build number of the operating system.

Read/write

 

 

 

Send comments about this topic to Microsoft

Build date: 11/16/2013

Show:
© 2014 Microsoft. All rights reserved.