diff options
author | Jeff Garzik <jgarzik@pobox.com> | 2005-11-17 05:44:44 -0500 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2005-11-17 05:44:44 -0500 |
commit | a2c91a8819e315e9fd1aef3ff57badb6c1be3f80 (patch) | |
tree | 0b75460b200383d341b8473fc187f5db2c681795 /drivers/scsi/sata_mv.c | |
parent | 22374677d18c5eeefd3a283431d312b8c44fef02 (diff) |
[libata sata_mv] handle lack of hardware nIEN support
Handle errata (it was unintentional on this h/w, whereas its intentional
on others) whereby the nIEN bit in Device Control is ignored, leading to
a situation where a hardware interrupt completes the qc before the
polling code has a chance to.
This will get fixed The Right Way(tm) once Albert Lee's irq-pio
branch is merged, as the more natural PIO method on this hardware is
interrupt-driven.
Diffstat (limited to 'drivers/scsi/sata_mv.c')
-rw-r--r-- | drivers/scsi/sata_mv.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/scsi/sata_mv.c b/drivers/scsi/sata_mv.c index ee0634da0872..ac184e60797e 100644 --- a/drivers/scsi/sata_mv.c +++ b/drivers/scsi/sata_mv.c | |||
@@ -1219,6 +1219,10 @@ static void mv_host_intr(struct ata_host_set *host_set, u32 relevant, | |||
1219 | handled++; | 1219 | handled++; |
1220 | } | 1220 | } |
1221 | 1221 | ||
1222 | if (ap && | ||
1223 | (ap->flags & (ATA_FLAG_PORT_DISABLED | ATA_FLAG_NOINTR))) | ||
1224 | continue; | ||
1225 | |||
1222 | err_mask = ac_err_mask(ata_status); | 1226 | err_mask = ac_err_mask(ata_status); |
1223 | 1227 | ||
1224 | shift = port << 1; /* (port * 2) */ | 1228 | shift = port << 1; /* (port * 2) */ |
@@ -1237,7 +1241,8 @@ static void mv_host_intr(struct ata_host_set *host_set, u32 relevant, | |||
1237 | VPRINTK("port %u IRQ found for qc, " | 1241 | VPRINTK("port %u IRQ found for qc, " |
1238 | "ata_status 0x%x\n", port,ata_status); | 1242 | "ata_status 0x%x\n", port,ata_status); |
1239 | /* mark qc status appropriately */ | 1243 | /* mark qc status appropriately */ |
1240 | ata_qc_complete(qc, err_mask); | 1244 | if (!(qc->tf.ctl & ATA_NIEN)) |
1245 | ata_qc_complete(qc, err_mask); | ||
1241 | } | 1246 | } |
1242 | } | 1247 | } |
1243 | } | 1248 | } |