diff options
Diffstat (limited to 'drivers/ata/libata-core.c')
-rw-r--r-- | drivers/ata/libata-core.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index 915a55a6cc14..0bb4b4dced76 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c | |||
@@ -937,12 +937,9 @@ void ata_port_queue_task(struct ata_port *ap, void (*fn)(void *), void *data, | |||
937 | if (ap->pflags & ATA_PFLAG_FLUSH_PORT_TASK) | 937 | if (ap->pflags & ATA_PFLAG_FLUSH_PORT_TASK) |
938 | return; | 938 | return; |
939 | 939 | ||
940 | PREPARE_WORK(&ap->port_task, fn, data); | 940 | PREPARE_DELAYED_WORK(&ap->port_task, fn, data); |
941 | 941 | ||
942 | if (!delay) | 942 | rc = queue_delayed_work(ata_wq, &ap->port_task, delay); |
943 | rc = queue_work(ata_wq, &ap->port_task); | ||
944 | else | ||
945 | rc = queue_delayed_work(ata_wq, &ap->port_task, delay); | ||
946 | 943 | ||
947 | /* rc == 0 means that another user is using port task */ | 944 | /* rc == 0 means that another user is using port task */ |
948 | WARN_ON(rc == 0); | 945 | WARN_ON(rc == 0); |
@@ -5320,8 +5317,8 @@ void ata_port_init(struct ata_port *ap, struct ata_host *host, | |||
5320 | ap->msg_enable = ATA_MSG_DRV | ATA_MSG_ERR | ATA_MSG_WARN; | 5317 | ap->msg_enable = ATA_MSG_DRV | ATA_MSG_ERR | ATA_MSG_WARN; |
5321 | #endif | 5318 | #endif |
5322 | 5319 | ||
5323 | INIT_WORK(&ap->port_task, NULL, NULL); | 5320 | INIT_DELAYED_WORK(&ap->port_task, NULL, NULL); |
5324 | INIT_WORK(&ap->hotplug_task, ata_scsi_hotplug, ap); | 5321 | INIT_DELAYED_WORK(&ap->hotplug_task, ata_scsi_hotplug, ap); |
5325 | INIT_WORK(&ap->scsi_rescan_task, ata_scsi_dev_rescan, ap); | 5322 | INIT_WORK(&ap->scsi_rescan_task, ata_scsi_dev_rescan, ap); |
5326 | INIT_LIST_HEAD(&ap->eh_done_q); | 5323 | INIT_LIST_HEAD(&ap->eh_done_q); |
5327 | init_waitqueue_head(&ap->eh_wait_q); | 5324 | init_waitqueue_head(&ap->eh_wait_q); |