summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpascoe <pascoe@openbsd.org>2007-04-07 13:05:18 +0000
committerpascoe <pascoe@openbsd.org>2007-04-07 13:05:18 +0000
commitbdd604f338ca151fdff865d8331317a66202207b (patch)
tree05dfdc83aceb32a734feda46433aa33038c53be7
parentAdd some more device status related register definitions. (diff)
downloadwireguard-openbsd-bdd604f338ca151fdff865d8331317a66202207b.tar.xz
wireguard-openbsd-bdd604f338ca151fdff865d8331317a66202207b.zip
Use the rx_count saved in the LRAM command slot entry to determine the
xfer residual.
-rw-r--r--sys/dev/ic/sili.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/ic/sili.c b/sys/dev/ic/sili.c
index 86b04ff79b9..750eb21c71c 100644
--- a/sys/dev/ic/sili.c
+++ b/sys/dev/ic/sili.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sili.c,v 1.17 2007/04/07 10:07:12 pascoe Exp $ */
+/* $OpenBSD: sili.c,v 1.18 2007/04/07 13:05:18 pascoe Exp $ */
/*
* Copyright (c) 2007 David Gwynne <dlg@openbsd.org>
@@ -687,7 +687,7 @@ sili_unload(struct sili_ccb *ccb)
BUS_DMASYNC_POSTWRITE);
bus_dmamap_unload(sc->sc_dmat, dmap);
- xa->resid = 0;
+ xa->resid = xa->datalen - sili_pread(sp, SILI_PREG_RX_COUNT(xa->tag));
}
struct ata_xfer *