Use direct config for subdevices.
This commit is contained in:
parent
e148dc7a64
commit
326830c1ba
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: ast.c,v 1.12 1994/11/18 22:07:32 mycroft Exp $ */
|
||||
/* $NetBSD: ast.c,v 1.13 1995/01/02 22:27:46 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
* Multi-port serial card interrupt demuxing support.
|
||||
@ -29,7 +29,7 @@ void astattach();
|
||||
int astintr __P((struct ast_softc *));
|
||||
|
||||
struct cfdriver astcd = {
|
||||
NULL, "ast", astprobe, astattach, DV_TTY, sizeof(struct ast_softc), 1
|
||||
NULL, "ast", astprobe, astattach, DV_TTY, sizeof(struct ast_softc)
|
||||
};
|
||||
|
||||
int
|
||||
@ -100,16 +100,17 @@ astattach(parent, self, aux)
|
||||
|
||||
isa.ia_aux = &aa;
|
||||
for (aa.aa_slave = 0; aa.aa_slave < 4; aa.aa_slave++) {
|
||||
void *match;
|
||||
struct cfdata *cf;
|
||||
isa.ia_iobase = sc->sc_iobase + 8 * aa.aa_slave;
|
||||
isa.ia_iosize = 0x666;
|
||||
isa.ia_irq = IRQUNK;
|
||||
isa.ia_drq = DRQUNK;
|
||||
isa.ia_msize = 0;
|
||||
if ((match = config_search(astsubmatch, self, &isa)) != 0) {
|
||||
sc->sc_slaves[aa.aa_slave] = match;
|
||||
if ((cf = config_search(astsubmatch, self, &isa)) != 0) {
|
||||
config_attach(self, cf, &isa, astprint);
|
||||
sc->sc_slaves[aa.aa_slave] =
|
||||
cf->cf_driver->cd_devs[cf->cf_unit];
|
||||
sc->sc_alive |= 1 << aa.aa_slave;
|
||||
config_attach(self, match, &isa, astprint);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: rtfps.c,v 1.7 1994/11/18 22:25:19 mycroft Exp $ */
|
||||
/* $NetBSD: rtfps.c,v 1.8 1995/01/02 22:27:47 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
* Multi-port serial card interrupt demuxing support.
|
||||
@ -30,7 +30,7 @@ void rtfpsattach();
|
||||
int rtfpsintr __P((struct rtfps_softc *));
|
||||
|
||||
struct cfdriver rtfpscd = {
|
||||
NULL, "rtfps", rtfpsprobe, rtfpsattach, DV_TTY, sizeof(struct rtfps_softc), 1
|
||||
NULL, "rtfps", rtfpsprobe, rtfpsattach, DV_TTY, sizeof(struct rtfps_softc)
|
||||
};
|
||||
|
||||
int
|
||||
@ -108,16 +108,17 @@ rtfpsattach(parent, self, aux)
|
||||
|
||||
isa.ia_aux = &ra;
|
||||
for (ra.ra_slave = 0; ra.ra_slave < 4; ra.ra_slave++) {
|
||||
void *match;
|
||||
struct cfdata *cf;
|
||||
isa.ia_iobase = sc->sc_iobase + 8 * ra.ra_slave;
|
||||
isa.ia_iosize = 0x666;
|
||||
isa.ia_irq = IRQUNK;
|
||||
isa.ia_drq = DRQUNK;
|
||||
isa.ia_msize = 0;
|
||||
if ((match = config_search(rtfpssubmatch, self, &isa)) != 0) {
|
||||
sc->sc_slaves[ra.ra_slave] = match;
|
||||
if ((cf = config_search(rtfpssubmatch, self, &isa)) != 0) {
|
||||
config_attach(self, cf, &isa, rtfpsprint);
|
||||
sc->sc_slaves[ra.ra_slave] =
|
||||
cf->cf_driver->cd_devs[cf->cf_unit];
|
||||
sc->sc_alive |= 1 << ra.ra_slave;
|
||||
config_attach(self, match, &isa, rtfpsprint);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: ast.c,v 1.12 1994/11/18 22:07:32 mycroft Exp $ */
|
||||
/* $NetBSD: ast.c,v 1.13 1995/01/02 22:27:46 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
* Multi-port serial card interrupt demuxing support.
|
||||
@ -29,7 +29,7 @@ void astattach();
|
||||
int astintr __P((struct ast_softc *));
|
||||
|
||||
struct cfdriver astcd = {
|
||||
NULL, "ast", astprobe, astattach, DV_TTY, sizeof(struct ast_softc), 1
|
||||
NULL, "ast", astprobe, astattach, DV_TTY, sizeof(struct ast_softc)
|
||||
};
|
||||
|
||||
int
|
||||
@ -100,16 +100,17 @@ astattach(parent, self, aux)
|
||||
|
||||
isa.ia_aux = &aa;
|
||||
for (aa.aa_slave = 0; aa.aa_slave < 4; aa.aa_slave++) {
|
||||
void *match;
|
||||
struct cfdata *cf;
|
||||
isa.ia_iobase = sc->sc_iobase + 8 * aa.aa_slave;
|
||||
isa.ia_iosize = 0x666;
|
||||
isa.ia_irq = IRQUNK;
|
||||
isa.ia_drq = DRQUNK;
|
||||
isa.ia_msize = 0;
|
||||
if ((match = config_search(astsubmatch, self, &isa)) != 0) {
|
||||
sc->sc_slaves[aa.aa_slave] = match;
|
||||
if ((cf = config_search(astsubmatch, self, &isa)) != 0) {
|
||||
config_attach(self, cf, &isa, astprint);
|
||||
sc->sc_slaves[aa.aa_slave] =
|
||||
cf->cf_driver->cd_devs[cf->cf_unit];
|
||||
sc->sc_alive |= 1 << aa.aa_slave;
|
||||
config_attach(self, match, &isa, astprint);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: rtfps.c,v 1.7 1994/11/18 22:25:19 mycroft Exp $ */
|
||||
/* $NetBSD: rtfps.c,v 1.8 1995/01/02 22:27:47 mycroft Exp $ */
|
||||
|
||||
/*
|
||||
* Multi-port serial card interrupt demuxing support.
|
||||
@ -30,7 +30,7 @@ void rtfpsattach();
|
||||
int rtfpsintr __P((struct rtfps_softc *));
|
||||
|
||||
struct cfdriver rtfpscd = {
|
||||
NULL, "rtfps", rtfpsprobe, rtfpsattach, DV_TTY, sizeof(struct rtfps_softc), 1
|
||||
NULL, "rtfps", rtfpsprobe, rtfpsattach, DV_TTY, sizeof(struct rtfps_softc)
|
||||
};
|
||||
|
||||
int
|
||||
@ -108,16 +108,17 @@ rtfpsattach(parent, self, aux)
|
||||
|
||||
isa.ia_aux = &ra;
|
||||
for (ra.ra_slave = 0; ra.ra_slave < 4; ra.ra_slave++) {
|
||||
void *match;
|
||||
struct cfdata *cf;
|
||||
isa.ia_iobase = sc->sc_iobase + 8 * ra.ra_slave;
|
||||
isa.ia_iosize = 0x666;
|
||||
isa.ia_irq = IRQUNK;
|
||||
isa.ia_drq = DRQUNK;
|
||||
isa.ia_msize = 0;
|
||||
if ((match = config_search(rtfpssubmatch, self, &isa)) != 0) {
|
||||
sc->sc_slaves[ra.ra_slave] = match;
|
||||
if ((cf = config_search(rtfpssubmatch, self, &isa)) != 0) {
|
||||
config_attach(self, cf, &isa, rtfpsprint);
|
||||
sc->sc_slaves[ra.ra_slave] =
|
||||
cf->cf_driver->cd_devs[cf->cf_unit];
|
||||
sc->sc_alive |= 1 << ra.ra_slave;
|
||||
config_attach(self, match, &isa, rtfpsprint);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user