aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sata_sil24.c
diff options
context:
space:
mode:
authorAlbert Lee <albertcc@tw.ibm.com>2005-12-05 02:38:02 -0500
committerJeff Garzik <jgarzik@pobox.com>2005-12-06 04:49:22 -0500
commita22e2eb0710798009b8e696ae911aef745089dd6 (patch)
tree93421443499249db0301868e07f24156c456cf7a /drivers/scsi/sata_sil24.c
parentc14b8331ec4843e4f2b67a4d847a0d812a50e43c (diff)
[PATCH] libata: move err_mask to ata_queued_cmd
- remove err_mask from the parameter list of the complete functions - move err_mask to ata_queued_cmd - initialize qc->err_mask when needed - for each function call to ata_qc_complete(), replace the err_mask parameter with qc->err_mask. Signed-off-by: Albert Lee <albertcc@tw.ibm.com> =============== Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'drivers/scsi/sata_sil24.c')
-rw-r--r--drivers/scsi/sata_sil24.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/scsi/sata_sil24.c b/drivers/scsi/sata_sil24.c
index e0d6f194f54f..a0ad3ed2200a 100644
--- a/drivers/scsi/sata_sil24.c
+++ b/drivers/scsi/sata_sil24.c
@@ -654,7 +654,8 @@ static void sil24_eng_timeout(struct ata_port *ap)
654 */ 654 */
655 printk(KERN_ERR "ata%u: command timeout\n", ap->id); 655 printk(KERN_ERR "ata%u: command timeout\n", ap->id);
656 qc->scsidone = scsi_finish_command; 656 qc->scsidone = scsi_finish_command;
657 ata_qc_complete(qc, AC_ERR_OTHER); 657 qc->err_mask |= AC_ERR_OTHER;
658 ata_qc_complete(qc);
658 659
659 sil24_reset_controller(ap); 660 sil24_reset_controller(ap);
660} 661}
@@ -711,8 +712,10 @@ static void sil24_error_intr(struct ata_port *ap, u32 slot_stat)
711 sil24_reset_controller(ap); 712 sil24_reset_controller(ap);
712 } 713 }
713 714
714 if (qc) 715 if (qc) {
715 ata_qc_complete(qc, err_mask); 716 qc->err_mask |= err_mask;
717 ata_qc_complete(qc);
718 }
716} 719}
717 720
718static inline void sil24_host_intr(struct ata_port *ap) 721static inline void sil24_host_intr(struct ata_port *ap)
@@ -734,8 +737,10 @@ static inline void sil24_host_intr(struct ata_port *ap)
734 */ 737 */
735 sil24_update_tf(ap); 738 sil24_update_tf(ap);
736 739
737 if (qc) 740 if (qc) {
738 ata_qc_complete(qc, ac_err_mask(pp->tf.command)); 741 qc->err_mask |= ac_err_mask(pp->tf.command);
742 ata_qc_complete(qc);
743 }
739 } else 744 } else
740 sil24_error_intr(ap, slot_stat); 745 sil24_error_intr(ap, slot_stat);
741} 746}