Print this page
9723 provide support for VMM's GDT handling
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: Patrick Mooney <patrick.mooney@joyent.com>


 874 
 875 #if defined(OPTERON_ERRATUM_121)
 876 extern int opteron_erratum_121;
 877 #endif
 878 
 879 #if defined(OPTERON_WORKAROUND_6323525)
 880 extern int opteron_workaround_6323525;
 881 extern void patch_workaround_6323525(void);
 882 #endif
 883 
 884 #if !defined(__xpv)
 885 extern void determine_platform(void);
 886 #endif
 887 extern int get_hwenv(void);
 888 extern int is_controldom(void);
 889 
 890 extern void enable_pcid(void);
 891 
 892 extern void xsave_setup_msr(struct cpu *);
 893 




 894 /*
 895  * Hypervisor signatures
 896  */
 897 #define HVSIG_XEN_HVM   "XenVMMXenVMM"
 898 #define HVSIG_VMWARE    "VMwareVMware"
 899 #define HVSIG_KVM       "KVMKVMKVM"
 900 #define HVSIG_MICROSOFT "Microsoft Hv"
 901 
 902 /*
 903  * Defined hardware environments
 904  */
 905 #define HW_NATIVE       (1 << 0)  /* Running on bare metal */
 906 #define HW_XEN_PV       (1 << 1)  /* Running on Xen PVM */
 907 
 908 #define HW_XEN_HVM      (1 << 2)  /* Running on Xen HVM */
 909 #define HW_VMWARE       (1 << 3)  /* Running on VMware hypervisor */
 910 #define HW_KVM          (1 << 4)  /* Running on KVM hypervisor */
 911 #define HW_MICROSOFT    (1 << 5)  /* Running on Microsoft hypervisor */
 912 
 913 #define HW_VIRTUAL      (HW_XEN_HVM | HW_VMWARE | HW_KVM | HW_MICROSOFT)


 874 
 875 #if defined(OPTERON_ERRATUM_121)
 876 extern int opteron_erratum_121;
 877 #endif
 878 
 879 #if defined(OPTERON_WORKAROUND_6323525)
 880 extern int opteron_workaround_6323525;
 881 extern void patch_workaround_6323525(void);
 882 #endif
 883 
 884 #if !defined(__xpv)
 885 extern void determine_platform(void);
 886 #endif
 887 extern int get_hwenv(void);
 888 extern int is_controldom(void);
 889 
 890 extern void enable_pcid(void);
 891 
 892 extern void xsave_setup_msr(struct cpu *);
 893 
 894 #if !defined(__xpv)
 895 extern void reset_gdtr_limit(void);
 896 #endif
 897 
 898 /*
 899  * Hypervisor signatures
 900  */
 901 #define HVSIG_XEN_HVM   "XenVMMXenVMM"
 902 #define HVSIG_VMWARE    "VMwareVMware"
 903 #define HVSIG_KVM       "KVMKVMKVM"
 904 #define HVSIG_MICROSOFT "Microsoft Hv"
 905 
 906 /*
 907  * Defined hardware environments
 908  */
 909 #define HW_NATIVE       (1 << 0)  /* Running on bare metal */
 910 #define HW_XEN_PV       (1 << 1)  /* Running on Xen PVM */
 911 
 912 #define HW_XEN_HVM      (1 << 2)  /* Running on Xen HVM */
 913 #define HW_VMWARE       (1 << 3)  /* Running on VMware hypervisor */
 914 #define HW_KVM          (1 << 4)  /* Running on KVM hypervisor */
 915 #define HW_MICROSOFT    (1 << 5)  /* Running on Microsoft hypervisor */
 916 
 917 #define HW_VIRTUAL      (HW_XEN_HVM | HW_VMWARE | HW_KVM | HW_MICROSOFT)