diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2004-08-19 10:22:02 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2004-08-19 10:22:02 +0000 |
commit | b8d0eab4980b9d45afa6bfe9bbabaa69e4a83d25 (patch) | |
tree | b11af7d73354b64e6ae967a53971f9ce3b12002b /sys/arch | |
parent | e03343059d550f49865abb3ad9b90d25857fe9d0 (diff) |
If a DMA operation takes longer time than usual, do not flood the console
too much with warning messages.
Diffstat (limited to 'sys/arch')
-rw-r--r-- | sys/arch/hp300/dev/spc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/arch/hp300/dev/spc.c b/sys/arch/hp300/dev/spc.c index 08e95a11182..5ef64b71fab 100644 --- a/sys/arch/hp300/dev/spc.c +++ b/sys/arch/hp300/dev/spc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: spc.c,v 1.1 2004/08/03 21:46:56 miod Exp $ */ +/* $OpenBSD: spc.c,v 1.2 2004/08/19 10:22:01 miod Exp $ */ /* $NetBSD: spc.c,v 1.2 2003/11/17 14:37:59 tsutsui Exp $ */ /* @@ -222,9 +222,11 @@ spc_dio_dmadone(struct spc_softc *sc) if ((spc_read(SSTS) & SSTS_BUSY) != 0) { int timeout = 1000; /* XXX how long? */ while ((spc_read(SSTS) & SSTS_BUSY) != 0) { - if (--timeout < 0) + if (--timeout < 0) { printf("%s: DMA complete timeout\n", sc->sc_dev.dv_xname); + timeout = 1000; + } DELAY(1); } } |