diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kernel/cpu/vmware.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kernel/cpu/vmware.c b/arch/x86/kernel/cpu/vmware.c index 2ac4394fcb90..a0905ecfe7d2 100644 --- a/arch/x86/kernel/cpu/vmware.c +++ b/arch/x86/kernel/cpu/vmware.c | |||
@@ -36,7 +36,7 @@ | |||
36 | "=a"(eax), "=c"(ecx), "=d"(edx), "=b"(ebx) : \ | 36 | "=a"(eax), "=c"(ecx), "=d"(edx), "=b"(ebx) : \ |
37 | "0"(VMWARE_HYPERVISOR_MAGIC), \ | 37 | "0"(VMWARE_HYPERVISOR_MAGIC), \ |
38 | "1"(VMWARE_PORT_CMD_##cmd), \ | 38 | "1"(VMWARE_PORT_CMD_##cmd), \ |
39 | "2"(VMWARE_HYPERVISOR_PORT), "3"(0) : \ | 39 | "2"(VMWARE_HYPERVISOR_PORT), "3"(UINT_MAX) : \ |
40 | "memory"); | 40 | "memory"); |
41 | 41 | ||
42 | static inline int __vmware_platform(void) | 42 | static inline int __vmware_platform(void) |
@@ -53,7 +53,7 @@ static unsigned long __vmware_get_tsc_khz(void) | |||
53 | 53 | ||
54 | VMWARE_PORT(GETHZ, eax, ebx, ecx, edx); | 54 | VMWARE_PORT(GETHZ, eax, ebx, ecx, edx); |
55 | 55 | ||
56 | if (eax == (uint32_t)-1) | 56 | if (ebx == UINT_MAX) |
57 | return 0; | 57 | return 0; |
58 | tsc_hz = eax | (((uint64_t)ebx) << 32); | 58 | tsc_hz = eax | (((uint64_t)ebx) << 32); |
59 | do_div(tsc_hz, 1000); | 59 | do_div(tsc_hz, 1000); |