asc_tc.c revision 1.15.2.1 1 1.15.2.1 fvdl /* $NetBSD: asc_tc.c,v 1.15.2.1 2001/10/11 00:02:27 fvdl Exp $ */
2 1.1 jonathan
3 1.15.2.1 fvdl /*-
4 1.15.2.1 fvdl * Copyright (c) 2000 The NetBSD Foundation, Inc.
5 1.15.2.1 fvdl * All rights reserved.
6 1.15.2.1 fvdl *
7 1.15.2.1 fvdl * This code is derived from software contributed to The NetBSD Foundation
8 1.15.2.1 fvdl * by Tohru Nishimura.
9 1.1 jonathan *
10 1.15.2.1 fvdl * Redistribution and use in source and binary forms, with or without
11 1.15.2.1 fvdl * modification, are permitted provided that the following conditions
12 1.15.2.1 fvdl * are met:
13 1.15.2.1 fvdl * 1. Redistributions of source code must retain the above copyright
14 1.15.2.1 fvdl * notice, this list of conditions and the following disclaimer.
15 1.15.2.1 fvdl * 2. Redistributions in binary form must reproduce the above copyright
16 1.15.2.1 fvdl * notice, this list of conditions and the following disclaimer in the
17 1.15.2.1 fvdl * documentation and/or other materials provided with the distribution.
18 1.15.2.1 fvdl * 3. All advertising materials mentioning features or use of this software
19 1.15.2.1 fvdl * must display the following acknowledgement:
20 1.15.2.1 fvdl * This product includes software developed by the NetBSD
21 1.15.2.1 fvdl * Foundation, Inc. and its contributors.
22 1.15.2.1 fvdl * 4. Neither the name of The NetBSD Foundation nor the names of its
23 1.15.2.1 fvdl * contributors may be used to endorse or promote products derived
24 1.15.2.1 fvdl * from this software without specific prior written permission.
25 1.1 jonathan *
26 1.15.2.1 fvdl * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
27 1.15.2.1 fvdl * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
28 1.15.2.1 fvdl * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
29 1.15.2.1 fvdl * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
30 1.15.2.1 fvdl * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
31 1.15.2.1 fvdl * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
32 1.15.2.1 fvdl * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
33 1.15.2.1 fvdl * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
34 1.15.2.1 fvdl * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
35 1.15.2.1 fvdl * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
36 1.15.2.1 fvdl * POSSIBILITY OF SUCH DAMAGE.
37 1.1 jonathan */
38 1.1 jonathan
39 1.15.2.1 fvdl #include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
40 1.15.2.1 fvdl __KERNEL_RCSID(0, "$NetBSD: asc_tc.c,v 1.15.2.1 2001/10/11 00:02:27 fvdl Exp $");
41 1.15.2.1 fvdl
42 1.15.2.1 fvdl #include <sys/types.h>
43 1.1 jonathan #include <sys/param.h>
44 1.1 jonathan #include <sys/systm.h>
45 1.1 jonathan #include <sys/device.h>
46 1.15.2.1 fvdl #include <sys/buf.h>
47 1.10 mrg
48 1.15.2.1 fvdl #include <dev/scsipi/scsi_all.h>
49 1.15.2.1 fvdl #include <dev/scsipi/scsipi_all.h>
50 1.15.2.1 fvdl #include <dev/scsipi/scsiconf.h>
51 1.15.2.1 fvdl #include <dev/scsipi/scsi_message.h>
52 1.1 jonathan
53 1.15.2.1 fvdl #include <machine/bus.h>
54 1.1 jonathan
55 1.15.2.1 fvdl #include <dev/ic/ncr53c9xreg.h>
56 1.15.2.1 fvdl #include <dev/ic/ncr53c9xvar.h>
57 1.1 jonathan
58 1.15.2.1 fvdl #include <dev/tc/tcvar.h>
59 1.1 jonathan
60 1.15.2.1 fvdl struct asc_softc {
61 1.15.2.1 fvdl struct ncr53c9x_softc sc_ncr53c9x; /* glue to MI code */
62 1.15.2.1 fvdl bus_space_tag_t sc_bst;
63 1.15.2.1 fvdl bus_space_handle_t sc_bsh;
64 1.15.2.1 fvdl bus_dma_tag_t sc_dmat;
65 1.15.2.1 fvdl bus_dmamap_t sc_dmamap;
66 1.15.2.1 fvdl caddr_t *sc_dmaaddr;
67 1.15.2.1 fvdl size_t *sc_dmalen;
68 1.15.2.1 fvdl size_t sc_dmasize;
69 1.15.2.1 fvdl int sc_active; /* DMA active ? */
70 1.15.2.1 fvdl int sc_ispullup; /* DMA into main memory? */
71 1.1 jonathan
72 1.15.2.1 fvdl /* XXX XXX XXX */
73 1.15.2.1 fvdl caddr_t sc_base, sc_bounce, sc_target;
74 1.15.2.1 fvdl };
75 1.15.2.1 fvdl
76 1.15.2.1 fvdl static int asc_tc_match __P((struct device *, struct cfdata *, void *));
77 1.15.2.1 fvdl static void asc_tc_attach __P((struct device *, struct device *, void *));
78 1.1 jonathan
79 1.1 jonathan struct cfattach asc_tc_ca = {
80 1.1 jonathan sizeof(struct asc_softc), asc_tc_match, asc_tc_attach
81 1.1 jonathan };
82 1.1 jonathan
83 1.15.2.1 fvdl static u_char asc_read_reg __P((struct ncr53c9x_softc *, int));
84 1.15.2.1 fvdl static void asc_write_reg __P((struct ncr53c9x_softc *, int, u_char));
85 1.15.2.1 fvdl static int asc_dma_isintr __P((struct ncr53c9x_softc *));
86 1.15.2.1 fvdl static void asc_tc_reset __P((struct ncr53c9x_softc *));
87 1.15.2.1 fvdl static int asc_tc_intr __P((struct ncr53c9x_softc *));
88 1.15.2.1 fvdl static int asc_tc_setup __P((struct ncr53c9x_softc *, caddr_t *,
89 1.15.2.1 fvdl size_t *, int, size_t *));
90 1.15.2.1 fvdl static void asc_tc_go __P((struct ncr53c9x_softc *));
91 1.15.2.1 fvdl static void asc_tc_stop __P((struct ncr53c9x_softc *));
92 1.15.2.1 fvdl static int asc_dma_isactive __P((struct ncr53c9x_softc *));
93 1.15.2.1 fvdl static void asc_clear_latched_intr __P((struct ncr53c9x_softc *));
94 1.15.2.1 fvdl
95 1.15.2.1 fvdl static struct ncr53c9x_glue asc_tc_glue = {
96 1.15.2.1 fvdl asc_read_reg,
97 1.15.2.1 fvdl asc_write_reg,
98 1.15.2.1 fvdl asc_dma_isintr,
99 1.15.2.1 fvdl asc_tc_reset,
100 1.15.2.1 fvdl asc_tc_intr,
101 1.15.2.1 fvdl asc_tc_setup,
102 1.15.2.1 fvdl asc_tc_go,
103 1.15.2.1 fvdl asc_tc_stop,
104 1.15.2.1 fvdl asc_dma_isactive,
105 1.15.2.1 fvdl asc_clear_latched_intr,
106 1.15.2.1 fvdl };
107 1.15.2.1 fvdl
108 1.1 jonathan /*
109 1.15.2.1 fvdl * Parameters specific to PMAZ-A TC option card.
110 1.1 jonathan */
111 1.15.2.1 fvdl #define PMAZ_OFFSET_53C94 0x0 /* from module base */
112 1.15.2.1 fvdl #define PMAZ_OFFSET_DMAR 0x40000 /* DMA Address Register */
113 1.15.2.1 fvdl #define PMAZ_OFFSET_RAM 0x80000 /* 128KB SRAM buffer */
114 1.15.2.1 fvdl #define PMAZ_OFFSET_ROM 0xc0000 /* diagnostic ROM */
115 1.15.2.1 fvdl
116 1.15.2.1 fvdl #define PMAZ_RAM_SIZE 0x20000 /* 128k (32k*32) */
117 1.15.2.1 fvdl #define PER_TGT_DMA_SIZE ((PMAZ_RAM_SIZE/7) & ~(sizeof(int)-1))
118 1.15.2.1 fvdl
119 1.15.2.1 fvdl #define PMAZ_DMAR_WRITE 0x80000000 /* DMA direction bit */
120 1.15.2.1 fvdl #define PMAZ_DMAR_MASK 0x1ffff /* 17 bits, 128k */
121 1.15.2.1 fvdl #define PMAZ_DMA_ADDR(x) ((unsigned long)(x) & PMAZ_DMAR_MASK)
122 1.1 jonathan
123 1.7 mhitch static int
124 1.15.2.1 fvdl asc_tc_match(parent, cfdata, aux)
125 1.1 jonathan struct device *parent;
126 1.15.2.1 fvdl struct cfdata *cfdata;
127 1.1 jonathan void *aux;
128 1.1 jonathan {
129 1.15.2.1 fvdl struct tc_attach_args *d = aux;
130 1.15.2.1 fvdl
131 1.15.2.1 fvdl if (strncmp("PMAZ-AA ", d->ta_modname, TC_ROM_LLEN))
132 1.1 jonathan return (0);
133 1.1 jonathan
134 1.1 jonathan return (1);
135 1.1 jonathan }
136 1.1 jonathan
137 1.15.2.1 fvdl static void
138 1.1 jonathan asc_tc_attach(parent, self, aux)
139 1.15.2.1 fvdl struct device *parent, *self;
140 1.1 jonathan void *aux;
141 1.1 jonathan {
142 1.15.2.1 fvdl struct tc_attach_args *ta = aux;
143 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)self;
144 1.15.2.1 fvdl struct ncr53c9x_softc *sc = &asc->sc_ncr53c9x;
145 1.1 jonathan
146 1.1 jonathan /*
147 1.15.2.1 fvdl * Set up glue for MI code early; we use some of it here.
148 1.1 jonathan */
149 1.15.2.1 fvdl sc->sc_glue = &asc_tc_glue;
150 1.15.2.1 fvdl asc->sc_bst = ta->ta_memt;
151 1.15.2.1 fvdl asc->sc_dmat = ta->ta_dmat;
152 1.15.2.1 fvdl if (bus_space_map(asc->sc_bst, ta->ta_addr,
153 1.15.2.1 fvdl PMAZ_OFFSET_RAM + PMAZ_RAM_SIZE, 0, &asc->sc_bsh)) {
154 1.15.2.1 fvdl printf("%s: unable to map device\n", sc->sc_dev.dv_xname);
155 1.15.2.1 fvdl return;
156 1.15.2.1 fvdl }
157 1.15.2.1 fvdl asc->sc_base = (caddr_t)ta->ta_addr; /* XXX XXX XXX */
158 1.15.2.1 fvdl
159 1.15.2.1 fvdl tc_intr_establish(parent, ta->ta_cookie, IPL_BIO, ncr53c9x_intr, sc);
160 1.15.2.1 fvdl
161 1.15.2.1 fvdl sc->sc_id = 7;
162 1.15.2.1 fvdl sc->sc_freq = (ta->ta_busspeed) ? 25000000 : 12500000;
163 1.15.2.1 fvdl
164 1.15.2.1 fvdl /* gimme Mhz */
165 1.15.2.1 fvdl sc->sc_freq /= 1000000;
166 1.1 jonathan
167 1.1 jonathan /*
168 1.15.2.1 fvdl * XXX More of this should be in ncr53c9x_attach(), but
169 1.15.2.1 fvdl * XXX should we really poke around the chip that much in
170 1.15.2.1 fvdl * XXX the MI code? Think about this more...
171 1.1 jonathan */
172 1.1 jonathan
173 1.1 jonathan /*
174 1.15.2.1 fvdl * Set up static configuration info.
175 1.1 jonathan */
176 1.15.2.1 fvdl sc->sc_cfg1 = sc->sc_id | NCRCFG1_PARENB;
177 1.15.2.1 fvdl sc->sc_cfg2 = NCRCFG2_SCSI2;
178 1.15.2.1 fvdl sc->sc_cfg3 = 0;
179 1.15.2.1 fvdl sc->sc_rev = NCR_VARIANT_NCR53C94;
180 1.7 mhitch
181 1.7 mhitch /*
182 1.15.2.1 fvdl * XXX minsync and maxxfer _should_ be set up in MI code,
183 1.15.2.1 fvdl * XXX but it appears to have some dependency on what sort
184 1.15.2.1 fvdl * XXX of DMA we're hooked up to, etc.
185 1.7 mhitch */
186 1.7 mhitch
187 1.7 mhitch /*
188 1.15.2.1 fvdl * This is the value used to start sync negotiations
189 1.15.2.1 fvdl * Note that the NCR register "SYNCTP" is programmed
190 1.15.2.1 fvdl * in "clocks per byte", and has a minimum value of 4.
191 1.15.2.1 fvdl * The SCSI period used in negotiation is one-fourth
192 1.15.2.1 fvdl * of the time (in nanoseconds) needed to transfer one byte.
193 1.15.2.1 fvdl * Since the chip's clock is given in MHz, we have the following
194 1.15.2.1 fvdl * formula: 4 * period = (1000 / freq) * 4
195 1.7 mhitch */
196 1.15.2.1 fvdl sc->sc_minsync = (1000 / sc->sc_freq) * 5 / 4;
197 1.7 mhitch
198 1.15.2.1 fvdl sc->sc_maxxfer = 64 * 1024;
199 1.1 jonathan
200 1.15.2.1 fvdl /* Do the common parts of attachment. */
201 1.15.2.1 fvdl sc->sc_adapter.adapt_minphys = minphys;
202 1.15.2.1 fvdl sc->sc_adapter.adapt_request = ncr53c9x_scsipi_request;
203 1.15.2.1 fvdl ncr53c9x_attach(sc);
204 1.15.2.1 fvdl }
205 1.15.2.1 fvdl
206 1.15.2.1 fvdl static void
207 1.15.2.1 fvdl asc_tc_reset(sc)
208 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
209 1.15.2.1 fvdl {
210 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
211 1.1 jonathan
212 1.15.2.1 fvdl asc->sc_active = 0;
213 1.1 jonathan }
214 1.1 jonathan
215 1.15.2.1 fvdl static int
216 1.15.2.1 fvdl asc_tc_intr(sc)
217 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
218 1.15.2.1 fvdl {
219 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
220 1.15.2.1 fvdl int trans, resid;
221 1.15.2.1 fvdl
222 1.15.2.1 fvdl resid = 0;
223 1.15.2.1 fvdl if (!asc->sc_ispullup &&
224 1.15.2.1 fvdl (resid = (NCR_READ_REG(sc, NCR_FFLAG) & NCRFIFO_FF)) != 0) {
225 1.15.2.1 fvdl NCR_DMA(("asc_tc_intr: empty FIFO of %d ", resid));
226 1.15.2.1 fvdl DELAY(1);
227 1.15.2.1 fvdl }
228 1.15.2.1 fvdl
229 1.15.2.1 fvdl resid += NCR_READ_REG(sc, NCR_TCL);
230 1.15.2.1 fvdl resid += NCR_READ_REG(sc, NCR_TCM) << 8;
231 1.15.2.1 fvdl
232 1.15.2.1 fvdl trans = asc->sc_dmasize - resid;
233 1.15.2.1 fvdl
234 1.15.2.1 fvdl if (asc->sc_ispullup)
235 1.15.2.1 fvdl memcpy(asc->sc_target, asc->sc_bounce, trans);
236 1.15.2.1 fvdl *asc->sc_dmalen -= trans;
237 1.15.2.1 fvdl *asc->sc_dmaaddr += trans;
238 1.15.2.1 fvdl asc->sc_active = 0;
239 1.15.2.1 fvdl
240 1.15.2.1 fvdl return (0);
241 1.15.2.1 fvdl }
242 1.15.2.1 fvdl
243 1.15.2.1 fvdl static int
244 1.15.2.1 fvdl asc_tc_setup(sc, addr, len, datain, dmasize)
245 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
246 1.15.2.1 fvdl caddr_t *addr;
247 1.15.2.1 fvdl size_t *len;
248 1.15.2.1 fvdl int datain;
249 1.15.2.1 fvdl size_t *dmasize;
250 1.15.2.1 fvdl {
251 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
252 1.15.2.1 fvdl u_int32_t tc_dmar;
253 1.15.2.1 fvdl size_t size;
254 1.15.2.1 fvdl
255 1.15.2.1 fvdl asc->sc_dmaaddr = addr;
256 1.15.2.1 fvdl asc->sc_dmalen = len;
257 1.15.2.1 fvdl asc->sc_ispullup = datain;
258 1.15.2.1 fvdl
259 1.15.2.1 fvdl NCR_DMA(("asc_tc_setup: start %ld@%p, %s\n", (long)*asc->sc_dmalen,
260 1.15.2.1 fvdl *asc->sc_dmaaddr, datain ? "IN" : "OUT"));
261 1.15.2.1 fvdl
262 1.15.2.1 fvdl size = *dmasize;
263 1.15.2.1 fvdl if (size > PER_TGT_DMA_SIZE)
264 1.15.2.1 fvdl size = PER_TGT_DMA_SIZE;
265 1.15.2.1 fvdl *dmasize = asc->sc_dmasize = size;
266 1.15.2.1 fvdl
267 1.15.2.1 fvdl NCR_DMA(("asc_tc_setup: dmasize = %ld\n", (long)asc->sc_dmasize));
268 1.15.2.1 fvdl
269 1.15.2.1 fvdl asc->sc_bounce = asc->sc_base + PMAZ_OFFSET_RAM;
270 1.15.2.1 fvdl asc->sc_bounce += PER_TGT_DMA_SIZE *
271 1.15.2.1 fvdl sc->sc_nexus->xs->xs_periph->periph_target;
272 1.15.2.1 fvdl asc->sc_target = *addr;
273 1.15.2.1 fvdl
274 1.15.2.1 fvdl if (!asc->sc_ispullup)
275 1.15.2.1 fvdl memcpy(asc->sc_bounce, asc->sc_target, size);
276 1.15.2.1 fvdl
277 1.15.2.1 fvdl #if 1
278 1.15.2.1 fvdl if (asc->sc_ispullup)
279 1.15.2.1 fvdl tc_dmar = PMAZ_DMA_ADDR(asc->sc_bounce);
280 1.15.2.1 fvdl else
281 1.15.2.1 fvdl tc_dmar = PMAZ_DMAR_WRITE | PMAZ_DMA_ADDR(asc->sc_bounce);
282 1.15.2.1 fvdl bus_space_write_4(asc->sc_bst, asc->sc_bsh, PMAZ_OFFSET_DMAR, tc_dmar);
283 1.15.2.1 fvdl asc->sc_active = 1;
284 1.15.2.1 fvdl #endif
285 1.15.2.1 fvdl return (0);
286 1.15.2.1 fvdl }
287 1.15.2.1 fvdl
288 1.15.2.1 fvdl static void
289 1.15.2.1 fvdl asc_tc_go(sc)
290 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
291 1.15.2.1 fvdl {
292 1.15.2.1 fvdl #if 0
293 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
294 1.15.2.1 fvdl u_int32_t tc_dmar;
295 1.15.2.1 fvdl
296 1.15.2.1 fvdl if (asc->sc_ispullup)
297 1.15.2.1 fvdl tc_dmar = PMAZ_DMA_ADDR(asc->sc_bounce);
298 1.15.2.1 fvdl else
299 1.15.2.1 fvdl tc_dmar = PMAZ_DMAR_WRITE | PMAZ_DMA_ADDR(asc->sc_bounce);
300 1.15.2.1 fvdl bus_space_write_4(asc->sc_bst, asc->sc_bsh, PMAZ_OFFSET_DMAR, tc_dmar);
301 1.15.2.1 fvdl asc->sc_active = 1;
302 1.15.2.1 fvdl #endif
303 1.15.2.1 fvdl }
304 1.15.2.1 fvdl
305 1.15.2.1 fvdl /* NEVER CALLED BY MI 53C9x ENGINE INDEED */
306 1.15.2.1 fvdl static void
307 1.15.2.1 fvdl asc_tc_stop(sc)
308 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
309 1.15.2.1 fvdl {
310 1.15.2.1 fvdl #if 0
311 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
312 1.15.2.1 fvdl
313 1.15.2.1 fvdl if (asc->sc_ispullup)
314 1.15.2.1 fvdl memcpy(asc->sc_target, asc->sc_bounce, asc->sc_dmasize);
315 1.15.2.1 fvdl asc->sc_active = 0;
316 1.15.2.1 fvdl #endif
317 1.15.2.1 fvdl }
318 1.1 jonathan
319 1.1 jonathan /*
320 1.15.2.1 fvdl * Glue functions.
321 1.1 jonathan */
322 1.15.2.1 fvdl static u_char
323 1.15.2.1 fvdl asc_read_reg(sc, reg)
324 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
325 1.15.2.1 fvdl int reg;
326 1.15.2.1 fvdl {
327 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
328 1.15.2.1 fvdl u_char v;
329 1.15.2.1 fvdl
330 1.15.2.1 fvdl v = bus_space_read_4(asc->sc_bst, asc->sc_bsh,
331 1.15.2.1 fvdl reg * sizeof(u_int32_t)) & 0xff;
332 1.15.2.1 fvdl
333 1.15.2.1 fvdl return (v);
334 1.15.2.1 fvdl }
335 1.15.2.1 fvdl
336 1.15.2.1 fvdl static void
337 1.15.2.1 fvdl asc_write_reg(sc, reg, val)
338 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
339 1.15.2.1 fvdl int reg;
340 1.15.2.1 fvdl u_char val;
341 1.15.2.1 fvdl {
342 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
343 1.15.2.1 fvdl
344 1.15.2.1 fvdl bus_space_write_4(asc->sc_bst, asc->sc_bsh,
345 1.15.2.1 fvdl reg * sizeof(u_int32_t), val);
346 1.15.2.1 fvdl }
347 1.15.2.1 fvdl
348 1.15.2.1 fvdl static int
349 1.15.2.1 fvdl asc_dma_isintr(sc)
350 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
351 1.15.2.1 fvdl {
352 1.15.2.1 fvdl return !!(NCR_READ_REG(sc, NCR_STAT) & NCRSTAT_INT);
353 1.15.2.1 fvdl }
354 1.15.2.1 fvdl
355 1.7 mhitch static int
356 1.15.2.1 fvdl asc_dma_isactive(sc)
357 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
358 1.1 jonathan {
359 1.15.2.1 fvdl struct asc_softc *asc = (struct asc_softc *)sc;
360 1.1 jonathan
361 1.15.2.1 fvdl return (asc->sc_active);
362 1.1 jonathan }
363 1.1 jonathan
364 1.1 jonathan static void
365 1.15.2.1 fvdl asc_clear_latched_intr(sc)
366 1.15.2.1 fvdl struct ncr53c9x_softc *sc;
367 1.1 jonathan {
368 1.1 jonathan }
369