diff options
-rw-r--r-- | drivers/scsi/libata-core.c | 14 | ||||
-rw-r--r-- | include/linux/libata.h | 2 |
2 files changed, 2 insertions, 14 deletions
diff --git a/drivers/scsi/libata-core.c b/drivers/scsi/libata-core.c index 1c4dbf3e9818..9ea102587914 100644 --- a/drivers/scsi/libata-core.c +++ b/drivers/scsi/libata-core.c | |||
@@ -3503,7 +3503,7 @@ struct ata_queued_cmd *ata_qc_new_init(struct ata_port *ap, | |||
3503 | static void __ata_qc_complete(struct ata_queued_cmd *qc) | 3503 | static void __ata_qc_complete(struct ata_queued_cmd *qc) |
3504 | { | 3504 | { |
3505 | struct ata_port *ap = qc->ap; | 3505 | struct ata_port *ap = qc->ap; |
3506 | unsigned int tag, do_clear = 0; | 3506 | unsigned int tag; |
3507 | 3507 | ||
3508 | qc->flags = 0; | 3508 | qc->flags = 0; |
3509 | tag = qc->tag; | 3509 | tag = qc->tag; |
@@ -3511,17 +3511,8 @@ static void __ata_qc_complete(struct ata_queued_cmd *qc) | |||
3511 | if (tag == ap->active_tag) | 3511 | if (tag == ap->active_tag) |
3512 | ap->active_tag = ATA_TAG_POISON; | 3512 | ap->active_tag = ATA_TAG_POISON; |
3513 | qc->tag = ATA_TAG_POISON; | 3513 | qc->tag = ATA_TAG_POISON; |
3514 | do_clear = 1; | ||
3515 | } | ||
3516 | |||
3517 | if (qc->waiting) { | ||
3518 | struct completion *waiting = qc->waiting; | ||
3519 | qc->waiting = NULL; | ||
3520 | complete(waiting); | ||
3521 | } | ||
3522 | |||
3523 | if (likely(do_clear)) | ||
3524 | clear_bit(tag, &ap->qactive); | 3514 | clear_bit(tag, &ap->qactive); |
3515 | } | ||
3525 | } | 3516 | } |
3526 | 3517 | ||
3527 | /** | 3518 | /** |
@@ -3537,7 +3528,6 @@ static void __ata_qc_complete(struct ata_queued_cmd *qc) | |||
3537 | void ata_qc_free(struct ata_queued_cmd *qc) | 3528 | void ata_qc_free(struct ata_queued_cmd *qc) |
3538 | { | 3529 | { |
3539 | assert(qc != NULL); /* ata_qc_from_tag _might_ return NULL */ | 3530 | assert(qc != NULL); /* ata_qc_from_tag _might_ return NULL */ |
3540 | assert(qc->waiting == NULL); /* nothing should be waiting */ | ||
3541 | 3531 | ||
3542 | __ata_qc_complete(qc); | 3532 | __ata_qc_complete(qc); |
3543 | } | 3533 | } |
diff --git a/include/linux/libata.h b/include/linux/libata.h index 833e57afd54c..46337e71613e 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
@@ -285,8 +285,6 @@ struct ata_queued_cmd { | |||
285 | 285 | ||
286 | ata_qc_cb_t complete_fn; | 286 | ata_qc_cb_t complete_fn; |
287 | 287 | ||
288 | struct completion *waiting; | ||
289 | |||
290 | void *private_data; | 288 | void *private_data; |
291 | }; | 289 | }; |
292 | 290 | ||