ramips: use gpio-keys-polled instead of gpio-buttons
[openwrt.git] / target / linux / ar71xx / patches-3.2 / 020-MIPS-ath79-Remove-ar913x-from-common-variable-and-fu.patch
1 From cc2140939233382c1e58abc1d0a1b88fdd6215e6 Mon Sep 17 00:00:00 2001
2 From: Gabor Juhos <juhosg@openwrt.org>
3 Date: Fri, 18 Nov 2011 00:17:53 +0000
4 Subject: [PATCH 20/27] MIPS: ath79: Remove 'ar913x' from common variable and function names
5
6 The wireless MAC specific variables and the registration code can be shared
7 between multiple SoCs. Remove the 'ar913x' part from the function and
8 variable names to avoid confusions.
9
10 Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
11 Cc: Imre Kaloz <kaloz@openwrt.org>
12 Cc: linux-mips@linux-mips.org
13 Patchwork: https://patchwork.linux-mips.org/patch/3028/
14 Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
15 ---
16 arch/mips/ath79/dev-ar913x-wmac.c | 20 ++++++++++----------
17 arch/mips/ath79/dev-ar913x-wmac.h | 8 ++++----
18 arch/mips/ath79/mach-ap81.c | 2 +-
19 3 files changed, 15 insertions(+), 15 deletions(-)
20
21 --- a/arch/mips/ath79/dev-ar913x-wmac.c
22 +++ b/arch/mips/ath79/dev-ar913x-wmac.c
23 @@ -19,9 +19,9 @@
24 #include <asm/mach-ath79/ar71xx_regs.h>
25 #include "dev-ar913x-wmac.h"
26
27 -static struct ath9k_platform_data ar913x_wmac_data;
28 +static struct ath9k_platform_data ath79_wmac_data;
29
30 -static struct resource ar913x_wmac_resources[] = {
31 +static struct resource ath79_wmac_resources[] = {
32 {
33 .start = AR913X_WMAC_BASE,
34 .end = AR913X_WMAC_BASE + AR913X_WMAC_SIZE - 1,
35 @@ -33,21 +33,21 @@ static struct resource ar913x_wmac_resou
36 },
37 };
38
39 -static struct platform_device ar913x_wmac_device = {
40 +static struct platform_device ath79_wmac_device = {
41 .name = "ath9k",
42 .id = -1,
43 - .resource = ar913x_wmac_resources,
44 - .num_resources = ARRAY_SIZE(ar913x_wmac_resources),
45 + .resource = ath79_wmac_resources,
46 + .num_resources = ARRAY_SIZE(ath79_wmac_resources),
47 .dev = {
48 - .platform_data = &ar913x_wmac_data,
49 + .platform_data = &ath79_wmac_data,
50 },
51 };
52
53 -void __init ath79_register_ar913x_wmac(u8 *cal_data)
54 +void __init ath79_register_wmac(u8 *cal_data)
55 {
56 if (cal_data)
57 - memcpy(ar913x_wmac_data.eeprom_data, cal_data,
58 - sizeof(ar913x_wmac_data.eeprom_data));
59 + memcpy(ath79_wmac_data.eeprom_data, cal_data,
60 + sizeof(ath79_wmac_data.eeprom_data));
61
62 /* reset the WMAC */
63 ath79_device_reset_set(AR913X_RESET_AMBA2WMAC);
64 @@ -56,5 +56,5 @@ void __init ath79_register_ar913x_wmac(u
65 ath79_device_reset_clear(AR913X_RESET_AMBA2WMAC);
66 mdelay(10);
67
68 - platform_device_register(&ar913x_wmac_device);
69 + platform_device_register(&ath79_wmac_device);
70 }
71 --- a/arch/mips/ath79/dev-ar913x-wmac.h
72 +++ b/arch/mips/ath79/dev-ar913x-wmac.h
73 @@ -9,9 +9,9 @@
74 * by the Free Software Foundation.
75 */
76
77 -#ifndef _ATH79_DEV_AR913X_WMAC_H
78 -#define _ATH79_DEV_AR913X_WMAC_H
79 +#ifndef _ATH79_DEV_WMAC_H
80 +#define _ATH79_DEV_WMAC_H
81
82 -void ath79_register_ar913x_wmac(u8 *cal_data);
83 +void ath79_register_wmac(u8 *cal_data);
84
85 -#endif /* _ATH79_DEV_AR913X_WMAC_H */
86 +#endif /* _ATH79_DEV_WMAC_H */
87 --- a/arch/mips/ath79/mach-ap81.c
88 +++ b/arch/mips/ath79/mach-ap81.c
89 @@ -92,7 +92,7 @@ static void __init ap81_setup(void)
90 ap81_gpio_keys);
91 ath79_register_spi(&ap81_spi_data, ap81_spi_info,
92 ARRAY_SIZE(ap81_spi_info));
93 - ath79_register_ar913x_wmac(cal_data);
94 + ath79_register_wmac(cal_data);
95 ath79_register_usb();
96 }
97
This page took 0.051384 seconds and 5 git commands to generate.