[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <48239865.3070706@myri.com>
Date: Fri, 09 May 2008 02:18:45 +0200
From: Brice Goglin <brice@...i.com>
To: Jeff Garzik <jeff@...zik.org>
CC: netdev@...r.kernel.org
Subject: [PATCH 07/16] myri10ge: add barrier in myri10ge_send_cmd
Add a barrier() in the usleep() loop in myri10ge_send_cmd().
Without the barrier, some mips machine never notices that the
firmware has DMA'ed the response.
Signed-off-by: Brice Goglin <brice@...i.com>
Signed-off-by: Andrew Gallatin <gallatin@...i.com>
---
drivers/net/myri10ge/myri10ge.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Index: linux-2.6/drivers/net/myri10ge/myri10ge.c
===================================================================
--- linux-2.6.orig/drivers/net/myri10ge/myri10ge.c 2008-05-09
00:04:48.000000000 +0200
+++ linux-2.6/drivers/net/myri10ge/myri10ge.c 2008-05-09
00:05:30.000000000 +0200
@@ -361,8 +361,10 @@
for (sleep_total = 0;
sleep_total < 1000
&& response->result == htonl(MYRI10GE_NO_RESPONSE_RESULT);
- sleep_total += 10)
+ sleep_total += 10) {
udelay(10);
+ mb();
+ }
} else {
/* use msleep for most command */
for (sleep_total = 0;
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists