diff options
author | Christopher Pascoe <pascoe@cvs.openbsd.org> | 2007-03-20 13:01:05 +0000 |
---|---|---|
committer | Christopher Pascoe <pascoe@cvs.openbsd.org> | 2007-03-20 13:01:05 +0000 |
commit | 6c1380d3df7e7663e1060ffe517e7e53fb40e89f (patch) | |
tree | 9636212628ea2043ee46bf91cdc896a98eacce23 /sys/dev/ata | |
parent | 47efffb371aa3ba598c34cf3cbfd6bf0ec9ffdc3 (diff) |
Tag ATAPI transfers that have no data phase correctly, otherwise the command
isn't sent to the device.
Diffstat (limited to 'sys/dev/ata')
-rw-r--r-- | sys/dev/ata/atascsi.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/dev/ata/atascsi.c b/sys/dev/ata/atascsi.c index 1719ce4dc09..4f692795e3d 100644 --- a/sys/dev/ata/atascsi.c +++ b/sys/dev/ata/atascsi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: atascsi.c,v 1.26 2007/03/20 12:44:04 pascoe Exp $ */ +/* $OpenBSD: atascsi.c,v 1.27 2007/03/20 13:01:04 pascoe Exp $ */ /* * Copyright (c) 2007 David Gwynne <dlg@openbsd.org> @@ -555,13 +555,14 @@ atascsi_atapi_cmd(struct scsi_xfer *xs) switch (xs->flags & (SCSI_DATA_IN | SCSI_DATA_OUT)) { case SCSI_DATA_IN: - xa->flags = ATA_F_READ | ATA_F_PACKET; + xa->flags = ATA_F_READ; break; case SCSI_DATA_OUT: - xa->flags = ATA_F_WRITE | ATA_F_PACKET; + xa->flags = ATA_F_WRITE; break; } + xa->flags |= ATA_F_PACKET; xa->data = xs->data; xa->datalen = xs->datalen; xa->complete = atascsi_atapi_cmd_done; |