aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/libata-core.c
diff options
context:
space:
mode:
authorAlbert Lee <albertcc@tw.ibm.com>2006-03-25 04:56:55 -0500
committerJeff Garzik <jeff@garzik.org>2006-03-29 17:21:54 -0500
commitc2bbc551615c21a4c280c797987dbb50f2701594 (patch)
tree8f23c49dceec2123663377c4750ea48fb46d8fea /drivers/scsi/libata-core.c
parent27cdadef6dfe0d0614653919a110fc75ab1650ce (diff)
[PATCH] libata-dev: ata_check_atapi_dma() fix for ATA_FLAG_PIO_POLLING LLDDs
ata_check_atapi_dma() fix for LLDDs with the ATA_FLAG_PIO_POLLING flag. Signed-off-by: Albert Lee <albertcc@tw.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/scsi/libata-core.c')
-rw-r--r--drivers/scsi/libata-core.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/scsi/libata-core.c b/drivers/scsi/libata-core.c
index ef0d0dd90e17..61c120dae74d 100644
--- a/drivers/scsi/libata-core.c
+++ b/drivers/scsi/libata-core.c
@@ -2883,6 +2883,15 @@ int ata_check_atapi_dma(struct ata_queued_cmd *qc)
2883 if (ap->ops->check_atapi_dma) 2883 if (ap->ops->check_atapi_dma)
2884 rc = ap->ops->check_atapi_dma(qc); 2884 rc = ap->ops->check_atapi_dma(qc);
2885 2885
2886 /* We don't support polling DMA.
2887 * Use PIO if the LLDD handles only interrupts in
2888 * the HSM_ST_LAST state and the ATAPI device
2889 * generates CDB interrupts.
2890 */
2891 if ((ap->flags & ATA_FLAG_PIO_POLLING) &&
2892 (qc->dev->flags & ATA_DFLAG_CDB_INTR))
2893 rc = 1;
2894
2886 return rc; 2895 return rc;
2887} 2896}
2888/** 2897/**
@@ -4038,6 +4047,7 @@ unsigned int ata_qc_issue_prot(struct ata_queued_cmd *qc)
4038 break; 4047 break;
4039 case ATA_PROT_ATAPI_DMA: 4048 case ATA_PROT_ATAPI_DMA:
4040 if (qc->dev->flags & ATA_DFLAG_CDB_INTR) 4049 if (qc->dev->flags & ATA_DFLAG_CDB_INTR)
4050 /* see ata_check_atapi_dma() */
4041 BUG(); 4051 BUG();
4042 break; 4052 break;
4043 default: 4053 default: