|
@@ -4737,7 +4737,7 @@ struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev, int tag)
|
|
|
return NULL;
|
|
|
|
|
|
/* libsas case */
|
|
|
- if (!ap->scsi_host) {
|
|
|
+ if (ap->flags & ATA_FLAG_SAS_HOST) {
|
|
|
tag = ata_sas_allocate_tag(ap);
|
|
|
if (tag < 0)
|
|
|
return NULL;
|
|
@@ -4776,7 +4776,7 @@ void ata_qc_free(struct ata_queued_cmd *qc)
|
|
|
tag = qc->tag;
|
|
|
if (likely(ata_tag_valid(tag))) {
|
|
|
qc->tag = ATA_TAG_POISON;
|
|
|
- if (!ap->scsi_host)
|
|
|
+ if (ap->flags & ATA_FLAG_SAS_HOST)
|
|
|
ata_sas_free_tag(tag, ap);
|
|
|
}
|
|
|
}
|