| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | /* $NetBSD: asp.c,v 1.19 2011/07/01 18:33:09 dyoung Exp $ */ | | 1 | /* $NetBSD: asp.c,v 1.20 2012/05/23 10:37:01 skrll Exp $ */ |
2 | | | 2 | |
3 | /* $OpenBSD: asp.c,v 1.5 2000/02/09 05:04:22 mickey Exp $ */ | | 3 | /* $OpenBSD: asp.c,v 1.5 2000/02/09 05:04:22 mickey Exp $ */ |
4 | | | 4 | |
5 | /* | | 5 | /* |
6 | * Copyright (c) 1998-2003 Michael Shalayeff | | 6 | * Copyright (c) 1998-2003 Michael Shalayeff |
7 | * All rights reserved. | | 7 | * All rights reserved. |
8 | * | | 8 | * |
9 | * Redistribution and use in source and binary forms, with or without | | 9 | * Redistribution and use in source and binary forms, with or without |
10 | * modification, are permitted provided that the following conditions | | 10 | * modification, are permitted provided that the following conditions |
11 | * are met: | | 11 | * are met: |
12 | * 1. Redistributions of source code must retain the above copyright | | 12 | * 1. Redistributions of source code must retain the above copyright |
13 | * notice, this list of conditions and the following disclaimer. | | 13 | * notice, this list of conditions and the following disclaimer. |
14 | * 2. Redistributions in binary form must reproduce the above copyright | | 14 | * 2. Redistributions in binary form must reproduce the above copyright |
| @@ -27,27 +27,27 @@ | | | @@ -27,27 +27,27 @@ |
27 | * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | | 27 | * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF |
28 | * THE POSSIBILITY OF SUCH DAMAGE. | | 28 | * THE POSSIBILITY OF SUCH DAMAGE. |
29 | */ | | 29 | */ |
30 | | | 30 | |
31 | /* | | 31 | /* |
32 | * References: | | 32 | * References: |
33 | * | | 33 | * |
34 | * 1. Cobra/Coral I/O Subsystem External Reference Specification | | 34 | * 1. Cobra/Coral I/O Subsystem External Reference Specification |
35 | * Hewlett-Packard | | 35 | * Hewlett-Packard |
36 | * | | 36 | * |
37 | */ | | 37 | */ |
38 | | | 38 | |
39 | #include <sys/cdefs.h> | | 39 | #include <sys/cdefs.h> |
40 | __KERNEL_RCSID(0, "$NetBSD: asp.c,v 1.19 2011/07/01 18:33:09 dyoung Exp $"); | | 40 | __KERNEL_RCSID(0, "$NetBSD: asp.c,v 1.20 2012/05/23 10:37:01 skrll Exp $"); |
41 | | | 41 | |
42 | #include <sys/param.h> | | 42 | #include <sys/param.h> |
43 | #include <sys/systm.h> | | 43 | #include <sys/systm.h> |
44 | #include <sys/device.h> | | 44 | #include <sys/device.h> |
45 | #include <sys/reboot.h> | | 45 | #include <sys/reboot.h> |
46 | | | 46 | |
47 | #include <sys/bus.h> | | 47 | #include <sys/bus.h> |
48 | #include <machine/iomod.h> | | 48 | #include <machine/iomod.h> |
49 | #include <machine/autoconf.h> | | 49 | #include <machine/autoconf.h> |
50 | #include <machine/cpufunc.h> | | 50 | #include <machine/cpufunc.h> |
51 | | | 51 | |
52 | #include <hp700/hp700/machdep.h> | | 52 | #include <hp700/hp700/machdep.h> |
53 | #include <hp700/dev/cpudevs.h> | | 53 | #include <hp700/dev/cpudevs.h> |
| @@ -191,27 +191,27 @@ aspattach(device_t parent, device_t self | | | @@ -191,27 +191,27 @@ aspattach(device_t parent, device_t self |
191 | struct confargs *ca = aux; | | 191 | struct confargs *ca = aux; |
192 | struct asp_softc *sc = device_private(self); | | 192 | struct asp_softc *sc = device_private(self); |
193 | struct gsc_attach_args ga; | | 193 | struct gsc_attach_args ga; |
194 | bus_space_handle_t ioh; | | 194 | bus_space_handle_t ioh; |
195 | uint32_t irr; | | 195 | uint32_t irr; |
196 | int s; | | 196 | int s; |
197 | | | 197 | |
198 | sc->sc_dev = self; | | 198 | sc->sc_dev = self; |
199 | | | 199 | |
200 | /* | | 200 | /* |
201 | * Map the ASP interrupt registers. | | 201 | * Map the ASP interrupt registers. |
202 | */ | | 202 | */ |
203 | if (bus_space_map(ca->ca_iot, ca->ca_hpa + ASP_REG_INT, | | 203 | if (bus_space_map(ca->ca_iot, ca->ca_hpa + ASP_REG_INT, |
204 | sizeof(struct asp_trs), 0, &ioh)) { | | 204 | sizeof(struct asp_trs), 0, &ioh)) { |
205 | aprint_error(": can't map interrupt registers.\n"); | | 205 | aprint_error(": can't map interrupt registers.\n"); |
206 | return; | | 206 | return; |
207 | } | | 207 | } |
208 | sc->sc_trs = (struct asp_trs *)ioh; | | 208 | sc->sc_trs = (struct asp_trs *)ioh; |
209 | | | 209 | |
210 | /* | | 210 | /* |
211 | * Map the ASP miscellaneous registers. | | 211 | * Map the ASP miscellaneous registers. |
212 | */ | | 212 | */ |
213 | if (bus_space_map(ca->ca_iot, ca->ca_hpa + ASP_REG_MISC, | | 213 | if (bus_space_map(ca->ca_iot, ca->ca_hpa + ASP_REG_MISC, |
214 | sizeof(struct asp_hwr), 0, &ioh)) { | | 214 | sizeof(struct asp_hwr), 0, &ioh)) { |
215 | aprint_error(": can't map miscellaneous registers.\n"); | | 215 | aprint_error(": can't map miscellaneous registers.\n"); |
216 | return; | | 216 | return; |
217 | } | | 217 | } |