提交 687a9933 编写于 作者: T Tejun Heo 提交者: Jeff Garzik

libata-sff: fix HSM_ST_ERR handling in __ata_sff_port_intr()

While separating out BMDMA irq handler from SFF, commit c3b28894
(libata-sff: separate out BMDMA irq handler) incorrectly made
__ata_sff_port_intr() consider an IRQ to be an idle one if the host
state was transitioned to HSM_ST_ERR by ata_bmdma_port_intr().

This makes BMDMA drivers ignore IRQs reporting host bus error which
leads to timeouts instead of triggering EH immediately.  Fix it by
making __ata_sff_port_intr() consider the IRQ to be an idle one iff
the state is HSM_ST_IDLE.  This is equivalent to adding HSM_ST_ERR to
the "break"ing case but less error-prone.
Signed-off-by: NTejun Heo <tj@kernel.org>
Reported-by: NAntonio Toma <antonio.toma@gmail.com>
Cc: stable@kernel.org
Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
上级 90a8a73c
...@@ -1532,11 +1532,10 @@ static unsigned int __ata_sff_port_intr(struct ata_port *ap, ...@@ -1532,11 +1532,10 @@ static unsigned int __ata_sff_port_intr(struct ata_port *ap,
if (!(qc->dev->flags & ATA_DFLAG_CDB_INTR)) if (!(qc->dev->flags & ATA_DFLAG_CDB_INTR))
return ata_sff_idle_irq(ap); return ata_sff_idle_irq(ap);
break; break;
case HSM_ST: case HSM_ST_IDLE:
case HSM_ST_LAST:
break;
default:
return ata_sff_idle_irq(ap); return ata_sff_idle_irq(ap);
default:
break;
} }
/* check main status, clearing INTRQ if needed */ /* check main status, clearing INTRQ if needed */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册