summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpascoe <pascoe@openbsd.org>2007-04-07 13:23:30 +0000
committerpascoe <pascoe@openbsd.org>2007-04-07 13:23:30 +0000
commit96d32dc367543c89f18586b9ebe6bdabbeed4724 (patch)
tree517f5535faee294a06a192be3610b03866376a37
parentHelper macros to provide the port name in debug messages. (diff)
downloadwireguard-openbsd-96d32dc367543c89f18586b9ebe6bdabbeed4724.tar.xz
wireguard-openbsd-96d32dc367543c89f18586b9ebe6bdabbeed4724.zip
Fill out control information for ATAPI commands.
-rw-r--r--sys/dev/ic/sili.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/dev/ic/sili.c b/sys/dev/ic/sili.c
index 5bc28a355b3..13fb1823ead 100644
--- a/sys/dev/ic/sili.c
+++ b/sys/dev/ic/sili.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sili.c,v 1.19 2007/04/07 13:15:03 pascoe Exp $ */
+/* $OpenBSD: sili.c,v 1.20 2007/04/07 13:23:30 pascoe Exp $ */
/*
* Copyright (c) 2007 David Gwynne <dlg@openbsd.org>
@@ -575,6 +575,11 @@ sili_ata_cmd(struct ata_xfer *xa)
if (xa->flags & ATA_F_PACKET) {
atapi = ccb->ccb_cmd;
+ if (xa->flags & ATA_F_WRITE)
+ atapi->control = htole16(SILI_PRB_PACKET_WRITE);
+ else
+ atapi->control = htole16(SILI_PRB_PACKET_READ);
+
sgl = atapi->sgl;
sgllen = sizeofa(atapi->sgl);