Print this page
XXXX introduce drv_sectohz
@@ -513,11 +513,11 @@
/* initialize isns client */
mutex_init(&isns_monitor_mutex, NULL, MUTEX_DEFAULT, NULL);
mutex_init(&esi.esi_mutex, NULL, MUTEX_DEFAULT, NULL);
isns_monitor_thr_id = NULL;
- monitor_idle_interval = ISNS_IDLE_TIME * drv_usectohz(1000000);
+ monitor_idle_interval = drv_sectohz(ISNS_IDLE_TIME);
cv_init(&isns_idle_cv, NULL, CV_DEFAULT, NULL);
cv_init(&esi.esi_cv, NULL, CV_DEFAULT, NULL);
xid = 0;
ISNS_GLOBAL_UNLOCK();
@@ -1076,11 +1076,11 @@
* to be registered before we send register-all. This is
* purely an optimization to cut down on the number of
* messages we send to the iSNS server.
*/
mutex_exit(&isns_monitor_mutex);
- delay(drv_usectohz(isns_initial_delay * 1000000));
+ delay(drv_sectohz(isns_initial_delay));
mutex_enter(&isns_monitor_mutex);
/* Force an initialization of isns_all_portals */
mutex_enter(&iscsit_isns_mutex);
isns_portals_changed = B_TRUE;
@@ -2872,11 +2872,11 @@
payload = kmem_alloc(payload_len, KM_NOSLEEP);
if (payload == NULL) {
goto rcv_error;
}
rcv_timer = timeout(isnst_so_timeout, so,
- drv_usectohz(ISNS_RCV_TIMER_SECONDS * 1000000));
+ drv_sectohz(ISNS_RCV_TIMER_SECONDS));
if (idm_sorecv(so, payload, payload_len) != 0) {
(void) untimeout(rcv_timer);
goto rcv_error;
}
(void) untimeout(rcv_timer);
@@ -3083,11 +3083,11 @@
if ((esi.esi_so = idm_socreate(PF_INET6, SOCK_STREAM, 0)) ==
NULL) {
ISNST_LOG(CE_WARN,
"isnst_esi_thread: Unable to create socket");
mutex_exit(&esi.esi_mutex);
- delay(drv_usectohz(1000000));
+ delay(drv_sectohz(1));
mutex_enter(&esi.esi_mutex);
continue;
}
/*
@@ -3104,11 +3104,11 @@
if (ksocket_bind(esi.esi_so, (struct sockaddr *)&sin6,
sizeof (sin6), CRED()) != 0) {
ISNST_LOG(CE_WARN, "Unable to bind socket for ESI");
idm_sodestroy(esi.esi_so);
mutex_exit(&esi.esi_mutex);
- delay(drv_usectohz(1000000));
+ delay(drv_sectohz(1));
mutex_enter(&esi.esi_mutex);
continue;
}
/*
@@ -3122,11 +3122,11 @@
if ((rc = ksocket_listen(esi.esi_so, 5, CRED())) != 0) {
ISNST_LOG(CE_WARN, "isnst_esi_thread: listen "
"failure 0x%x", rc);
idm_sodestroy(esi.esi_so);
mutex_exit(&esi.esi_mutex);
- delay(drv_usectohz(1000000));
+ delay(drv_sectohz(1));
mutex_enter(&esi.esi_mutex);
continue;
}
ksocket_hold(esi.esi_so);