summaryrefslogtreecommitdiffstats
path: root/sys/dev/ata
diff options
context:
space:
mode:
authorsos <sos@FreeBSD.org>2003-10-10 11:03:27 +0000
committersos <sos@FreeBSD.org>2003-10-10 11:03:27 +0000
commit2688d9803175fc4f3eb991136014b429d1d04737 (patch)
treebc536489f27777fd8412f6a7104c524a301afbd2 /sys/dev/ata
parentdff7842fedb3ab8a5a13b7cff94c4b0b9e6fdb51 (diff)
downloadFreeBSD-src-2688d9803175fc4f3eb991136014b429d1d04737.zip
FreeBSD-src-2688d9803175fc4f3eb991136014b429d1d04737.tar.gz
Restore transfermode on devices after reinit.
Diffstat (limited to 'sys/dev/ata')
-rw-r--r--sys/dev/ata/ata-all.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/dev/ata/ata-all.c b/sys/dev/ata/ata-all.c
index f58e49e..d3a45e9 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
OpenPOWER on IntegriCloud