From 82681884cf8a124890742949facf5a92898ae029 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B8ren=20Schmidt?= Date: Fri, 10 Oct 2003 11:03:27 +0000 Subject: [PATCH] Restore transfermode on devices after reinit. --- sys/dev/ata/ata-all.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/dev/ata/ata-all.c b/sys/dev/ata/ata-all.c index f58e49e3515..d3a45e94657 100644 --- a/sys/dev/ata/ata-all.c +++ b/sys/dev/ata/ata-all.c @@ -276,6 +276,13 @@ ata_reinit(struct ata_channel *ch) ch->device[SLAVE].attach) ch->device[SLAVE].attach(&ch->device[SLAVE]); } + + /* restore transfermode on devices */ + if (ch->devices & (ATA_ATA_MASTER | ATA_ATAPI_MASTER)) + ch->device[MASTER].setmode(&ch->device[MASTER],ch->device[MASTER].mode); + if (ch->devices & (ATA_ATA_SLAVE | ATA_ATAPI_SLAVE)) + ch->device[SLAVE].setmode(&ch->device[SLAVE], ch->device[SLAVE].mode); + #ifdef DEV_ATAPICAM atapi_cam_reinit_bus(ch); #endif