debuggers.hg

view xen/include/asm-x86/x86_64/regs.h @ 3640:9a9c5a491401

bitkeeper revision 1.1159.235.1 (42000d3dwcPyT8aY4VIPYGCfCAJuQQ)

More x86/64. Status: traps.c now included in the build, but actual building
of IDT doesn't happen, and we need some sort of entry.S. More page-table
building required so that arch_init_memory() can work. And there is something
odd with MP-table parsing; I currently suspect that __init sections are
causing problems.
Signed-off-by: keir.fraser@cl.cam.ac.uk
author kaf24@viper.(none)
date Tue Feb 01 23:14:05 2005 +0000 (2005-02-01)
parents ed902e5c4b49
children e6af5d8f8b39
line source
1 #ifndef _X86_64_REGS_H
2 #define _X86_64_REGS_H
4 #include <asm/types.h>
6 struct xen_regs
7 {
8 u64 r15;
9 u64 r14;
10 u64 r13;
11 u64 r12;
12 u64 rbp;
13 u64 rbx;
14 /* NB. Above here is C callee-saves. */
15 u64 r11;
16 u64 r10;
17 u64 r9;
18 u64 r8;
19 union { u64 rax; u32 eax; } __attribute__ ((packed));
20 union { u64 rcx; u32 ecx; } __attribute__ ((packed));
21 union { u64 rdx; u32 edx; } __attribute__ ((packed));
22 union { u64 rsi; u32 esi; } __attribute__ ((packed));
23 union { u64 rdi; u32 edi; } __attribute__ ((packed));
24 u32 error_code;
25 u32 entry_vector;
26 union { u64 rip; u64 eip; } __attribute__ ((packed));
27 u64 cs;
28 u64 eflags;
29 u64 rsp;
30 u64 ss;
31 } __attribute__ ((packed));
33 #define VM86_MODE(_r) ((_r)->eflags & EF_VM)
34 #define RING_0(_r) (((_r)->cs & 3) == 0)
35 #define RING_1(_r) (((_r)->cs & 3) == 1)
36 #define RING_2(_r) (((_r)->cs & 3) == 2)
37 #define RING_3(_r) (((_r)->cs & 3) == 3)
39 #endif