summaryrefslogtreecommitdiffstats
path: root/sys/dev/isp/isp_freebsd.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/isp/isp_freebsd.h')
-rw-r--r--sys/dev/isp/isp_freebsd.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/sys/dev/isp/isp_freebsd.h b/sys/dev/isp/isp_freebsd.h
index fbf9def..1aa6b83 100644
--- a/sys/dev/isp/isp_freebsd.h
+++ b/sys/dev/isp/isp_freebsd.h
@@ -71,7 +71,7 @@
#define HANDLE_LOOPSTATE_IN_OUTER_LAYERS 1
-typedef void ispfwfunc __P((int, int, int, const u_int16_t **));
+typedef void ispfwfunc __P((int, int, int, u_int16_t **));
#ifdef ISP_TARGET_MODE
#define ISP_TARGET_FUNCTIONS 1
@@ -192,6 +192,9 @@ struct isposinfo {
isp->isp_mboxbsy = 0
#define MBOX_RELEASE(isp)
+#define FC_SCRATCH_ACQUIRE(isp)
+#define FC_SCRATCH_RELEASE(isp)
+
#ifndef SCSI_GOOD
#define SCSI_GOOD SCSI_STATUS_OK
#endif
@@ -363,9 +366,10 @@ static INLINE void
isp_mbox_wait_complete(struct ispsoftc *isp)
{
if (isp->isp_osinfo.intsok) {
+ int lim = ((isp->isp_mbxwrk0)? 120 : 20) * hz;
isp->isp_osinfo.mboxwaiting = 1;
(void) msleep(&isp->isp_osinfo.mboxwaiting,
- &isp->isp_lock, PRIBIO, "isp_mboxwaiting", 10 * hz);
+ &isp->isp_lock, PRIBIO, "isp_mboxwaiting", lim);
if (isp->isp_mboxbsy != 0) {
isp_prt(isp, ISP_LOGWARN,
"Interrupting Mailbox Command (0x%x) Timeout",
@@ -374,8 +378,9 @@ isp_mbox_wait_complete(struct ispsoftc *isp)
}
isp->isp_osinfo.mboxwaiting = 0;
} else {
+ int lim = ((isp->isp_mbxwrk0)? 240 : 60) * 10000;
int j;
- for (j = 0; j < 60 * 10000; j++) {
+ for (j = 0; j < lim; j++) {
u_int16_t isr, sema, mbox;
if (isp->isp_mboxbsy == 0) {
break;
OpenPOWER on IntegriCloud