FreeBSD/sys/dev/mvs/mvs.c
/* Must be called with channel locked. */
Must be called with channel locked.
Must be called with channel locked .
static void
mvs_rearm_timeout(device_t dev)
{
	struct mvs_channel *ch = device_get_softc(dev);
	int i;
	mtx_assert(&ch->mtx, MA_OWNED);
	for (i = 0; i < MVS_MAX_SLOTS; i++) {
		struct mvs_slot *slot = &ch->slot[i];
		if (slot->state < MVS_SLOT_RUNNING)
			continue;
		if ((ch->toslots & (1 << i)) == 0)
			continue;
		callout_reset_sbt(&slot->timeout,
		    SBT_1MS * slot->ccb->ccb_h.timeout / 2, 0,
		    (timeout_t*)mvs_timeout, slot, 0);
	}
}
static void mvs_rearm_timeout ( device_t dev ) { struct mvs_channel * ch = device_get_softc ( dev ) ; int i ; mtx_assert ( & ch -> mtx , MA_OWNED ) ; for ( i = 0 ; i < MVS_MAX_SLOTS ; i ++ ) { struct mvs_slot * slot = & ch -> slot [ i ] ; if ( slot -> state < MVS_SLOT_RUNNING ) continue ; if ( ( ch -> toslots & ( 1 << i ) ) == 0 ) continue ; callout_reset_sbt ( & slot -> timeout , SBT_1MS * slot -> ccb -> ccb_h . timeout / 2 , 0 , ( timeout_t * ) mvs_timeout , slot , 0 ) ; } }
Must be called with channel locked.
Must be called with channel locked .
/* Do we have a running request on slot? */