diff options
author | mav <mav@FreeBSD.org> | 2009-02-28 22:07:15 +0000 |
---|---|---|
committer | mav <mav@FreeBSD.org> | 2009-02-28 22:07:15 +0000 |
commit | 55cab290fcfb54ff2225bc84652ff631feca520a (patch) | |
tree | ec95ab40b5ed482c5e53ec83ecf3ff4a51f7e75c /sys/dev/ata/ata-disk.c | |
parent | 4eafa084fe4aba2a485ea0c0d8e047b253977e9d (diff) | |
download | FreeBSD-src-55cab290fcfb54ff2225bc84652ff631feca520a.zip FreeBSD-src-55cab290fcfb54ff2225bc84652ff631feca520a.tar.gz |
Revert my ata_identify()/ata_reinit() related changes: r189166, r189091
and partially r188903. Revert breaks new drives detection on reinit to the
state as it was before me, but fixes series of new bugs reported by some
people.
Unconditional queueing of ata_completed() calls can lead to deadlock if
due to timeout ata_reinit() was called at the same thread by previous
ata_completed(). Calling of ata_identify() on ata_reinit() in current
implementation opens numerous races and deadlocks.
Problems I was touching here are still exist and should be addresed, but
probably in different way.
Diffstat (limited to 'sys/dev/ata/ata-disk.c')
-rw-r--r-- | sys/dev/ata/ata-disk.c | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/sys/dev/ata/ata-disk.c b/sys/dev/ata/ata-disk.c index a1280ac..e11f3f9 100644 --- a/sys/dev/ata/ata-disk.c +++ b/sys/dev/ata/ata-disk.c @@ -79,18 +79,6 @@ ad_probe(device_t dev) { struct ata_device *atadev = device_get_softc(dev); - if (atadev->type != ATA_T_ATA) - return (ENXIO); - - if (!(atadev->flags & ATA_D_PROBED)) { - atadev->flags |= ATA_D_PROBED; - if (ata_getparam(atadev, 1) == 0) - atadev->flags |= ATA_D_VALID; - } - - if (!(atadev->flags & ATA_D_VALID)) - return (ENXIO); - if (!(atadev->param.config & ATA_PROTO_ATAPI) || (atadev->param.config == ATA_CFA_MAGIC1) || (atadev->param.config == ATA_CFA_MAGIC2) || |