* add p cc
[mascara-docs.git] / i386 / linux / linux-2.3.21 / include / asm-ppc / amigappc.h
blob96e5e8f0974e0d8f45db1c3f80b0a00d27f9a9fe
1 /*
2 ** asm-m68k/amigappc.h -- This header defines some values and pointers for
3 ** the Phase 5 PowerUp card.
4 **
5 ** Copyright 1997, 1998 by Phase5, Germany.
6 **
7 ** This file is subject to the terms and conditions of the GNU General Public
8 ** License. See the file COPYING in the main directory of this archive
9 ** for more details.
11 ** Created: 7/22/97 by Jesper Skov
14 #ifndef _M68K_AMIGAPPC_H
15 #define _M68K_AMIGAPPC_H
17 #ifndef __ASSEMBLY__
19 /* #include <asm/system.h> */
20 #define mb() __asm__ __volatile__ ("sync" : : : "memory")
22 #define APUS_WRITE(_a_, _v_) \
23 do { \
24 (*((volatile unsigned char *)(_a_)) = (_v_)); \
25 mb(); \
26 } while (0)
28 #define APUS_READ(_a_, _v_) \
29 do { \
30 (_v_) = (*((volatile unsigned char *)(_a_))); \
31 mb(); \
32 } while (0)
33 #endif /* ndef __ASSEMBLY__ */
35 /* Maybe add a [#ifdef WANT_ZTWOBASE] condition to amigahw.h? */
36 #define zTwoBase (0x80000000)
38 #define APUS_IPL_BASE (zTwoBase + 0x00f60000)
39 #define APUS_REG_RESET (APUS_IPL_BASE + 0x00)
40 #define APUS_REG_WAITSTATE (APUS_IPL_BASE + 0x10)
41 #define APUS_REG_SHADOW (APUS_IPL_BASE + 0x18)
42 #define APUS_REG_LOCK (APUS_IPL_BASE + 0x20)
43 #define APUS_REG_INT (APUS_IPL_BASE + 0x28)
44 #define APUS_IPL_EMU (APUS_IPL_BASE + 0x30)
45 #define APUS_INT_LVL (APUS_IPL_BASE + 0x38)
47 #define REGSHADOW_SETRESET (0x80)
48 #define REGSHADOW_SELFRESET (0x40)
50 #define REGLOCK_SETRESET (0x80)
51 #define REGLOCK_BLACKMAGICK1 (0x40)
52 #define REGLOCK_BLACKMAGICK2 (0x20)
53 #define REGLOCK_BLACKMAGICK3 (0x10)
55 #define REGWAITSTATE_SETRESET (0x80)
56 #define REGWAITSTATE_PPCW (0x08)
57 #define REGWAITSTATE_PPCR (0x04)
59 #define REGRESET_SETRESET (0x80)
60 #define REGRESET_PPCRESET (0x10)
61 #define REGRESET_M68KRESET (0x08)
62 #define REGRESET_AMIGARESET (0x04)
63 #define REGRESET_AUXRESET (0x02)
64 #define REGRESET_SCSIRESET (0x01)
66 #define REGINT_SETRESET (0x80)
67 #define REGINT_ENABLEIPL (0x02)
68 #define REGINT_INTMASTER (0x01)
70 #define IPLEMU_SETRESET (0x80)
71 #define IPLEMU_DISABLEINT (0x40)
72 #define IPLEMU_IPL2 (0x20)
73 #define IPLEMU_IPL1 (0x10)
74 #define IPLEMU_IPL0 (0x08)
75 #define IPLEMU_PPCIPL2 (0x04)
76 #define IPLEMU_PPCIPL1 (0x02)
77 #define IPLEMU_PPCIPL0 (0x01)
78 #define IPLEMU_IPLMASK (IPLEMU_PPCIPL2|IPLEMU_PPCIPL1|IPLEMU_PPCIPL0)
80 #define INTLVL_SETRESET (0x80)
81 #define INTLVL_MASK (0x7f)
83 #endif /* _M68k_AMIGAPPC_H */