diff options
author | Tejun Heo | 2007-05-14 20:28:15 +0200 |
---|---|---|
committer | Jeff Garzik | 2007-05-16 07:18:30 +0200 |
commit | 6ddcd3b0201a7ad72294347636d2b4028ddbd95d (patch) | |
tree | ef2d28ea1775693f632705ebe71ad3e451cd69f1 /drivers/ata/pata_optidma.c | |
parent | libata: separate out ata_dev_reread_id() (diff) | |
download | kernel-qcow2-linux-6ddcd3b0201a7ad72294347636d2b4028ddbd95d.tar.gz kernel-qcow2-linux-6ddcd3b0201a7ad72294347636d2b4028ddbd95d.tar.xz kernel-qcow2-linux-6ddcd3b0201a7ad72294347636d2b4028ddbd95d.zip |
libata: during revalidation, check n_sectors after device is configured
Device might be resized during ata_dev_configure() due to HPA or
(later) ACPI _GTF. Currently it's worked around by caching n_sectors
before turning off HPA. The cached original size is overwritten if
the device is reconfigured without being hardreset - which always
happens after configuring trasnfer mode. If the device gets hardreset
for some reason after that, revalidation fails with -ENODEV.
This patch makes size checking more robust by moving n_sectors check
from ata_dev_reread_id() to ata_dev_revalidate() after the device is
fully configured. No matter what happens during configuration, a
device must have the same n_sectors after fully configured to be
treated as the same device.
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/ata/pata_optidma.c')
0 files changed, 0 insertions, 0 deletions