aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/ata/libata-acpi.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/ata/libata-acpi.c b/drivers/ata/libata-acpi.c
index abea74b42a20..9330b7922f62 100644
--- a/drivers/ata/libata-acpi.c
+++ b/drivers/ata/libata-acpi.c
@@ -197,6 +197,10 @@ static void ata_acpi_handle_hotplug(struct ata_port *ap, struct ata_device *dev,
197 /* This device does not support hotplug */ 197 /* This device does not support hotplug */
198 return; 198 return;
199 199
200 if (event == ACPI_NOTIFY_BUS_CHECK ||
201 event == ACPI_NOTIFY_DEVICE_CHECK)
202 status = acpi_evaluate_integer(handle, "_STA", NULL, &sta);
203
200 spin_lock_irqsave(ap->lock, flags); 204 spin_lock_irqsave(ap->lock, flags);
201 205
202 switch (event) { 206 switch (event) {
@@ -204,7 +208,6 @@ static void ata_acpi_handle_hotplug(struct ata_port *ap, struct ata_device *dev,
204 case ACPI_NOTIFY_DEVICE_CHECK: 208 case ACPI_NOTIFY_DEVICE_CHECK:
205 ata_ehi_push_desc(ehi, "ACPI event"); 209 ata_ehi_push_desc(ehi, "ACPI event");
206 210
207 status = acpi_evaluate_integer(handle, "_STA", NULL, &sta);
208 if (ACPI_FAILURE(status)) { 211 if (ACPI_FAILURE(status)) {
209 ata_port_printk(ap, KERN_ERR, 212 ata_port_printk(ap, KERN_ERR,
210 "acpi: failed to determine bay status (0x%x)\n", 213 "acpi: failed to determine bay status (0x%x)\n",