diff options
Diffstat (limited to 'drivers/ata/libata-core.c')
-rw-r--r-- | drivers/ata/libata-core.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index 25d8d3f778a1..2cf8251728d2 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c | |||
@@ -1410,7 +1410,16 @@ int ata_dev_read_id(struct ata_device *dev, unsigned int *p_class, | |||
1410 | } | 1410 | } |
1411 | 1411 | ||
1412 | tf.protocol = ATA_PROT_PIO; | 1412 | tf.protocol = ATA_PROT_PIO; |
1413 | tf.flags |= ATA_TFLAG_POLLING; /* for polling presence detection */ | 1413 | |
1414 | /* Some devices choke if TF registers contain garbage. Make | ||
1415 | * sure those are properly initialized. | ||
1416 | */ | ||
1417 | tf.flags |= ATA_TFLAG_ISADDR | ATA_TFLAG_DEVICE; | ||
1418 | |||
1419 | /* Device presence detection is unreliable on some | ||
1420 | * controllers. Always poll IDENTIFY if available. | ||
1421 | */ | ||
1422 | tf.flags |= ATA_TFLAG_POLLING; | ||
1414 | 1423 | ||
1415 | err_mask = ata_exec_internal(dev, &tf, NULL, DMA_FROM_DEVICE, | 1424 | err_mask = ata_exec_internal(dev, &tf, NULL, DMA_FROM_DEVICE, |
1416 | id, sizeof(id[0]) * ATA_ID_WORDS); | 1425 | id, sizeof(id[0]) * ATA_ID_WORDS); |