[06/20] ibmveth: Use lighter weight read memory barrier in ibmveth_poll

Message ID 20100823001238.849831193@samba.org
State Awaiting Upstream, archived
Delegated to: David Miller
Headers show

Commit Message

Anton Blanchard Aug. 23, 2010, 12:09 a.m.
We want to order the read in ibmveth_rxq_pending_buffer and the read of
ibmveth_rxq_buffer_valid which are both cacheable memory. smp_rmb() is good
enough for this.

Signed-off-by: Anton Blanchard <anton@samba.org>

To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Index: net-next-2.6/drivers/net/ibmveth.c
--- net-next-2.6.orig/drivers/net/ibmveth.c	2010-08-23 08:52:29.793789816 +1000
+++ net-next-2.6/drivers/net/ibmveth.c	2010-08-23 08:52:30.283755038 +1000
@@ -1010,7 +1010,7 @@  static int ibmveth_poll(struct napi_stru
 		if (!ibmveth_rxq_pending_buffer(adapter))
-		rmb();
+		smp_rmb();
 		if (!ibmveth_rxq_buffer_valid(adapter)) {
 			wmb(); /* suggested by larson1 */