Skip to content

Commit

Permalink
pata_it821x: use raw nbytes in check_atapi_dma
Browse files Browse the repository at this point in the history
pata_it821x needs to look at raw request size in check_atapi_dma().

Signed-off-by: Tejun Heo <htejun@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Tejun Heo authored and Jeff Garzik committed Mar 25, 2008
1 parent aacda37 commit b63b133
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/ata/pata_it821x.c
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ static int it821x_check_atapi_dma(struct ata_queued_cmd *qc)
struct it821x_dev *itdev = ap->private_data;

/* Only use dma for transfers to/from the media. */
if (qc->nbytes < 2048)
if (ata_qc_raw_nbytes(qc) < 2048)
return -EOPNOTSUPP;

/* No ATAPI DMA in smart mode */
Expand Down

0 comments on commit b63b133

Please sign in to comment.