From 4473d4da67b9ccf00d1338380c5f66fc2d1ba894 Mon Sep 17 00:00:00 2001 From: Adrian Chadd Date: Thu, 15 Dec 2011 00:59:11 +0000 Subject: [PATCH] Add the 11n chipset RF frontends to the linker set, even though they're not attached this way. The AR5212 based NICs have a variety of RF frontends, so there's a linker set which the AR5212 attach routine calls. The same framework is used for the AR5416 and later but as there's a fixed RF frontend for each 11n NIC, it is just directly attached. However in the case of compiling a cut down HAL (eg _just_ AR9130 WMAC support), the linker set ends up being empty and this causes the compile to fail. So this is just a workaround for that - it means those users who wish an 11n only HAL can compile the 11n chipsets and RF frontend they need, and just "ath_ar5212" for the AR5212/AR5416 common code, and it'll just work. Sponsored by: Hobnob, Inc. --- sys/dev/ath/ath_hal/ar5416/ar2133.c | 8 ++++++++ sys/dev/ath/ath_hal/ar9002/ar9280.c | 8 ++++++++ sys/dev/ath/ath_hal/ar9002/ar9285.c | 8 ++++++++ sys/dev/ath/ath_hal/ar9002/ar9287.c | 8 ++++++++ 4 files changed, 32 insertions(+) diff --git a/sys/dev/ath/ath_hal/ar5416/ar2133.c b/sys/dev/ath/ath_hal/ar5416/ar2133.c index f25c108267e2..779f0de256d2 100644 --- a/sys/dev/ath/ath_hal/ar5416/ar2133.c +++ b/sys/dev/ath/ath_hal/ar5416/ar2133.c @@ -549,3 +549,11 @@ ar2133RfAttach(struct ath_hal *ah, HAL_STATUS *status) return AH_TRUE; } + +static HAL_BOOL +ar2133Probe(struct ath_hal *ah) +{ + return (AR_SREV_OWL(ah) || AR_SREV_HOWL(ah) || AR_SREV_SOWL(ah)); +} + +AH_RF(RF2133, ar2133Probe, ar2133RfAttach); diff --git a/sys/dev/ath/ath_hal/ar9002/ar9280.c b/sys/dev/ath/ath_hal/ar9002/ar9280.c index 99fd1d790d2e..cc622f8c2804 100644 --- a/sys/dev/ath/ath_hal/ar9002/ar9280.c +++ b/sys/dev/ath/ath_hal/ar9002/ar9280.c @@ -384,3 +384,11 @@ ar9280RfAttach(struct ath_hal *ah, HAL_STATUS *status) return AH_TRUE; } + +static HAL_BOOL +ar9280RfProbe(struct ath_hal *ah) +{ + return (AR_SREV_MERLIN(ah)); +} + +AH_RF(RF9280, ar9280RfProbe, ar9280RfAttach); diff --git a/sys/dev/ath/ath_hal/ar9002/ar9285.c b/sys/dev/ath/ath_hal/ar9002/ar9285.c index f1851ccc91b5..9e9f95cac851 100644 --- a/sys/dev/ath/ath_hal/ar9002/ar9285.c +++ b/sys/dev/ath/ath_hal/ar9002/ar9285.c @@ -77,3 +77,11 @@ ar9285RfAttach(struct ath_hal *ah, HAL_STATUS *status) return AH_TRUE; } + +static HAL_BOOL +ar9285RfProbe(struct ath_hal *ah) +{ + return (AR_SREV_KITE(ah)); +} + +AH_RF(RF9285, ar9285RfProbe, ar9285RfAttach); diff --git a/sys/dev/ath/ath_hal/ar9002/ar9287.c b/sys/dev/ath/ath_hal/ar9002/ar9287.c index 9b874b36bd3c..724fb7c55dd1 100644 --- a/sys/dev/ath/ath_hal/ar9002/ar9287.c +++ b/sys/dev/ath/ath_hal/ar9002/ar9287.c @@ -390,3 +390,11 @@ ar9287RfAttach(struct ath_hal *ah, HAL_STATUS *status) return AH_TRUE; } + +static HAL_BOOL +ar9287RfProbe(struct ath_hal *ah) +{ + return (AR_SREV_KIWI(ah)); +} + +AH_RF(RF9287, ar9287RfProbe, ar9287RfAttach);