vcore_id() is now implemented using TLS
[akaros.git] / kern / arch / sparc / ros / trapframe.h
1 #ifndef ROS_INCLUDE_ARCH_TRAPFRAME_H
2 #define ROS_INCLUDE_ARCH_TRAPFRAME_H
3
4 #include <ros/common.h>
5 #include <stdint.h>
6
7 typedef struct trapframe
8 {
9         uint32_t gpr[32] __attribute__((aligned (8)));
10         uint32_t psr;
11         uint32_t pc;
12         uint32_t npc;
13         uint32_t wim;
14         uint32_t tbr;
15         uint32_t y;
16         uint32_t fault_status;
17         uint32_t fault_addr;
18         uint64_t timestamp;
19 } trapframe_t;
20
21 /* TODO: consider using a user-space specific trapframe, since they don't need
22  * all of this information.  Will do that eventually, but til then: */
23 #define user_trapframe trapframe
24
25 typedef struct ancillary_state
26 {
27         uint32_t fpr[32] __attribute__((aligned (8)));
28         uint32_t fsr;
29 } ancillary_state_t;
30
31 #endif /* !ROS_INCLUDE_ARCH_TRAPFRAME_H */