Johannes Lochmann wrote: > On Monday 18 October 2004 23:00, Simon L. Nielsen wrote: > >>I'm not sure if I dare to tell you... :-) but my Thinkpad R40 also >>hangs now with RELENG_5 from today. It's OK with 5.3-BETA7 from Oct >>10. >> >>The patch below did not fix it. I haven't tried backstepping ata(4) >>yet, but I will do that shortly. > > > same here for an IBM Thinkpad T40P (with and without patch). > OK, try this patch for releng_5 and let me know... -- -Søren Index: ata-queue.c =================================================================== RCS file: /home/ncvs/src/sys/dev/ata/ata-queue.c,v retrieving revision 1.32.2.4 diff -u -r1.32.2.4 ata-queue.c --- ata-queue.c 16 Oct 2004 08:43:06 -0000 1.32.2.4 +++ ata-queue.c 19 Oct 2004 20:50:23 -0000 _at__at_ -182,15 +182,13 _at__at_ /* check for the right state */ mtx_lock(&ch->state_mtx); if (ch->state == ATA_IDLE) { + ATA_DEBUG_RQ(request, "starting"); TAILQ_REMOVE(&ch->ata_queue, request, chain); ch->running = request; - - ATA_DEBUG_RQ(request, "starting"); - + ch->state = ATA_ACTIVE; if (!dumping) callout_reset(&request->callout, request->timeout * hz, (timeout_t*)ata_timeout, request); - if (ch->hw.begin_transaction(request) == ATA_OP_FINISHED) { ch->running = NULL; ch->state = ATA_IDLE; _at__at_ -200,8 +198,6 _at__at_ ata_finish(request); return; } - else - ch->state = ATA_ACTIVE; } mtx_unlock(&ch->state_mtx); } _at__at_ -242,14 +238,9 _at__at_ /* if we had a timeout, reinit channel and deal with the falldown */ if (request->flags & ATA_R_TIMEOUT) { - int error = ata_reinit(ch); - /* if our device disappeared return as cleanup was done already */ - if (!request->device->param) - return; - /* if reinit succeeded and retries still permit, reinject request */ - if (!error && request->retries-- > 0) { + if (ata_reinit(ch) && request->retries-- > 0) { request->flags &= ~(ATA_R_TIMEOUT | ATA_R_DEBUG); request->flags |= (ATA_R_IMMEDIATE | ATA_R_REQUEUE); ATA_DEBUG_RQ(request, "completed reinject");Received on Tue Oct 19 2004 - 18:54:18 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:18 UTC