aboutsummaryrefslogtreecommitdiff
path: root/drivers/ata
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2008-04-02 17:35:19 +0900
committerJeff Garzik <jeff@garzik.org>2008-04-04 02:43:36 -0400
commite52dcc4899cf1b7601379c31542bd91cd2997a64 (patch)
tree40bce50f8f912bbd2d988526f3f5c5763f67af62 /drivers/ata
parent436d34b36202ef724778ded1e9cb10f8c37b32bc (diff)
libata: ATA_12/16 doesn't fall into ATAPI_MISC
SAT passthrus don't really fit into ATAPI_MISC class. SAT passthru commands always transfer multiple of 512 bytes and variable length response is not allowed. This patch creates a separate category - ATAPI_PASS_THRU - for these. This fixes HSM violation on "hdparm -I". Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/ata')
-rw-r--r--drivers/ata/libata-core.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index e9b69ba489d..be95fdb6972 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -353,6 +353,11 @@ int atapi_cmd_type(u8 opcode)
case GPCMD_READ_CD_MSF:
return ATAPI_READ_CD;
+ case ATA_16:
+ case ATA_12:
+ if (atapi_passthru16)
+ return ATAPI_PASS_THRU;
+ /* fall thru */
default:
return ATAPI_MISC;
}