icureg.h revision 1.2 1 1.2 takemura /* $NetBSD: icureg.h,v 1.2 1999/12/28 03:15:17 takemura Exp $ */
2 1.1 takemura
3 1.1 takemura /*-
4 1.1 takemura * Copyright (c) 1999 Shin Takemura. All rights reserved.
5 1.1 takemura * Copyright (c) 1999 SATO Kazumi. All rights reserved.
6 1.1 takemura * Copyright (c) 1999 PocketBSD Project. All rights reserved.
7 1.1 takemura *
8 1.1 takemura * Redistribution and use in source and binary forms, with or without
9 1.1 takemura * modification, are permitted provided that the following conditions
10 1.1 takemura * are met:
11 1.1 takemura * 1. Redistributions of source code must retain the above copyright
12 1.1 takemura * notice, this list of conditions and the following disclaimer.
13 1.1 takemura * 2. Redistributions in binary form must reproduce the above copyright
14 1.1 takemura * notice, this list of conditions and the following disclaimer in the
15 1.1 takemura * documentation and/or other materials provided with the distribution.
16 1.1 takemura * 3. All advertising materials mentioning features or use of this software
17 1.1 takemura * must display the following acknowledgement:
18 1.1 takemura * This product includes software developed by the PocketBSD project
19 1.1 takemura * and its contributors.
20 1.1 takemura * 4. Neither the name of the project nor the names of its contributors
21 1.1 takemura * may be used to endorse or promote products derived from this software
22 1.1 takemura * without specific prior written permission.
23 1.1 takemura *
24 1.1 takemura * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
25 1.1 takemura * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
26 1.1 takemura * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
27 1.1 takemura * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
28 1.1 takemura * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
29 1.1 takemura * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
30 1.1 takemura * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
31 1.1 takemura * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
32 1.1 takemura * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
33 1.1 takemura * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34 1.1 takemura * SUCH DAMAGE.
35 1.1 takemura *
36 1.1 takemura */
37 1.1 takemura
38 1.1 takemura /*
39 1.1 takemura * ICU (Interrupt Control UNIT) Registers definitions
40 1.1 takemura * start 0x0B000080
41 1.1 takemura */
42 1.1 takemura #define SYSINT1_REG_W 0x000 /* Level1 System intr reg 1 */
43 1.1 takemura #define MSYSINT1_REG_W 0x00c /* Level1 Mask System intr reg 1 */
44 1.1 takemura
45 1.1 takemura #define SYSINT1_INT15 (1<<15)
46 1.1 takemura #define SYSINT1_INT14 (1<<14)
47 1.1 takemura #define SYSINT1_DOZEPIU (1<<13) /* PIU intr during Suspend */
48 1.1 takemura #define SYSINT1_INT12 (1<<12)
49 1.1 takemura #define SYSINT1_SOFT (1<<11) /* Software intr */
50 1.1 takemura #define SYSINT1_WRBERR (1<<10) /* Bus error intr */
51 1.1 takemura #define SYSINT1_SIU (1<<9) /* SIU intr */
52 1.1 takemura #define SYSINT1_GIU (1<<8) /* GIU intr */
53 1.1 takemura #define SYSINT1_KIU (1<<7) /* KIU intr */
54 1.1 takemura #define SYSINT1_AIU (1<<6) /* AIU intr */
55 1.1 takemura #define SYSINT1_PIU (1<<5) /* PIU intr */
56 1.1 takemura #define SYSINT1_INT4 (1<<4)
57 1.1 takemura #define SYSINT1_ETIMER (1<<3) /* ETIMER intr */
58 1.1 takemura #define SYSINT1_RTCL1 (1<<2) /* RTClong1 intr */
59 1.1 takemura #define SYSINT1_POWER (1<<1) /* PowerSW intr */
60 1.1 takemura #define SYSINT1_BAT (1<<0) /* Battery intr */
61 1.1 takemura
62 1.1 takemura
63 1.2 takemura #define ICUPIUINT_REG_W 0x002 /* Level2 PIU intr reg */
64 1.1 takemura #define MPIUINT_REG_W 0x00e /* Level2 Mask PIU intr reg */
65 1.1 takemura
66 1.1 takemura #define PIUINT_PADCMD (1<<6) /* PIU command scan intr */
67 1.1 takemura #define PIUINT_PADADP (1<<5) /* PIU AD port scan intr */
68 1.1 takemura #define PIUINT_PADPAGE1 (1<<4) /* PIU data page 1 intr */
69 1.1 takemura #define PIUINT_PADPAGE0 (1<<3) /* PIU data page 0 intr */
70 1.1 takemura #define PIUINT_PADLOST (1<<2) /* A/D data timeout intr */
71 1.1 takemura #define PIUINT_PENCHG (1) /* Touch Panel contact intr */
72 1.1 takemura
73 1.1 takemura #define AIUINT_REG_W 0x004 /* Level2 AIU intr reg */
74 1.1 takemura #define MAIUINT_REG_W 0x010 /* Level2 Mask AIU intr reg */
75 1.1 takemura
76 1.1 takemura #define AIUINT_INTMEND (1<<11) /* Audio input DMA buffer 2 page */
77 1.1 takemura #define AIUINT_INTM (1<<10) /* Audio input DMA buffer 1 page */
78 1.1 takemura #define AIUINT_INTMIDLE (1<<9) /* Audio input idle intr */
79 1.1 takemura #define AIUINT_INTMST (1<<8) /* Audio input receive completion intr */
80 1.1 takemura #define AIUINT_INTSEND (1<<3) /* Audio output buffer 2 page */
81 1.1 takemura #define AIUINT_INTS (1<<2) /* Audio output buffer 1 page */
82 1.1 takemura #define AIUINT_INTSIDLE (1<<1) /* Audio output idle intr */
83 1.1 takemura
84 1.1 takemura
85 1.1 takemura #define KIUINT_REG_W 0x006 /* Level2 KIU intr reg */
86 1.1 takemura #define MKIUINT_REG_W 0x012 /* Level2 Mask KIU intr reg */
87 1.1 takemura
88 1.1 takemura #define KIUINT_KDATLOST (1<<2) /* Key scan data lost */
89 1.1 takemura #define KIUINT_KDATRDY (1<<1) /* Key scan data complete */
90 1.1 takemura #define KIUINT_SCANINT (1) /* Key input detect intr */
91 1.1 takemura
92 1.1 takemura
93 1.1 takemura #define GIUINT_L_REG_W 0x008 /* Level2 GIU intr reg Low */
94 1.1 takemura #define MGIUINT_L_REG_W 0x014 /* Level2 Mask GIU intr reg Low */
95 1.1 takemura
96 1.1 takemura #define GIUINT_GPIO15 (1<<15) /* GPIO 15 */
97 1.1 takemura #define GIUINT_GPIO14 (1<<14) /* GPIO 14 */
98 1.1 takemura #define GIUINT_GPIO13 (1<<13) /* GPIO 13 */
99 1.1 takemura #define GIUINT_GPIO12 (1<<12) /* GPIO 12 */
100 1.1 takemura #define GIUINT_GPIO11 (1<<11) /* GPIO 11 */
101 1.1 takemura #define GIUINT_GPIO10 (1<<10) /* GPIO 10 */
102 1.1 takemura #define GIUINT_GPIO9 (1<<9) /* GPIO 9 */
103 1.1 takemura #define GIUINT_GPIO8 (1<<8) /* GPIO 8 */
104 1.1 takemura #define GIUINT_GPIO7 (1<<7) /* GPIO 7 */
105 1.1 takemura #define GIUINT_GPIO6 (1<<6) /* GPIO 6 */
106 1.1 takemura #define GIUINT_GPIO5 (1<<5) /* GPIO 5 */
107 1.1 takemura #define GIUINT_GPIO4 (1<<4) /* GPIO 4 */
108 1.1 takemura #define GIUINT_GPIO3 (1<<3) /* GPIO 3 */
109 1.1 takemura #define GIUINT_GPIO2 (1<<2) /* GPIO 2 */
110 1.1 takemura #define GIUINT_GPIO1 (1<<1) /* GPIO 1 */
111 1.1 takemura #define GIUINT_GPIO0 (1) /* GPIO 0 */
112 1.1 takemura
113 1.1 takemura
114 1.1 takemura #define DSIUINT_REG_W 0x00a /* Level2 DSIU intr reg */
115 1.1 takemura #define MDSIUINT_REG_W 0x016 /* Level2 Mask DSIU intr reg */
116 1.1 takemura
117 1.1 takemura #define DSIUINT_DCTS (1<<11) /* DCTS# change */
118 1.1 takemura #define DSIUINT_SER0 (1<<10) /* Debug serial receive error */
119 1.1 takemura #define DSIUINT_SR0 (1<<9) /* Debug serial receive */
120 1.1 takemura #define DSIUINT_ST0 (1<<8) /* Debug serial transmit */
121 1.1 takemura
122 1.1 takemura #define NMI_REG_W 0x018 /* NMI reg */
123 1.1 takemura
124 1.1 takemura #define LOWBATT_NMIORINT (1) /* Low battery type */
125 1.1 takemura #define LOWBATT_INT0 (1) /* Low battery int 0 */
126 1.1 takemura #define LOWBATT_NMI (0) /* Low battery NMI */
127 1.1 takemura
128 1.1 takemura
129 1.1 takemura #define SOFTINT_REG_W 0x01a /* Software intr reg */
130 1.1 takemura
131 1.1 takemura #define SOFTINT_MASK3 (1<<3) /* Softint3 mask */
132 1.1 takemura #define SOFTINT_SET3 (1<<3) /* Softint3 set */
133 1.1 takemura #define SOFTINT_CLEAR3 (0<<3) /* Softint3 clear */
134 1.1 takemura
135 1.1 takemura #define SOFTINT_MASK2 (1<<2) /* Softint2 mask */
136 1.1 takemura #define SOFTINT_SET2 (1<<2) /* Softint2 set */
137 1.1 takemura #define SOFTINT_CLEAR2 (0<<2) /* Softint2 clear */
138 1.1 takemura
139 1.1 takemura #define SOFTINT_MASK1 (1<<1) /* Softint1 mask */
140 1.1 takemura #define SOFTINT_SET1 (1<<1) /* Softint1 set */
141 1.1 takemura #define SOFTINT_CLEAR1 (0<<1) /* Softint1 clear */
142 1.1 takemura
143 1.1 takemura #define SOFTINT_MASK0 (1) /* Softint0 mask */
144 1.1 takemura #define SOFTINT_SET0 (1) /* Softint0 set */
145 1.1 takemura #define SOFTINT_CLEAR0 (0) /* Softint0 clear */
146 1.1 takemura
147 1.1 takemura
148 1.1 takemura #define SYSINT2_REG_W 0x180 /* Level1 System intr reg 2 */
149 1.1 takemura #define MSYSINT2_REG_W 0x186 /* Level1 Mask System intr reg 2 */
150 1.1 takemura
151 1.1 takemura #define SYSINT2_INT31 (1<<15)
152 1.1 takemura #define SYSINT2_INT30 (1<<14)
153 1.1 takemura #define SYSINT2_INT29 (1<<13)
154 1.1 takemura #define SYSINT2_INT28 (1<<12)
155 1.1 takemura #define SYSINT2_INT27 (1<<11)
156 1.1 takemura #define SYSINT2_INT26 (1<<10)
157 1.1 takemura #define SYSINT2_INT25 (1<<9)
158 1.1 takemura #define SYSINT2_INT24 (1<<8)
159 1.1 takemura #define SYSINT2_INT23 (1<<7)
160 1.1 takemura #define SYSINT2_INT22 (1<<6)
161 1.1 takemura #define SYSINT2_DSIU (1<<5) /* DSUI intr */
162 1.1 takemura #define SYSINT2_FIR (1<<4) /* FIR intr */
163 1.1 takemura #define SYSINT2_TCLK (1<<3) /* TClock Counter intr */
164 1.1 takemura #define SYSINT2_HSP (1<<2) /* HSP intr */
165 1.1 takemura #define SYSINT2_LED (1<<1) /* LED intr */
166 1.1 takemura #define SYSINT2_RTCL2 (1<<0) /* RTCLong2 intr */
167 1.1 takemura
168 1.1 takemura
169 1.1 takemura #define GIUINT_H_REG_W 0x182 /* Level2 GIU intr reg High */
170 1.1 takemura #define MGIUINT_H_REG_W 0x188 /* Level2 Mask GIU intr reg High */
171 1.1 takemura
172 1.1 takemura #define GIUINT_GPIO31 (1<<15) /* GPIO 31 */
173 1.1 takemura #define GIUINT_GPIO30 (1<<14) /* GPIO 30 */
174 1.1 takemura #define GIUINT_GPIO29 (1<<13) /* GPIO 29 */
175 1.1 takemura #define GIUINT_GPIO28 (1<<12) /* GPIO 28 */
176 1.1 takemura #define GIUINT_GPIO27 (1<<11) /* GPIO 27 */
177 1.1 takemura #define GIUINT_GPIO26 (1<<10) /* GPIO 26 */
178 1.1 takemura #define GIUINT_GPIO25 (1<<9) /* GPIO 25 */
179 1.1 takemura #define GIUINT_GPIO24 (1<<8) /* GPIO 24 */
180 1.1 takemura #define GIUINT_GPIO23 (1<<7) /* GPIO 23 */
181 1.1 takemura #define GIUINT_GPIO22 (1<<6) /* GPIO 22 */
182 1.1 takemura #define GIUINT_GPIO21 (1<<5) /* GPIO 21 */
183 1.1 takemura #define GIUINT_GPIO20 (1<<4) /* GPIO 20 */
184 1.1 takemura #define GIUINT_GPIO19 (1<<3) /* GPIO 19 */
185 1.1 takemura #define GIUINT_GPIO18 (1<<2) /* GPIO 18 */
186 1.1 takemura #define GIUINT_GPIO17 (1<<1) /* GPIO 17 */
187 1.1 takemura #define GIUINT_GPIO16 (1) /* GPIO 16 */
188 1.1 takemura
189 1.1 takemura
190 1.1 takemura #define FIRINT_REG_W 0x184 /* Level2 FIR intr reg */
191 1.1 takemura #define MFIRINT_REG_W 0x18a /* Level2 Mask FIR intr reg */
192 1.1 takemura
193 1.1 takemura #define FIRINT_FIR (1<<4) /* FIR intr */
194 1.1 takemura #define FIRINT_RECV2 (1<<3) /* FIR DMA buf recv buffer2 */
195 1.1 takemura #define FIRINT_TRNS2 (1<<2) /* FIR DMA buf transmit buffer2 */
196 1.1 takemura #define FIRINT_RECV1 (1<<1) /* FIR DMA buf recv buffer1 */
197 1.1 takemura #define FIRINT_TRNS1 (1) /* FIR DMA buf transmit buffer1 */
198 1.1 takemura
199 1.1 takemura /* END icureg.h */
200