Statistics
| Branch: | Revision:

root / linux-user / ppc / syscall.h @ 5fafdf24

History | View | Annotate | Download (1.6 kB)

1 79aceca5 bellard
/*
2 79aceca5 bellard
 *  PPC emulation for qemu: syscall definitions.
3 5fafdf24 ths
 *
4 79aceca5 bellard
 *  Copyright (c) 2003 Jocelyn Mayer
5 79aceca5 bellard
 *
6 79aceca5 bellard
 * This library is free software; you can redistribute it and/or
7 79aceca5 bellard
 * modify it under the terms of the GNU Lesser General Public
8 79aceca5 bellard
 * License as published by the Free Software Foundation; either
9 79aceca5 bellard
 * version 2 of the License, or (at your option) any later version.
10 79aceca5 bellard
 *
11 79aceca5 bellard
 * This library is distributed in the hope that it will be useful,
12 79aceca5 bellard
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 79aceca5 bellard
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 79aceca5 bellard
 * Lesser General Public License for more details.
15 79aceca5 bellard
 *
16 79aceca5 bellard
 * You should have received a copy of the GNU Lesser General Public
17 79aceca5 bellard
 * License along with this library; if not, write to the Free Software
18 79aceca5 bellard
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19 79aceca5 bellard
 */
20 79aceca5 bellard
21 79aceca5 bellard
/* XXX: ABSOLUTELY BUGGY:
22 79aceca5 bellard
 * for now, this is quite just a cut-and-paste from i386 target...
23 79aceca5 bellard
 */
24 79aceca5 bellard
25 79aceca5 bellard
/* default linux values for the selectors */
26 79aceca5 bellard
#define __USER_DS        (1)
27 79aceca5 bellard
28 79aceca5 bellard
struct target_pt_regs {
29 79aceca5 bellard
        unsigned long gpr[32];
30 79aceca5 bellard
        unsigned long nip;
31 79aceca5 bellard
        unsigned long msr;
32 79aceca5 bellard
        unsigned long orig_gpr3;        /* Used for restarting system calls */
33 79aceca5 bellard
        unsigned long ctr;
34 79aceca5 bellard
        unsigned long link;
35 79aceca5 bellard
        unsigned long xer;
36 79aceca5 bellard
        unsigned long ccr;
37 79aceca5 bellard
        unsigned long mq;                /* 601 only (not used at present) */
38 79aceca5 bellard
                                        /* Used on APUS to hold IPL value. */
39 79aceca5 bellard
        unsigned long trap;                /* Reason for being here */
40 79aceca5 bellard
        unsigned long dar;                /* Fault registers */
41 79aceca5 bellard
        unsigned long dsisr;
42 79aceca5 bellard
        unsigned long result;                 /* Result of a system call */
43 79aceca5 bellard
};
44 79aceca5 bellard
45 79aceca5 bellard
/* ioctls */
46 79aceca5 bellard
struct target_revectored_struct {
47 79aceca5 bellard
        target_ulong __map[8];                        /* 256 bits */
48 79aceca5 bellard
};
49 79aceca5 bellard
50 79aceca5 bellard
/*
51 79aceca5 bellard
 * flags masks
52 79aceca5 bellard
 */
53 79aceca5 bellard
54 cf720db3 bellard
#define UNAME_MACHINE "ppc"