From cde6672474c8f8ad8688f3c6f1d1f35cb3d29539 Mon Sep 17 00:00:00 2001 From: jhb Date: Thu, 15 Sep 2005 17:09:42 +0000 Subject: 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 --- sys/alpha/alpha/busdma_machdep.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'sys/alpha') 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 -- cgit v1.1