brcm63xx: F@ST2504n board support (Linux-3.8.12)
[openwrt.git] / target / linux / brcm63xx / patches-3.8 / 536-board_fast2504n.patch
1 --- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
2 +++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
3 @@ -3507,6 +3507,96 @@ static struct board_info __initdata boar
4         .devs = nb6_devices,
5         .num_devs = ARRAY_SIZE(nb6_devices),
6  };
7 +
8 +static struct board_info __initdata board_fast2504n = {
9 +       .name                           = "F@ST2504n",
10 +       .expected_cpu_id                = 0x6362,
11 +
12 +       .has_uart0                      = 1,
13 +
14 +       .has_enetsw                     = 1,
15 +
16 +       .enetsw = {
17 +               .used_ports = {
18 +                       [0] = {
19 +                               .used   = 1,
20 +                               .phy_id = 1,
21 +                               .name   = "port1",
22 +                       },
23 +
24 +                       [1] = {
25 +                               .used   = 1,
26 +                               .phy_id = 2,
27 +                               .name   = "port2",
28 +                       },
29 +
30 +                       [2] = {
31 +                               .used   = 1,
32 +                               .phy_id = 3,
33 +                               .name   = "port3",
34 +                       },
35 +
36 +                       [3] = {
37 +                               .used   = 1,
38 +                               .phy_id = 4,
39 +                               .name   = "port4",
40 +                       },
41 +               },
42 +       },
43 +
44 +       .leds = {
45 +               {
46 +                       .name           = "fast2504n:orange:power",
47 +                       .gpio           = 2,
48 +                       .active_low     = 1,
49 +               },
50 +               {
51 +                       .name           = "fast2504n:green:power",
52 +                       .gpio           = 10,
53 +                       .active_low     = 1,
54 +                       .default_trigger = "default-on",
55 +               },
56 +               {
57 +                       .name           = "fast2504n:red:internet",
58 +                       .gpio           = 26,
59 +                       .active_low     = 1,
60 +               },
61 +               {
62 +                       .name           = "fast2504n:green:ok",
63 +                       .gpio           = 28,
64 +                       .active_low     = 1,
65 +               },
66 +               {
67 +                       .name           = "fast2504n:orange:ok",
68 +                       .gpio           = 29,
69 +                       .active_low     = 1,
70 +               },
71 +               {
72 +                       .name           = "fast2504n:orange:wlan",
73 +                       .gpio           = 30,
74 +                       .active_low     = 1,
75 +               },
76 +       },
77 +
78 +       .buttons = {
79 +               {
80 +                       .desc           = "reset",
81 +                       .gpio           = 24,
82 +                       .type           = EV_KEY,
83 +                       .code           = KEY_RESTART,
84 +                       .debounce_interval = BCM963XX_KEYS_DEBOUNCE_INTERVAL,
85 +                       .active_low     = 1,
86 +               },
87 +               {
88 +                       .desc           = "wps",
89 +                       .gpio           = 25,
90 +                       .type           = EV_KEY,
91 +                       .code           = KEY_WPS_BUTTON,
92 +                       .debounce_interval = BCM963XX_KEYS_DEBOUNCE_INTERVAL,
93 +                       .active_low     = 1,
94 +               },
95 +       },
96 +};
97  #endif
98  
99  /*
100 @@ -3717,6 +3807,7 @@ static const struct board_info __initcon
101  
102  #ifdef CONFIG_BCM63XX_CPU_6362
103         &board_nb6,
104 +       &board_fast2504n,
105  #endif
106  
107  #ifdef CONFIG_BCM63XX_CPU_6368