[PATCH 11/14] Spidernet Memory barrier

Linas Vepstas linas at austin.ibm.com
Thu Dec 14 08:22:04 EST 2006


Add memory barrier to make sure that the rest of the 
RX descriptor state is flushed to memory before we tell 
the hardware that its ready to go.

Signed-off-by: Linas Vepstas <linas at austin.ibm.com>
Cc: James K Lewis <jklewis at us.ibm.com>
Cc: Arnd Bergmann <arnd at arndb.de>

----
 drivers/net/spider_net.c |    1 +
 1 file changed, 1 insertion(+)

Index: linux-2.6.19-git7/drivers/net/spider_net.c
===================================================================
--- linux-2.6.19-git7.orig/drivers/net/spider_net.c	2006-12-13 14:28:19.000000000 -0600
+++ linux-2.6.19-git7/drivers/net/spider_net.c	2006-12-13 14:28:23.000000000 -0600
@@ -419,6 +419,7 @@ spider_net_prepare_rx_descr(struct spide
 		card->spider_stats.rx_iommu_map_error++;
 		descr->dmac_cmd_status = SPIDER_NET_DESCR_NOT_IN_USE;
 	} else {
+		wmb();
 		descr->dmac_cmd_status = SPIDER_NET_DESCR_CARDOWNED |
 					 SPIDER_NET_DMAC_NOINTR_COMPLETE;
 	}



More information about the Linuxppc-dev mailing list