]> rtime.felk.cvut.cz Git - l4.git/blob - l4/pkg/uclibc/lib/contrib/uclibc/libc/sysdeps/linux/cris/sys/user.h
update
[l4.git] / l4 / pkg / uclibc / lib / contrib / uclibc / libc / sysdeps / linux / cris / sys / user.h
1 #ifndef __ASM_CRIS_USER_H
2 #define __ASM_CRIS_USER_H
3
4 /* User-mode register used for core dumps. */
5
6 struct user_fpregs {
7 };
8
9 struct user_regs_struct {
10         unsigned long r0;       /* General registers. */
11         unsigned long r1;
12         unsigned long r2;
13         unsigned long r3;
14         unsigned long r4;
15         unsigned long r5;
16         unsigned long r6;
17         unsigned long r7;
18         unsigned long r8;
19         unsigned long r9;
20         unsigned long r10;
21         unsigned long r11;
22         unsigned long r12;
23         unsigned long r13;
24         unsigned long sp;       /* R14, Stack pointer. */
25         unsigned long acr;      /* R15, Address calculation register. */
26         unsigned long bz;       /* P0, Constant zero (8-bits). */
27         unsigned long vr;       /* P1, Version register (8-bits). */
28         unsigned long pid;      /* P2, Process ID (8-bits). */
29         unsigned long srs;      /* P3, Support register select (8-bits). */
30         unsigned long wz;       /* P4, Constant zero (16-bits). */
31         unsigned long exs;      /* P5, Exception status. */
32         unsigned long eda;      /* P6, Exception data address. */
33         unsigned long mof;      /* P7, Multiply overflow regiter. */
34         unsigned long dz;       /* P8, Constant zero (32-bits). */
35         unsigned long ebp;      /* P9, Exception base pointer. */
36         unsigned long erp;      /* P10, Exception return pointer. */
37         unsigned long srp;      /* P11, Subroutine return pointer. */
38         unsigned long nrp;      /* P12, NMI return pointer. */
39         unsigned long ccs;      /* P13, Condition code stack. */
40         unsigned long usp;      /* P14, User mode stack pointer. */
41         unsigned long spc;      /* P15, Single step PC. */
42 };
43
44 /*
45  * Core file format: The core file is written in such a way that gdb
46  * can understand it and provide useful information to the user (under
47  * linux we use the `trad-core' bfd).  The file contents are as follows:
48  *
49  *  upage: 1 page consisting of a user struct that tells gdb
50  *      what is present in the file.  Directly after this is a
51  *      copy of the task_struct, which is currently not used by gdb,
52  *      but it may come in handy at some point.  All of the registers
53  *      are stored as part of the upage.  The upage should always be
54  *      only one page long.
55  *  data: The data segment follows next.  We use current->end_text to
56  *      current->brk to pick up all of the user variables, plus any memory
57  *      that may have been sbrk'ed.  No attempt is made to determine if a
58  *      page is demand-zero or if a page is totally unused, we just cover
59  *      the entire range.  All of the addresses are rounded in such a way
60  *      that an integral number of pages is written.
61  *  stack: We need the stack information in order to get a meaningful
62  *      backtrace.  We need to write the data from usp to
63  *      current->start_stack, so we round each of these in order to be able
64  *      to write an integer number of pages.
65  */
66
67 struct user {
68         struct user_regs_struct regs;           /* entire machine state */
69         size_t          u_tsize;                /* text size (pages) */
70         size_t          u_dsize;                /* data size (pages) */
71         size_t          u_ssize;                /* stack size (pages) */
72         unsigned long   start_code;             /* text starting address */
73         unsigned long   start_data;             /* data starting address */
74         unsigned long   start_stack;            /* stack starting address */
75         long int        signal;                 /* signal causing core dump */
76         unsigned long   u_ar0;                  /* help gdb find registers */
77         unsigned long   magic;                  /* identifies a core file */
78         char            u_comm[32];             /* user command name */
79 };
80
81 #endif /* __ASM_CRIS_USER_H */