summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/htc_drv_init.c
diff options
context:
space:
mode:
authorSujith Manoharan <Sujith.Manoharan@atheros.com>2010-12-07 16:31:38 +0530
committerJohn W. Linville <linville@tuxdriver.com>2010-12-07 17:08:06 -0500
commit0b5ead91cda63e0db964dadc77601233434f60cb (patch)
tree989e877003120c769f8d155dee129033f96029f2 /drivers/net/wireless/ath/ath9k/htc_drv_init.c
parentc658e5db01117bf2a321a9a782754dd5b10e2f15 (diff)
downloadlinux-0b5ead91cda63e0db964dadc77601233434f60cb.tar.bz2
ath9k_htc: Cleanup device identification
ath.ko is a common module shared between ath5k, ar9170usb, ath9k and ath9k_htc. Adding driver specific data to the shared structure would impact all the drivers. Handling USB device recognition for devices specific to ath9k_htc can be handled within the driver itself. Also, AR7010 refers to the processor used in both AR9280/AR9287 based devices. Rename the device enumerations accordingly. While at it, check properly for the bus type when choosing the EEPROM base address for UB95. Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/htc_drv_init.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/htc_drv_init.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_init.c b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
index f89f6635abae..680cd369f144 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_init.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
@@ -246,7 +246,7 @@ static int ath9k_init_htc_services(struct ath9k_htc_priv *priv, u16 devid,
* the HIF layer, shouldn't matter much.
*/
- if (drv_info & AR7010_DEVICE)
+ if (IS_AR7010_DEVICE(drv_info))
priv->htc->credits = 45;
else
priv->htc->credits = 33;
@@ -630,6 +630,7 @@ static int ath9k_init_priv(struct ath9k_htc_priv *priv,
ah->hw_version.devid = devid;
ah->hw_version.subsysid = 0; /* FIXME */
+ ah->hw_version.usbdev = drv_info;
ah->ah_flags |= AH_USE_EEPROM;
priv->ah = ah;
@@ -640,7 +641,6 @@ static int ath9k_init_priv(struct ath9k_htc_priv *priv,
common->hw = priv->hw;
common->priv = priv;
common->debug_mask = ath9k_debug;
- common->driver_info = drv_info;
spin_lock_init(&priv->wmi->wmi_lock);
spin_lock_init(&priv->beacon_lock);
@@ -891,7 +891,7 @@ int ath9k_htc_resume(struct htc_target *htc_handle)
return ret;
ret = ath9k_init_htc_services(priv, priv->ah->hw_version.devid,
- priv->ah->common.driver_info);
+ priv->ah->hw_version.usbdev);
return ret;
}
#endif