aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>2003-06-11 16:51:27 +0000
committerWarner Losh <imp@FreeBSD.org>2003-06-11 16:51:27 +0000
commit7988ce93e8bc1021892b887aa287222736749152 (patch)
treec201d860ea1bda0152f6c472d4f1c87473ff99ba
parent729a248d6378ff8c4094f8b69bd33a58daa403bd (diff)
downloadsrc-7988ce93e8bc1021892b887aa287222736749152.tar.gz
src-7988ce93e8bc1021892b887aa287222736749152.zip
Minor tweaks that are effectively all style tweaks.
Notes
Notes: svn path=/head/; revision=116206
-rw-r--r--sys/dev/wi/if_wi.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/sys/dev/wi/if_wi.c b/sys/dev/wi/if_wi.c
index cc53a0d4104c..bda7b23d1ee0 100644
--- a/sys/dev/wi/if_wi.c
+++ b/sys/dev/wi/if_wi.c
@@ -2153,9 +2153,8 @@ wi_cmd(struct wi_softc *sc, int cmd, int val0, int val1, int val2)
/* wait for the busy bit to clear */
for (i = 500; i > 0; i--) { /* 5s */
- if (!(CSR_READ_2(sc, WI_COMMAND) & WI_CMD_BUSY)) {
+ if (!(CSR_READ_2(sc, WI_COMMAND) & WI_CMD_BUSY))
break;
- }
DELAY(10*1000); /* 10 m sec */
}
if (i == 0) {
@@ -2171,7 +2170,7 @@ wi_cmd(struct wi_softc *sc, int cmd, int val0, int val1, int val2)
if (cmd == WI_CMD_INI) {
/* XXX: should sleep here. */
- DELAY(100*1000);
+ DELAY(100*1000); /* 100ms delay for init */
}
for (i = 0; i < WI_TIMEOUT; i++) {
/*
@@ -2183,10 +2182,6 @@ wi_cmd(struct wi_softc *sc, int cmd, int val0, int val1, int val2)
/* Ack the event and read result code. */
s = CSR_READ_2(sc, WI_STATUS);
CSR_WRITE_2(sc, WI_EVENT_ACK, WI_EV_CMD);
-#ifdef foo
- if ((s & WI_CMD_CODE_MASK) != (cmd & WI_CMD_CODE_MASK))
- return(EIO);
-#endif
if (s & WI_STAT_CMD_RESULT) {
count--;
return(EIO);