Xen Test Framework
x86-tss.h
Go to the documentation of this file.
1
7#ifndef XTF_X86_TSS_H
8#define XTF_X86_TSS_H
9
10#include <xtf/types.h>
11#include <xtf/compiler.h>
12
14 uint16_t link; uint16_t :16;
15
18
21
24
36
43 uint16_t ldtr; uint16_t :16;
44
47};
48
51
55
57
58 uint64_t ist[7]; /* 1-based structure */
59
61
64};
65
66#define X86_TSS_INVALID_IO_BITMAP 0x8000
67
68void dump_x86_tss32(const struct x86_tss32 *t);
69void dump_x86_tss64(const struct x86_tss64 *t);
70
71#if defined(__x86_64__)
72
73typedef struct x86_tss64 env_tss;
74
75static inline void dump_env_tss(const env_tss *t)
76{
78}
79
80#elif defined(__i386__)
81
82typedef struct x86_tss32 env_tss;
83
84static inline void dump_env_tss(const env_tss *t)
85{
87}
88
89#else
90# error Bad architecture for TSS infrastructure
91#endif
92
93#endif /* XTF_X86_TSS_H */
94
95/*
96 * Local variables:
97 * mode: C
98 * c-file-style: "BSD"
99 * c-basic-offset: 4
100 * tab-width: 4
101 * indent-tabs-mode: nil
102 * End:
103 */
#define __packed
Definition: compiler.h:11
__UINT32_TYPE__ uint32_t
Definition: stdint.h:16
__UINT64_TYPE__ uint64_t
Definition: stdint.h:17
__UINT16_TYPE__ uint16_t
Definition: stdint.h:15
uint32_t eip
Definition: x86-tss.h:26
uint32_t esp2
Definition: x86-tss.h:22
uint32_t edi
Definition: x86-tss.h:35
uint16_t trace
Definition: x86-tss.h:45
uint32_t esp
Definition: x86-tss.h:32
uint32_t esp1
Definition: x86-tss.h:19
uint32_t eax
Definition: x86-tss.h:28
uint16_t uint16_t iopb
Definition: x86-tss.h:46
uint32_t cr3
Definition: x86-tss.h:25
uint32_t ebp
Definition: x86-tss.h:33
uint32_t esp0
Definition: x86-tss.h:16
uint32_t esi
Definition: x86-tss.h:34
uint32_t edx
Definition: x86-tss.h:30
uint32_t ebx
Definition: x86-tss.h:31
uint32_t eflags
Definition: x86-tss.h:27
uint32_t ecx
Definition: x86-tss.h:29
uint64_t rsp1
Definition: x86-tss.h:53
uint64_t rsp2
Definition: x86-tss.h:54
uint16_t trace
Definition: x86-tss.h:62
uint64_t rsp0
Definition: x86-tss.h:52
uint16_t uint16_t iopb
Definition: x86-tss.h:63
Common declarations for all tests.
void dump_x86_tss32(const struct x86_tss32 *t)
Definition: x86-tss.c:10
void dump_x86_tss64(const struct x86_tss64 *t)
Definition: x86-tss.c:43