diff options
author | Michael Shalayeff <mickey@cvs.openbsd.org> | 2000-07-21 17:41:07 +0000 |
---|---|---|
committer | Michael Shalayeff <mickey@cvs.openbsd.org> | 2000-07-21 17:41:07 +0000 |
commit | 7e8db0cf80ffef34a376325ca354af247366f3e4 (patch) | |
tree | 53e68852e1d5fa26316a25f80e56770fc1834e28 /sys/dev/isa/lpt_isa.c | |
parent | 120b5e87b31cf3a2eceace158d775a3b4f350d50 (diff) |
convert to new timeouts
Diffstat (limited to 'sys/dev/isa/lpt_isa.c')
-rw-r--r-- | sys/dev/isa/lpt_isa.c | 25 |
1 files changed, 10 insertions, 15 deletions
diff --git a/sys/dev/isa/lpt_isa.c b/sys/dev/isa/lpt_isa.c index fcd4ecdd9ac..ac7356c2064 100644 --- a/sys/dev/isa/lpt_isa.c +++ b/sys/dev/isa/lpt_isa.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lpt_isa.c,v 1.10 1999/01/30 01:41:48 imp Exp $ */ +/* $OpenBSD: lpt_isa.c,v 1.11 2000/07/21 17:41:03 mickey Exp $ */ /* * Copyright (c) 1993, 1994 Charles Hannum. @@ -176,24 +176,19 @@ lpt_isa_attach(parent, self, aux) { struct lpt_softc *sc = (void *)self; struct isa_attach_args *ia = aux; - bus_space_tag_t iot; - bus_space_handle_t ioh; - - if (ia->ia_irq != IRQUNK) - printf("\n"); - else { - sc->sc_flags |= LPT_POLLED; - printf(": polled\n"); - } sc->sc_state = 0; - - iot = sc->sc_iot = ia->ia_iot; - if (bus_space_map(iot, ia->ia_iobase, ia->ia_iosize, 0, &ioh)) + sc->sc_iot = ia->ia_iot; + if (bus_space_map(sc->sc_iot, ia->ia_iobase, ia->ia_iosize, 0, + &sc->sc_ioh)) panic("lpt_isa_attach: couldn't map I/O ports"); - sc->sc_ioh = ioh; - bus_space_write_1(iot, ioh, lpt_control, LPC_NINIT); + if (ia->ia_irq == IRQUNK) { + sc->sc_flags |= LPT_POLLED; + printf(": polled"); + } + + lpt_attach_common(sc); if (ia->ia_irq != IRQUNK) sc->sc_ih = isa_intr_establish(ia->ia_ic, ia->ia_irq, IST_EDGE, |