summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormjacob <mjacob@FreeBSD.org>2000-07-04 01:02:38 +0000
committermjacob <mjacob@FreeBSD.org>2000-07-04 01:02:38 +0000
commit6d0b7294147b18b40ce94ef8a52e35976e27fb95 (patch)
treee8ec86b2ec0c1a114ebddecf7b245c2b2a67cf9c
parent9d667c3b829024c993f25752e3ecfbbb2014508a (diff)
downloadFreeBSD-src-6d0b7294147b18b40ce94ef8a52e35976e27fb95.zip
FreeBSD-src-6d0b7294147b18b40ce94ef8a52e35976e27fb95.tar.gz
Change delay loop in new isp_mboxcmd to the use of the new MBOX_WAIT_COMPLETE
macro. Change notification of completion of a mailbox command in isp_intr to MBOX_NOTIFY_COMPLETE macro.
-rw-r--r--sys/dev/isp/isp.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c
index 7996b0f..554dc8f 100644
--- a/sys/dev/isp/isp.c
+++ b/sys/dev/isp/isp.c
@@ -2482,7 +2482,7 @@ isp_intr(arg)
isp->isp_mboxtmp[i] =
ISP_READ(isp, MBOX_OFF(i));
}
- isp->isp_mboxbsy = 0;
+ MBOX_NOTIFY_COMPLETE(isp);
} else {
PRINTF("%s: Command Mbox 0x%x\n",
isp->isp_name, mbox);
@@ -3605,12 +3605,7 @@ isp_mboxcmd(isp, mbp)
/*
* While we haven't finished the command, spin our wheels here.
*/
-
- do {
- if (isp_intr(isp) == 0) {
- SYS_DELAY(500);
- }
- } while (isp->isp_mboxbsy != 0);
+ MBOX_WAIT_COMPLETE(isp);
/*
* Copy back output registers.
OpenPOWER on IntegriCloud