From: VMware, Inc <> Date: Fri, 18 Sep 2009 21:43:24 +0000 (-0700) Subject: Changes in shared code that don't affect open-vm-tools functionality. X-Git-Tag: 2009.09.18-193784~15 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e510ef60c7bf70a8e0e85609495e7dc7c6d89d85;p=thirdparty%2Fopen-vm-tools.git Changes in shared code that don't affect open-vm-tools functionality. Signed-off-by: Marcelo Vanzin --- diff --git a/open-vm-tools/lib/include/x86cpuid.h b/open-vm-tools/lib/include/x86cpuid.h index b56fcbfc8..e646fd248 100644 --- a/open-vm-tools/lib/include/x86cpuid.h +++ b/open-vm-tools/lib/include/x86cpuid.h @@ -182,7 +182,9 @@ typedef enum { #define CPUID_CYRIX_VENDOR_STRING "CyriteadxIns" #define CPUID_VIA_VENDOR_STRING "CentaulsaurH" #define CPUID_HYPERV_HYPERVISOR_VENDOR_STRING "Microsoft Hv" +#define CPUID_KVM_HYPERVISOR_VENDOR_STRING "KVMKVMKVM\0\0\0" #define CPUID_VMWARE_HYPERVISOR_VENDOR_STRING "VMwareVMware" +#define CPUID_XEN_HYPERVISOR_VENDOR_STRING "XenVMMXenVMM" #define CPUID_INTEL_VENDOR_STRING_FIXED "GenuineIntel" #define CPUID_AMD_VENDOR_STRING_FIXED "AuthenticAMD" #define CPUID_CYRIX_VENDOR_STRING_FIXED "CyrixInstead" diff --git a/open-vm-tools/lib/user/hostinfo.c b/open-vm-tools/lib/user/hostinfo.c index 7167b0754..8de66711d 100644 --- a/open-vm-tools/lib/user/hostinfo.c +++ b/open-vm-tools/lib/user/hostinfo.c @@ -322,7 +322,6 @@ Hostinfo_TouchXen(void) { #ifdef linux #define XEN_CPUID 0x40000000 -#define XEN_STRING "XenVMMXenVMM" CPUIDRegs regs; uint32 name[4]; @@ -343,7 +342,7 @@ Hostinfo_TouchXen(void) name[1] = regs.ecx; name[2] = regs.edx; name[3] = 0; - if (0 == strcmp(XEN_STRING, (const char*)name)) { + if (0 == strcmp(CPUID_XEN_HYPERVISOR_VENDOR_STRING, (const char*)name)) { return TRUE; }