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