ar71xx: add support for 3.7
[openwrt/svn-archive/archive.git] / target / linux / ar71xx / patches-3.7 / 611-MIPS-ath79-ap135-support.patch
1 --- a/arch/mips/ath79/Kconfig
2 +++ b/arch/mips/ath79/Kconfig
3 @@ -71,7 +71,7 @@ config ATH79_MACH_AP121
4 Atheros AP121 reference board.
5
6 config ATH79_MACH_AP136
7 - bool "Atheros AP136 reference board"
8 + bool "Atheros AP136/AP135 reference board"
9 select SOC_QCA955X
10 select ATH79_DEV_GPIO_BUTTONS
11 select ATH79_DEV_LEDS_GPIO
12 @@ -80,7 +80,7 @@ config ATH79_MACH_AP136
13 select ATH79_DEV_WMAC
14 help
15 Say 'Y' here if you want your kernel to support the
16 - Atheros AP136 reference board.
17 + Atheros AP136 or AP135 reference boards.
18
19 config ATH79_MACH_AP81
20 bool "Atheros AP81 reference board"
21 --- a/arch/mips/ath79/mach-ap136.c
22 +++ b/arch/mips/ath79/mach-ap136.c
23 @@ -237,3 +237,23 @@ static void __init ap136_020_setup(void)
24 MIPS_MACHINE(ATH79_MACH_AP136_020, "AP136-020",
25 "Atheros AP136-020 reference board",
26 ap136_020_setup);
27 +
28 +/*
29 + * AP135-020 is similar to AP136-020, any future AP135 specific init
30 + * code can be added here.
31 + */
32 +static void __init ap135_020_setup(void)
33 +{
34 + ap136_leds_gpio[0].name = "ap135:green:status";
35 + ap136_leds_gpio[1].name = "ap135:red:status";
36 + ap136_leds_gpio[2].name = "ap135:green:wps";
37 + ap136_leds_gpio[3].name = "ap135:red:wps";
38 + ap136_leds_gpio[4].name = "ap135:red:wlan-2g";
39 + ap136_leds_gpio[5].name = "ap135:red:usb";
40 +
41 + ap136_020_setup();
42 +}
43 +
44 +MIPS_MACHINE(ATH79_MACH_AP135_020, "AP135-020",
45 + "Atheros AP135-020 reference board",
46 + ap135_020_setup);
47 --- a/arch/mips/ath79/machtypes.h
48 +++ b/arch/mips/ath79/machtypes.h
49 @@ -24,6 +24,7 @@ enum ath79_mach_type {
50 ATH79_MACH_AP113, /* Atheros AP113 reference board */
51 ATH79_MACH_AP121, /* Atheros AP121 reference board */
52 ATH79_MACH_AP121_MINI, /* Atheros AP121-MINI reference board */
53 + ATH79_MACH_AP135_020, /* Atheros AP135-020 reference board */
54 ATH79_MACH_AP136_010, /* Atheros AP136-010 reference board */
55 ATH79_MACH_AP136_020, /* Atheros AP136-020 reference board */
56 ATH79_MACH_AP81, /* Atheros AP81 reference board */