ia64/xen-unstable

view xen/include/public/io/vmx_vlapic.h @ 7339:ff7c5a791ed5

Backout incautious public/io header changes
author djm@kirby.fc.hp.com
date Fri Oct 21 13:58:39 2005 -0600 (2005-10-21)
parents 760f5e85c706
children b6cce4237ded
line source
1 #ifndef _VMX_VLAPIC_H
2 #define _VMX_VLAPIC_H
4 /*
5 We extended one bit for PIC type
6 */
7 #define VLAPIC_DELIV_MODE_FIXED 0x0
8 #define VLAPIC_DELIV_MODE_LPRI 0x1
9 #define VLAPIC_DELIV_MODE_SMI 0x2
10 #define VLAPIC_DELIV_MODE_NMI 0x4
11 #define VLAPIC_DELIV_MODE_INIT 0x5
12 #define VLAPIC_DELIV_MODE_STARTUP 0x6
13 #define VLAPIC_DELIV_MODE_EXT 0x7
14 #define VLAPIC_DELIV_MODE_MASK 0x8
16 #define VLAPIC_MSG_LEVEL 4
18 #define INTR_EXT 0
19 #define INTR_APIC 1
20 #define INTR_LAPIC 2
22 #define VL_STATE_EOI 1
23 #define VL_STATE_EXT_LOCK 2
24 #define VL_STATE_MSG_LOCK 3
25 #define VL_STATE_EOI_LOCK 3
27 #define VLOCAL_APIC_MAX_INTS 256
28 #define VLAPIC_INT_COUNT (VLOCAL_APIC_MAX_INTS/(BITS_PER_BYTE * sizeof(uint64_t)))
29 #define VLAPIC_INT_COUNT_32 (VLOCAL_APIC_MAX_INTS/(BITS_PER_BYTE * sizeof(uint32_t)))
31 struct vapic_bus_message{
32 uint8_t deliv_mode:4; /* deliver mode, including fixed, LPRI, etc */
33 uint8_t level:1; /* level or edge */
34 uint8_t trig_mod:1; /* assert or disassert */
35 uint8_t reserved:2;
36 uint8_t vector;
37 };
39 typedef struct {
40 /* interrupt for PIC and ext type IOAPIC interrupt */
41 uint64_t vl_ext_intr[VLAPIC_INT_COUNT];
42 uint64_t vl_ext_intr_mask[VLAPIC_INT_COUNT];
43 uint64_t vl_apic_intr[VLAPIC_INT_COUNT];
44 uint64_t vl_apic_tmr[VLAPIC_INT_COUNT];
45 uint64_t vl_eoi[VLAPIC_INT_COUNT];
46 uint32_t vl_lapic_id;
47 uint32_t direct_intr;
48 uint32_t vl_apr;
49 uint32_t vl_logical_dest;
50 uint32_t vl_dest_format;
51 uint32_t vl_arb_id;
52 uint32_t vl_state;
53 uint32_t apic_msg_count;
54 struct vapic_bus_message vl_apic_msg[24];
55 } vlapic_info;
57 #endif /* _VMX_VLAPIC_H_ */
59 /*
60 * Local variables:
61 * mode: C
62 * c-set-style: "BSD"
63 * c-basic-offset: 4
64 * tab-width: 4
65 * indent-tabs-mode: nil
66 * End:
67 */