]> git.ipfire.org Git - thirdparty/open-vm-tools.git/commitdiff
vm_basic_types.h: remove VM_I386
authorOliver Kurth <okurth@vmware.com>
Tue, 5 Jun 2018 22:47:39 +0000 (15:47 -0700)
committerOliver Kurth <okurth@vmware.com>
Tue, 5 Jun 2018 22:47:39 +0000 (15:47 -0700)
The VM_I386 macro is described as "historical". But recent cleanups
reduced the number of usages to the point where "historical" can become
"removed".

Remove the declaration, comments describing the declaration, and
fix the last two places to use the modern macro alternatives.

open-vm-tools/lib/include/backdoor_types.h
open-vm-tools/lib/include/vm_basic_defs.h
open-vm-tools/lib/include/vm_basic_types.h

index 2a9783af2b4f54f3389f7c7b5e0bcbf6b6a7eb25..d506c314645579b74f750ab5f2c6d339a19eb0ab 100644 (file)
@@ -39,7 +39,8 @@
 #ifndef _BACKDOOR_TYPES_H_
 #define _BACKDOOR_TYPES_H_
 
-#ifndef VM_I386
+#if !defined(__i386__) && !defined(__x86_64__) && \
+    !defined(_M_IX86) && !defined(_M_X64)
 #error The backdoor protocol is only supported on x86 architectures.
 #endif
 
index a74d36311943c80b05b4d765610bde60009447e7..5d9afaa37a4e9ae34086f5b5db7ca44516a57679 100644 (file)
@@ -248,7 +248,7 @@ Max(int a, int b)
  */
 
 #ifndef PAGE_SHIFT // {
-#if defined VM_I386
+#if defined __x86_64__ || defined __i386__
    #define PAGE_SHIFT    12
 #elif defined __APPLE__
    #define PAGE_SHIFT    12
index 91624d5772788cfbafa14f4eebc6ea720cee521a..78d39113b733af735820abf340fc9bfbd689c214 100644 (file)
  * - VM_<arch>_32 for the 32-bit variant.
  * - VM_<arch>_64 for the 64-bit variant.
  * - VM_<arch>_ANY for any variant of <arch>.
- *
- * VM_X86_ANY is synonymous with the confusing and deprecated VM_I386 (which
- * should really be VM_X86_32).
  */
 
 #ifdef __i386__
-/*
- * VM_I386 is historically synonymous with VM_X86_ANY in bora, but misleading,
- * since it is confused with the __i386__ gcc but defined for both 32- and
- * 64-bit x86. We retain it here for legacy compatibility.
- */
-#define VM_I386
 #define VM_X86_32
 #define VM_X86_ANY
 #define VM_32BIT
 #ifdef __x86_64__
 #define VM_X86_64
 #define vm_x86_64 1
-#define VM_I386
 #define VM_X86_ANY
 #define VM_64BIT
 #else