* [ath9k-devel] [PATCH v0 4/6] support for antenna configuration profiles
@ 2011-11-14 13:07 Daniel Golle
0 siblings, 0 replies; only message in thread
From: Daniel Golle @ 2011-11-14 13:07 UTC (permalink / raw)
To: ath9k-devel
Add support for platform-supplied antenna-switch profiles in the AP91 template
of the OpenWrt Kernel.
Here hust for illustration and to be re-posted on openwrt-devel.
Signed-off-by: Daniel Golle <dgolle@allnet.de>
Index: arch/mips/ar71xx/dev-ap91-pci.c
===================================================================
--- arch/mips/ar71xx/dev-ap91-pci.c (revision 28855)
+++ arch/mips/ar71xx/dev-ap91-pci.c (working copy)
@@ -53,6 +53,15 @@
ap91_wmac_data.gpio_val = val;
}
+__init void ap91_pci_setup_wmac_switchcom(int idx, u32 val, char *name, char *desc)
+{
+ if (idx>=0 && idx<ATH9K_PLAT_MAX_SWITCHCOM_PROFILES) {
+ ap91_wmac_data.switchcom_profiles[idx].val = val;
+ ap91_wmac_data.switchcom_profiles[idx].name = name;
+ ap91_wmac_data.switchcom_profiles[idx].desc = desc;
+ }
+}
+
void __init ap91_pci_init(u8 *cal_data, u8 *mac_addr)
{
if (cal_data)
Index: arch/mips/ar71xx/dev-ap91-pci.h
===================================================================
--- arch/mips/ar71xx/dev-ap91-pci.h (revision 28855)
+++ arch/mips/ar71xx/dev-ap91-pci.h (working copy)
@@ -15,10 +15,12 @@
void ap91_pci_init(u8 *cal_data, u8 *mac_addr) __init;
void ap91_pci_setup_wmac_led_pin(int pin) __init;
void ap91_pci_setup_wmac_gpio(u32 mask, u32 val) __init;
+void ap91_pci_setup_wmac_switchcom(int idx, u32 val, char *name, char *desc) __init;
#else
static inline void ap91_pci_init(u8 *cal_data, u8 *mac_addr) { }
static inline void ap91_pci_setup_wmac_led_pin(int pin) { }
static inline void ap91_pci_setup_wmac_gpio(u32 mask, u32 gpio) { }
+static inline void ap91_pci_setup_wmac_switchcom(int idx, u32 val, char *name, char *desc) { }
#endif
#endif /* _AR71XX_DEV_AP91_PCI_H */
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-11-14 13:07 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-14 13:07 [ath9k-devel] [PATCH v0 4/6] support for antenna configuration profiles Daniel Golle
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.