nouveau.hidd: disable warnings about not initialized variables
[AROS.git] / arch / all-mingw32 / kernel / cpu_arm.h
blobcfb70718beeb08c911a4d51e2e83f0b0a8764ca3
1 #ifdef __AROS__
3 /*
4 * This was taken from Mingw32ce's winnt.h
5 * Ouch, ouch, ouch... We don't have VFP data... No floating point in AROS, sorry. :(
6 */
8 /* Context flags */
9 #define CONTEXT_ARM 0x0000040
10 #define CONTEXT_CONTROL (CONTEXT_ARM | 0x00000001L)
11 #define CONTEXT_INTEGER (CONTEXT_ARM | 0x00000002L)
12 #define CONTEXT_FULL (CONTEXT_CONTROL | CONTEXT_INTEGER)
14 typedef struct _CONTEXT
16 ULONG ContextFlags;
17 ULONG R0;
18 ULONG R1;
19 ULONG R2;
20 ULONG R3;
21 ULONG R4;
22 ULONG R5;
23 ULONG R6;
24 ULONG R7;
25 ULONG R8;
26 ULONG R9;
27 ULONG R10;
28 ULONG R11;
29 ULONG R12;
30 ULONG Sp;
31 ULONG Lr;
32 ULONG Pc;
33 ULONG Psr;
34 } CONTEXT;
36 /* Complete context frame, with Windows private data */
37 struct AROSCPUContext
39 struct ExceptionContext regs; /* Public portion */
40 ULONG LastError; /* LastError code */
44 * Thank you Microsoft! :( You gave us no FPU. Because of this
45 * our register save/restore functions are so simple...
48 #define TRAP_SAVEREGS(regs, ctx) \
49 ctx.Flags = 0; \
50 CopyMemQuick(&regs->R0, ctx.r, 17 * sizeof(ULONG))
52 #define TRAP_RESTOREREGS(regs, ctx) \
53 regs->ContextFlags = CONTEXT_FULL; \
54 CopyMemQuick(ctx.r, &regs->R0, 17 * sizeof(ULONG))
56 #define SAVEREGS(regs, ctx) TRAP_SAVEREGS(regs, ctx->regs)
57 #define RESTOREREGS(regs, ctx) TRAP_RESTOREREGS(regs, ctx->regs)
59 #define COPY_FPU(src, dest)
61 #define GET_SP(ctx) (void *)ctx->regs.sp
63 #define EXCEPTIONS_COUNT 18
65 #endif /* __AROS__ */
67 #define PRINT_CPUCONTEXT(ctx) \
68 bug (" R0=%08lX R1=%08lX R2 =%08lX R3 =%08lX\n" \
69 " R4=%08lX R5=%08lX R6 =%08lX R7 =%08lX\n" \
70 " R8=%08lX R9=%08lX R10=%08lX R11=%08lX\n" \
71 " IP=%08lX SP=%08lX LR =%08lX PC =%08lX\n" \
72 " CPSR=%08lX\n" \
73 , (ctx)->R0 , (ctx)->R1, (ctx)->R2 , (ctx)->R3 \
74 , (ctx)->R4 , (ctx)->R5, (ctx)->R6 , (ctx)->R7 \
75 , (ctx)->R8 , (ctx)->R9, (ctx)->R10, (ctx)->R11 \
76 , (ctx)->R12, (ctx)->Sp, (ctx)->Lr , (ctx)->Pc \
77 , (ctx)->Psr \
80 #define CONTEXT_INIT_FLAGS(ctx) (ctx)->ContextFlags = CONTEXT_FULL
82 #define PC(regs) regs->Pc
83 #define R0(regs) regs->R0