summaryrefslogtreecommitdiffstats
path: root/sys/alpha
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2005-09-15 17:09:42 +0000
committerjhb <jhb@FreeBSD.org>2005-09-15 17:09:42 +0000
commitcde6672474c8f8ad8688f3c6f1d1f35cb3d29539 (patch)
tree8fd7e52c45ba14c4bbe18ca99169c6a164bf0b53 /sys/alpha
parent32a45dd89e052b5b59f8cdde303861e41a0069d8 (diff)
downloadFreeBSD-src-cde6672474c8f8ad8688f3c6f1d1f35cb3d29539.zip
FreeBSD-src-cde6672474c8f8ad8688f3c6f1d1f35cb3d29539.tar.gz
Add a memory barrier for PREWRITE operations to ensure all writes by the
CPU have drained before further writes to kick off the operation. MFC after: 1 week
Diffstat (limited to 'sys/alpha')
-rw-r--r--sys/alpha/alpha/busdma_machdep.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/alpha/alpha/busdma_machdep.c b/sys/alpha/alpha/busdma_machdep.c
index ee2ee41..a7eb1c5 100644
--- a/sys/alpha/alpha/busdma_machdep.c
+++ b/sys/alpha/alpha/busdma_machdep.c
@@ -891,6 +891,10 @@ _bus_dmamap_sync(bus_dma_tag_t dmat, bus_dmamap_t map, bus_dmasync_op_t op)
}
}
}
+
+ /* Ensure any pending writes have drained. */
+ if (op & (BUS_DMASYNC_PREWRITE))
+ alpha_mb();
}
static void
OpenPOWER on IntegriCloud