kernel: update linux 3.3 to 3.3.2
[openwrt/svn-archive/archive.git] / target / linux / lantiq / patches-3.3 / 0010-MIPS-lantiq-fix-STP-gpio-groups.patch
1 From 8da3264153de296b0d378befd4eb711f20d7843c Mon Sep 17 00:00:00 2001
2 From: John Crispin <blogic@openwrt.org>
3 Date: Thu, 27 Oct 2011 20:06:05 +0200
4 Subject: [PATCH 10/70] MIPS: lantiq: fix STP gpio groups
5
6 The STP engine has 3 groups of 8 pins. Only the first was activated by default.
7 This patch activates the 2 missing groups.
8
9 Signed-off-by: Matti Laakso <malaakso@elisanet.fi>
10 Signed-off-by: John Crispin <blogic@openwrt.org>
11 ---
12 arch/mips/lantiq/xway/gpio_stp.c | 7 +++++--
13 1 files changed, 5 insertions(+), 2 deletions(-)
14
15 --- a/arch/mips/lantiq/xway/gpio_stp.c
16 +++ b/arch/mips/lantiq/xway/gpio_stp.c
17 @@ -35,6 +35,8 @@
18 #define LTQ_STP_ADSL_SRC (3 << 24)
19
20 #define LTQ_STP_GROUP0 (1 << 0)
21 +#define LTQ_STP_GROUP1 (1 << 1)
22 +#define LTQ_STP_GROUP2 (1 << 2)
23
24 #define LTQ_STP_RISING 0
25 #define LTQ_STP_FALLING (1 << 26)
26 @@ -93,8 +95,9 @@ static int ltq_stp_hw_init(void)
27 /* rising or falling edge */
28 ltq_stp_w32_mask(LTQ_STP_EDGE_MASK, LTQ_STP_FALLING, LTQ_STP_CON0);
29
30 - /* per default stp 15-0 are set */
31 - ltq_stp_w32_mask(0, LTQ_STP_GROUP0, LTQ_STP_CON1);
32 + /* enable all three led groups */
33 + ltq_stp_w32_mask(0, LTQ_STP_GROUP0 | LTQ_STP_GROUP1 | LTQ_STP_GROUP2,
34 + LTQ_STP_CON1);
35
36 /* stp are update periodically by the FPI bus */
37 ltq_stp_w32_mask(LTQ_STP_UPD_MASK, LTQ_STP_UPD_FPI, LTQ_STP_CON1);