diff options
author | Jason Wright <jason@cvs.openbsd.org> | 2003-05-14 05:18:49 +0000 |
---|---|---|
committer | Jason Wright <jason@cvs.openbsd.org> | 2003-05-14 05:18:49 +0000 |
commit | d3c3f9a9eae2627f4ff02be6048ddbe229053966 (patch) | |
tree | ea9acd74a10da206ebe463709c4d824c81a9bab8 /sys/dev/pci/eap.c | |
parent | 9332ed24738c77a81d45cb0d0eddc604058db3ea (diff) |
time bound some of the loops instead of depending on pci read to determine
the loop time... icky poo! ok millert, tested by margarida
Diffstat (limited to 'sys/dev/pci/eap.c')
-rw-r--r-- | sys/dev/pci/eap.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/pci/eap.c b/sys/dev/pci/eap.c index b3cb79e8b04..436ec29270c 100644 --- a/sys/dev/pci/eap.c +++ b/sys/dev/pci/eap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: eap.c,v 1.19 2003/04/27 11:22:53 ho Exp $ */ +/* $OpenBSD: eap.c,v 1.20 2003/05/14 05:18:48 jason Exp $ */ /* $NetBSD: eap.c,v 1.46 2001/09/03 15:07:37 reinoud Exp $ */ /* @@ -348,6 +348,7 @@ eap1371_read_codec(void *sc_, u_int8_t a, u_int16_t *d) for (to = 0; to < EAP_WRITE_TIMEOUT; to++) { if (!(EREAD4(sc, E1371_CODEC) & E1371_CODEC_WIP)) break; + delay(1); } if (to == EAP_WRITE_TIMEOUT) printf("%s: eap1371_read_codec timeout 1\n", @@ -357,6 +358,7 @@ eap1371_read_codec(void *sc_, u_int8_t a, u_int16_t *d) t = EREAD4(sc, E1371_CODEC); if (t & E1371_CODEC_VALID) break; + delay(1); } if (to == EAP_WRITE_TIMEOUT) printf("%s: eap1371_read_codec timeout 2\n", |