From b7423f516e7a48df5525ee444fc8252b9b1f77df Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Fri, 24 Mar 2006 15:25:30 +0900 Subject: [PATCH] --- yaml --- r: 23485 b: refs/heads/master c: 1f7dd3e9d62b25c7b79f913f37c2242a61295de4 h: refs/heads/master i: 23483: 1a268c3462fd83fb1110ef99d77cd6ba68e1fbcd v: v3 --- [refs] | 2 +- trunk/drivers/scsi/libata-core.c | 16 ++++++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 1919ea8d885a..26279448b08e 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 5a529139554f12cb265715117a2153c936286294 +refs/heads/master: 1f7dd3e9d62b25c7b79f913f37c2242a61295de4 diff --git a/trunk/drivers/scsi/libata-core.c b/trunk/drivers/scsi/libata-core.c index 1063928e3824..9cd9053e78fe 100644 --- a/trunk/drivers/scsi/libata-core.c +++ b/trunk/drivers/scsi/libata-core.c @@ -1009,6 +1009,22 @@ ata_exec_internal(struct ata_port *ap, struct ata_device *dev, ata_qc_free(qc); + /* XXX - Some LLDDs (sata_mv) disable port on command failure. + * Until those drivers are fixed, we detect the condition + * here, fail the command with AC_ERR_SYSTEM and reenable the + * port. + * + * Note that this doesn't change any behavior as internal + * command failure results in disabling the device in the + * higher layer for LLDDs without new reset/EH callbacks. + * + * Kill the following code as soon as those drivers are fixed. + */ + if (ap->flags & ATA_FLAG_PORT_DISABLED) { + err_mask |= AC_ERR_SYSTEM; + ata_port_probe(ap); + } + return err_mask; }