]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/2.6.30.4/dsa-fix-88e6xxx-statistics-counter-snapshotting.patch
5.1-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 2.6.30.4 / dsa-fix-88e6xxx-statistics-counter-snapshotting.patch
CommitLineData
db972160
GKH
1From 1ded3f59f35a2642852b3e2a1c0fa8a97777e9af Mon Sep 17 00:00:00 2001
2From: Stephane Contri <Stephane.Contri@grassvalley.com>
3Date: Thu, 2 Jul 2009 23:26:48 +0000
4Subject: dsa: fix 88e6xxx statistics counter snapshotting
5
6From: Stephane Contri <Stephane.Contri@grassvalley.com>
7
8commit 1ded3f59f35a2642852b3e2a1c0fa8a97777e9af upstream.
9
10The bit that tells us whether a statistics counter snapshot operation
11has completed is located in the GLOBAL register block, not in the
12GLOBAL2 register block, so fix up mv88e6xxx_stats_wait() to poll the
13right register address.
14
15Signed-off-by: Stephane Contri <Stephane.Contri@grassvalley.com>
16Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
17Signed-off-by: David S. Miller <davem@davemloft.net>
18Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
19
20---
21 net/dsa/mv88e6xxx.c | 2 +-
22 1 file changed, 1 insertion(+), 1 deletion(-)
23
24--- a/net/dsa/mv88e6xxx.c
25+++ b/net/dsa/mv88e6xxx.c
26@@ -418,7 +418,7 @@ static int mv88e6xxx_stats_wait(struct d
27 int i;
28
29 for (i = 0; i < 10; i++) {
30- ret = REG_READ(REG_GLOBAL2, 0x1d);
31+ ret = REG_READ(REG_GLOBAL, 0x1d);
32 if ((ret & 0x8000) == 0)
33 return 0;
34 }