[hyperv] Check for required features
[ipxe.git] / src / arch / x86 / drivers / hyperv / hyperv.h
1 #ifndef _HYPERV_H
2 #define _HYPERV_H
3
4 /** @file
5 *
6 * Hyper-V driver
7 *
8 */
9
10 FILE_LICENCE ( GPL2_OR_LATER );
11
12 /** Get vendor identification */
13 #define HV_CPUID_VENDOR_ID 0x40000000UL
14
15 /** Get interface identification */
16 #define HV_CPUID_INTERFACE_ID 0x40000001UL
17
18 /** Get hypervisor identification */
19 #define HV_CPUID_HYPERVISOR_ID 0x40000002UL
20
21 /** Get hypervisor features */
22 #define HV_CPUID_FEATURES 0x40000003UL
23
24 /** SynIC MSRs are available */
25 #define HV_FEATURES_AVAIL_SYNIC_MSR 0x00000004UL
26
27 /** Hypercall MSRs are available */
28 #define HV_FEATURES_AVAIL_HYPERCALL_MSR 0x00000020UL
29
30 /** Guest may post messages */
31 #define HV_FEATURES_PERM_POST_MESSAGES 0x00000010UL
32
33 /** Guest may signal events */
34 #define HV_FEATURES_PERM_SIGNAL_EVENTS 0x00000020UL
35
36 /** Guest OS identity MSR */
37 #define HV_X64_MSR_GUEST_OS_ID 0x40000000UL
38
39 /** Hypercall page MSR */
40 #define HV_X64_MSR_HYPERCALL 0x40000001UL
41
42 /** SynIC control MSR */
43 #define HV_X64_MSR_SCONTROL 0x40000080UL
44
45 /** SynIC event flags page MSR */
46 #define HV_X64_MSR_SIEFP 0x40000082UL
47
48 /** SynIC message page MSR */
49 #define HV_X64_MSR_SIMP 0x40000083UL
50
51 /** SynIC end of message MSR */
52 #define HV_X64_MSR_EOM 0x40000084UL
53
54 /** SynIC interrupt source MSRs */
55 #define HV_X64_MSR_SINT(x) ( 0x40000090UL + (x) )
56
57 #endif /* _HYPERV_H */