-/* $OpenBSD: isa.c,v 1.8 1996/05/07 07:37:07 deraadt Exp $ */
-/* $NetBSD: isa.c,v 1.81 1996/04/29 20:03:24 christos Exp $ */
+/* $OpenBSD: isa.c,v 1.9 1996/05/10 12:37:45 deraadt Exp $ */
+/* $NetBSD: isa.c,v 1.82 1996/05/05 01:14:07 thorpej Exp $ */
/*-
* Copyright (c) 1993, 1994 Charles Hannum. All rights reserved.
sc->sc_bc = iba->iba_bc;
sc->sc_ic = iba->iba_ic;
+ /*
+ * Map port 0x84, which causes a 2.5us delay when read.
+ * We do this now, since several drivers need it.
+ */
+ if (bus_io_map(sc->sc_bc, 0x84, 1, &sc->sc_delayioh))
+ panic("isaattach: can't map `delay port'"); /* XXX */
+
TAILQ_INIT(&sc->sc_subdevs);
config_scan(isascan, self);
}
ia.ia_msize = cf->cf_loc[3];
ia.ia_irq = cf->cf_loc[4] == 2 ? 9 : cf->cf_loc[4];
ia.ia_drq = cf->cf_loc[5];
+ ia.ia_delayioh = sc->sc_delayioh;
if ((*cf->cf_attach->ca_match)(parent, dev, &ia) > 0)
config_attach(parent, dev, &ia, isaprint);
-/* $OpenBSD: isavar.h,v 1.9 1996/04/27 18:39:07 niklas Exp $ */
-/* $NetBSD: isavar.h,v 1.21 1996/04/11 22:20:50 cgd Exp $ */
+/* $OpenBSD: isavar.h,v 1.10 1996/05/10 12:37:45 deraadt Exp $ */
+/* $NetBSD: isavar.h,v 1.22 1996/05/05 01:14:14 thorpej Exp $ */
/*
* Copyright (c) 1995 Chris G. Demetriou
int ia_maddr; /* physical i/o mem addr */
u_int ia_msize; /* size of i/o memory */
void *ia_aux; /* driver specific */
+
+ bus_io_handle_t ia_delayioh; /* i/o handle for `delay port' */
};
#define IOBASEUNK -1 /* i/o address is unknown */
bus_chipset_tag_t sc_bc;
isa_chipset_tag_t sc_ic;
+
+ /*
+ * This i/o handle is used to map port 0x84, which is
+ * read to provide a 2.5us delay. This i/o handle
+ * is mapped in isaattach(), and exported to drivers
+ * via isa_attach_args.
+ */
+ bus_io_handle_t sc_delayioh;
};
#define cf_iobase cf_loc[0]