Commit 4cb629dd authored by Jeff Garzik's avatar Jeff Garzik

[libata sata_promise] provide proper SCSI completion function

Promise driver uses a custom error handling function, so we need
the fix that was applied to the libata core:  the SCSI error
handling thread requires that we complete commands using a special
completion function, since the normal one doesn't work inside
the error handling thread.
parent 2dd84413
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
#include <asm/io.h> #include <asm/io.h>
#define DRV_NAME "sata_promise" #define DRV_NAME "sata_promise"
#define DRV_VERSION "0.90" #define DRV_VERSION "0.91"
enum { enum {
...@@ -1014,6 +1014,14 @@ static void pdc_eng_timeout(struct ata_port *ap) ...@@ -1014,6 +1014,14 @@ static void pdc_eng_timeout(struct ata_port *ap)
goto out; goto out;
} }
/* hack alert! We cannot use the supplied completion
* function from inside the ->eh_strategy_handler() thread.
* libata is the only user of ->eh_strategy_handler() in
* any kernel, so the default scsi_done() assumes it is
* not being called from the SCSI EH.
*/
qc->scsidone = scsi_finish_command;
switch (qc->tf.protocol) { switch (qc->tf.protocol) {
case ATA_PROT_DMA_READ: case ATA_PROT_DMA_READ:
case ATA_PROT_DMA_WRITE: case ATA_PROT_DMA_WRITE:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment