summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkettenis <kettenis@openbsd.org>2019-08-18 15:52:45 +0000
committerkettenis <kettenis@openbsd.org>2019-08-18 15:52:45 +0000
commit66fc675e45f83cbc4af4bcc8fce5b9d5fc46aa8c (patch)
tree564e2e0511737fbde0d2bc47b21e56cf56242e0c
parentIn polled mode, wait on STOP detected bit to be set in the interrupt status (diff)
downloadwireguard-openbsd-66fc675e45f83cbc4af4bcc8fce5b9d5fc46aa8c.tar.xz
wireguard-openbsd-66fc675e45f83cbc4af4bcc8fce5b9d5fc46aa8c.zip
Increase timeout used when waiting for the Rx FIFO to fill up when in polled
mode. ok jcs@, mlarkin@
-rw-r--r--sys/dev/ic/dwiic.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/ic/dwiic.c b/sys/dev/ic/dwiic.c
index 89de133ee1b..bae04efa0fa 100644
--- a/sys/dev/ic/dwiic.c
+++ b/sys/dev/ic/dwiic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dwiic.c,v 1.7 2019/08/18 15:51:18 kettenis Exp $ */
+/* $OpenBSD: dwiic.c,v 1.8 2019/08/18 15:52:45 kettenis Exp $ */
/*
* Synopsys DesignWare I2C controller
*
@@ -350,7 +350,7 @@ dwiic_i2c_exec(void *cookie, i2c_op_t op, i2c_addr_t addr, const void *cmdbuf,
sc->sc_dev.dv_xname, __func__, tx_limit, x));
if (flags & I2C_F_POLL) {
- for (retries = 100; retries > 0; retries--) {
+ for (retries = 1000; retries > 0; retries--) {
rx_avail = dwiic_read(sc, DW_IC_RXFLR);
if (rx_avail > 0)
break;