diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2001-05-01 16:51:11 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2001-05-01 16:51:11 +0000 |
commit | e6700178859f7c12ca3ca6223f8890b62c03e5c2 (patch) | |
tree | 3606a37015a96d78af7694a8d7340afdd1b0de8c /sys/arch/hp300/dev/dma.c | |
parent | 61ce39031c354943763c896117ea06630bc3f0f4 (diff) |
convert to new timeouts
Diffstat (limited to 'sys/arch/hp300/dev/dma.c')
-rw-r--r-- | sys/arch/hp300/dev/dma.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/sys/arch/hp300/dev/dma.c b/sys/arch/hp300/dev/dma.c index 78c0420c7d7..70ae2e7956a 100644 --- a/sys/arch/hp300/dev/dma.c +++ b/sys/arch/hp300/dev/dma.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dma.c,v 1.8 1997/07/06 08:01:49 downsj Exp $ */ +/* $OpenBSD: dma.c,v 1.9 2001/05/01 16:51:08 millert Exp $ */ /* $NetBSD: dma.c,v 1.19 1997/05/05 21:02:39 thorpej Exp $ */ /* @@ -50,6 +50,7 @@ #include <sys/kernel.h> #include <sys/proc.h> #include <sys/device.h> +#include <sys/timeout.h> #include <machine/frame.h> #include <machine/cpu.h> @@ -85,6 +86,9 @@ struct dma_channel { struct dma_softc { struct dmareg *sc_dmareg; /* pointer to our hardware */ struct dma_channel sc_chan[NDMACHAN]; /* 2 channels */ +#ifdef DEBUG + struct timeout sc_timeout; /* DMA timeout */ +#endif TAILQ_HEAD(, dmaqueue) sc_queue; /* job queue */ char sc_type; /* A, B, or C */ int sc_ipl; /* our interrupt level */ @@ -177,7 +181,8 @@ dmainit() #ifdef DEBUG /* make sure timeout is really not needed */ - timeout(dmatimeout, sc, 30 * hz); + timeout_set(&sc->sc_timeout, dmatimeout, sc); + timeout_add(&sc->sc_timeout, 30 * hz); #endif printf("98620%c, 2 channels, %d bit DMA\n", @@ -588,6 +593,6 @@ dmatimeout(arg) } splx(s); } - timeout(dmatimeout, sc, 30 * hz); + timeout_add(&sc->sc_timeout, 30 * hz); } #endif |