this is from eriks contrib:
static void
westerndigitalhung(Drive *d)
{
if((d->portm.feat&Datapi) == 0 && d->active &&
TK2MS(Ticks-d->intick) > 5000){
dprint("%s: drive hung; resetting [%lux] ci=%lux\n",
d->unit->name, d->port->task, d->port->ci);
d->state = Dreset;
}
}
and this is the version on sources:
static void
westerndigitalhung(Drive *d)
{
if((d->portm.feat&Datapi) == 0 && d->active && TK2MS(d->intick) > 5000){
dprint("%s: drive hung; resetting [%lux] ci %lx\n",
d->unit->name, d->port->task, d->port->ci);
d->state = Dreset;
}
}
if i understand it right, d->intick is just the point in time it started some
io request. it does:
p->intick = MACHP(0)->ticks;
p->active++;
so it seems the version on sources is wrong, and eriks version does the right
thing.
(calculating the time the operation takes (current time - time of request
start))
can somebody confirm this?
--
cinap