| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | /* $NetBSD: machdep.c,v 1.80 2019/12/31 13:07:12 ad Exp $ */ | | 1 | /* $NetBSD: machdep.c,v 1.81 2020/03/08 06:05:05 rin Exp $ */ |
2 | | | 2 | |
3 | /* | | 3 | /* |
4 | * Copyright (c) 1982, 1986, 1990, 1993 | | 4 | * Copyright (c) 1982, 1986, 1990, 1993 |
5 | * The Regents of the University of California. All rights reserved. | | 5 | * The Regents of the University of California. All rights reserved. |
6 | * | | 6 | * |
7 | * This code is derived from software contributed to Berkeley by | | 7 | * This code is derived from software contributed to Berkeley by |
8 | * the Systems Programming Group of the University of Utah Computer | | 8 | * the Systems Programming Group of the University of Utah Computer |
9 | * Science Department. | | 9 | * Science Department. |
10 | * | | 10 | * |
11 | * Redistribution and use in source and binary forms, with or without | | 11 | * Redistribution and use in source and binary forms, with or without |
12 | * modification, are permitted provided that the following conditions | | 12 | * modification, are permitted provided that the following conditions |
13 | * are met: | | 13 | * are met: |
14 | * 1. Redistributions of source code must retain the above copyright | | 14 | * 1. Redistributions of source code must retain the above copyright |
| @@ -139,87 +139,87 @@ | | | @@ -139,87 +139,87 @@ |
139 | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE | | 139 | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE |
140 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | | 140 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
141 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | | 141 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS |
142 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | | 142 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) |
143 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | | 143 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT |
144 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | | 144 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY |
145 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | | 145 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
146 | * SUCH DAMAGE. | | 146 | * SUCH DAMAGE. |
147 | * | | 147 | * |
148 | * @(#)machdep.c 8.6 (Berkeley) 1/14/94 | | 148 | * @(#)machdep.c 8.6 (Berkeley) 1/14/94 |
149 | */ | | 149 | */ |
150 | | | 150 | |
151 | #include <sys/cdefs.h> | | 151 | #include <sys/cdefs.h> |
152 | __KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.80 2019/12/31 13:07:12 ad Exp $"); | | 152 | __KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.81 2020/03/08 06:05:05 rin Exp $"); |
153 | | | 153 | |
154 | #include "opt_ddb.h" | | 154 | #include "opt_ddb.h" |
155 | #include "opt_kgdb.h" | | | |
156 | #include "opt_fpu_emulate.h" | | 155 | #include "opt_fpu_emulate.h" |
| | | 156 | #include "opt_kgdb.h" |
157 | #include "opt_modular.h" | | 157 | #include "opt_modular.h" |
158 | | | 158 | |
159 | #include <sys/param.h> | | 159 | #include <sys/param.h> |
160 | #include <sys/systm.h> | | | |
161 | #include <sys/kernel.h> | | | |
162 | #include <sys/proc.h> | | | |
163 | #include <sys/buf.h> | | 160 | #include <sys/buf.h> |
164 | #include <sys/reboot.h> | | | |
165 | #include <sys/conf.h> | | 161 | #include <sys/conf.h> |
166 | #include <sys/file.h> | | 162 | #include <sys/core.h> |
| | | 163 | #include <sys/cpu.h> |
167 | #include <sys/device.h> | | 164 | #include <sys/device.h> |
168 | #include <sys/malloc.h> | | 165 | #include <sys/exec.h> |
| | | 166 | #include <sys/exec_aout.h> /* for MID_* */ |
169 | #include <sys/extent.h> | | 167 | #include <sys/extent.h> |
| | | 168 | #include <sys/file.h> |
| | | 169 | #include <sys/ioctl.h> |
| | | 170 | #include <sys/kcore.h> |
| | | 171 | #include <sys/kernel.h> |
| | | 172 | #include <sys/ksyms.h> |
| | | 173 | #include <sys/malloc.h> |
170 | #include <sys/mbuf.h> | | 174 | #include <sys/mbuf.h> |
| | | 175 | #include <sys/mount.h> |
171 | #include <sys/msgbuf.h> | | 176 | #include <sys/msgbuf.h> |
172 | #include <sys/ioctl.h> | | 177 | #include <sys/proc.h> |
| | | 178 | #include <sys/reboot.h> |
| | | 179 | #include <sys/syscallargs.h> |
| | | 180 | #include <sys/sysctl.h> |
| | | 181 | #include <sys/systm.h> |
173 | #include <sys/tty.h> | | 182 | #include <sys/tty.h> |
174 | #include <sys/mount.h> | | | |
175 | #include <sys/exec.h> | | | |
176 | #include <sys/exec_aout.h> /* for MID_* */ | | | |
177 | #include <sys/core.h> | | | |
178 | #include <sys/kcore.h> | | | |
179 | #include <sys/vnode.h> | | 183 | #include <sys/vnode.h> |
180 | #include <sys/syscallargs.h> | | 184 | |
181 | #include <sys/ksyms.h> | | | |
182 | #include <sys/cpu.h> | | | |
183 | #ifdef KGDB | | 185 | #ifdef KGDB |
184 | #include <sys/kgdb.h> | | 186 | #include <sys/kgdb.h> |
185 | #endif | | 187 | #endif |
186 | | | 188 | |
187 | #include <uvm/uvm.h> /* XXX: not _extern ... need vm_map_create */ | | 189 | #include <uvm/uvm.h> /* XXX: not _extern ... need vm_map_create */ |
188 | | | 190 | |
189 | #include <sys/sysctl.h> | | | |
190 | | | | |
191 | #include <dev/cons.h> | | 191 | #include <dev/cons.h> |
192 | #include <dev/mm.h> | | 192 | #include <dev/mm.h> |
193 | | | 193 | |
194 | #include <machine/promlib.h> | | 194 | #define _SUN68K_BUS_DMA_PRIVATE |
| | | 195 | #include <machine/autoconf.h> |
| | | 196 | #include <machine/bus.h> |
195 | #include <machine/cpu.h> | | 197 | #include <machine/cpu.h> |
196 | #include <machine/dvma.h> | | 198 | #include <machine/dvma.h> |
197 | #include <machine/idprom.h> | | 199 | #include <machine/idprom.h> |
| | | 200 | #include <machine/intr.h> |
198 | #include <machine/kcore.h> | | 201 | #include <machine/kcore.h> |
199 | #include <machine/reg.h> | | | |
200 | #include <machine/pcb.h> | | 202 | #include <machine/pcb.h> |
| | | 203 | #include <machine/pmap.h> |
| | | 204 | #include <machine/promlib.h> |
201 | #include <machine/psl.h> | | 205 | #include <machine/psl.h> |
202 | #include <machine/pte.h> | | 206 | #include <machine/pte.h> |
203 | #define _SUN68K_BUS_DMA_PRIVATE | | 207 | #include <machine/reg.h> |
204 | #include <machine/autoconf.h> | | | |
205 | #include <machine/bus.h> | | | |
206 | #include <machine/intr.h> | | | |
207 | #include <machine/pmap.h> | | | |
208 | | | 208 | |
209 | #if defined(DDB) | | 209 | #if defined(DDB) |
210 | #include <machine/db_machdep.h> | | 210 | #include <machine/db_machdep.h> |
211 | #include <ddb/db_sym.h> | | | |
212 | #include <ddb/db_extern.h> | | 211 | #include <ddb/db_extern.h> |
| | | 212 | #include <ddb/db_sym.h> |
213 | #endif | | 213 | #endif |
214 | | | 214 | |
215 | #include <dev/vme/vmereg.h> | | 215 | #include <dev/vme/vmereg.h> |
216 | #include <dev/vme/vmevar.h> | | 216 | #include <dev/vme/vmevar.h> |
217 | | | 217 | |
218 | #include <sun2/sun2/control.h> | | 218 | #include <sun2/sun2/control.h> |
219 | #include <sun2/sun2/enable.h> | | 219 | #include <sun2/sun2/enable.h> |
220 | #include <sun2/sun2/machdep.h> | | 220 | #include <sun2/sun2/machdep.h> |
221 | | | 221 | |
222 | #include <sun68k/sun68k/vme_sun68k.h> | | 222 | #include <sun68k/sun68k/vme_sun68k.h> |
223 | | | 223 | |
224 | #include "ksyms.h" | | 224 | #include "ksyms.h" |
225 | | | 225 | |