aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2010-02-09 16:27:35 +0000
committerGabor Juhos <juhosg@openwrt.org>2010-02-09 16:27:35 +0000
commit4f9f195c3281ced570efe34b9f5d5fcb9520b42e (patch)
tree11ecec6c6f37a4ce9f2b0c720e42bd2baa85eed9 /target
parent6c60de0ed15145bbc1376095aeda0d2b43fad837 (diff)
downloadupstream-4f9f195c3281ced570efe34b9f5d5fcb9520b42e.tar.gz
upstream-4f9f195c3281ced570efe34b9f5d5fcb9520b42e.tar.bz2
upstream-4f9f195c3281ced570efe34b9f5d5fcb9520b42e.zip
ar71xx/mac80211: add a workaround for the bad signal strength on the WNDR3700
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19565 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target')
-rw-r--r--target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.c8
-rw-r--r--target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.h11
-rw-r--r--target/linux/ar71xx/files/arch/mips/ar71xx/mach-wndr3700.c3
-rw-r--r--target/linux/ar71xx/files/include/linux/ath9k_platform.h2
4 files changed, 18 insertions, 6 deletions
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.c b/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.c
index 920ab6c725..bfa668f74f 100644
--- a/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.c
+++ b/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.c
@@ -1,7 +1,7 @@
/*
* Atheros AP94 reference board PCI initialization
*
- * Copyright (C) 2009 Gabor Juhos <juhosg@openwrt.org>
+ * Copyright (C) 2009-2010 Gabor Juhos <juhosg@openwrt.org>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 as published
@@ -125,6 +125,12 @@ static void ap94_pci_fixup(struct pci_dev *dev)
}
DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_ATHEROS, PCI_ANY_ID, ap94_pci_fixup);
+void __init ap94_pci_enable_quirk_wndr3700(void)
+{
+ ap94_wmac0_data.quirk_wndr3700 = 1;
+ ap94_wmac1_data.quirk_wndr3700 = 1;
+}
+
void __init ap94_pci_init(u8 *cal_data0, u8 *mac_addr0,
u8 *cal_data1, u8 *mac_addr1)
{
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.h b/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.h
index 7969ed4270..e69ba55e53 100644
--- a/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.h
+++ b/target/linux/ar71xx/files/arch/mips/ar71xx/dev-ap94-pci.h
@@ -1,7 +1,7 @@
/*
* Atheros AP94 reference board PCI initialization
*
- * Copyright (C) 2009 Gabor Juhos <juhosg@openwrt.org>
+ * Copyright (C) 2009-2010 Gabor Juhos <juhosg@openwrt.org>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 as published
@@ -14,11 +14,14 @@
#if defined(CONFIG_AR71XX_DEV_AP94_PCI)
void ap94_pci_init(u8 *cal_data0, u8 *mac_addr0,
u8 *cal_data1, u8 *mac_addr1) __init;
+
+void ap94_pci_enable_quirk_wndr3700(void) __init;
+
#else
static inline void ap94_pci_init(u8 *cal_data0, u8 *mac_addr0,
- u8 *cal_data1, u8 *mac_addr1)
-{
-}
+ u8 *cal_data1, u8 *mac_addr1) {}
+
+static inline void ap94_pci_enable_quirk_wndr3700(void) {}
#endif
#endif /* _AR71XX_DEV_AP94_PCI_H */
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/mach-wndr3700.c b/target/linux/ar71xx/files/arch/mips/ar71xx/mach-wndr3700.c
index a0eb8d4826..eaa9654aaa 100644
--- a/target/linux/ar71xx/files/arch/mips/ar71xx/mach-wndr3700.c
+++ b/target/linux/ar71xx/files/arch/mips/ar71xx/mach-wndr3700.c
@@ -2,7 +2,7 @@
* Netgear WNDR3700 board support
*
* Copyright (C) 2009 Marco Porsch
- * Copyright (C) 2009 Gabor Juhos <juhosg@openwrt.org>
+ * Copyright (C) 2009-2010 Gabor Juhos <juhosg@openwrt.org>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 as published
@@ -191,6 +191,7 @@ static void __init wndr3700_setup(void)
platform_device_register(&wndr3700_rtl8366s_device);
platform_device_register_simple("wndr3700-led-usb", -1, NULL, 0);
+ ap94_pci_enable_quirk_wndr3700();
ap94_pci_init(art + WNDR3700_CALDATA0_OFFSET,
art + WNDR3700_WMAC0_MAC_OFFSET,
art + WNDR3700_CALDATA1_OFFSET,
diff --git a/target/linux/ar71xx/files/include/linux/ath9k_platform.h b/target/linux/ar71xx/files/include/linux/ath9k_platform.h
index 9fb8c6e422..3c22012028 100644
--- a/target/linux/ar71xx/files/include/linux/ath9k_platform.h
+++ b/target/linux/ar71xx/files/include/linux/ath9k_platform.h
@@ -16,6 +16,8 @@
struct ath9k_platform_data {
u16 eeprom_data[ATH9K_PLAT_EEP_MAX_WORDS];
u8 *macaddr;
+
+ unsigned long quirk_wndr3700:1;
};
#endif /* _LINUX_ATH9K_PLATFORM_H */