summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath5k/pci.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2010-12-02 10:27:06 +0100
committerJohn W. Linville <linville@tuxdriver.com>2010-12-02 15:17:51 -0500
commite7aecd327d80b2f156b54769013aaccb2a20645a (patch)
tree6b0edda6058597dc290bf75dd72883a8480b8250 /drivers/net/wireless/ath/ath5k/pci.c
parent8efa5d7d6ad307ae2d220def37ca89594062c40d (diff)
ath5k: Add a function to read chipset's MAC revision
Add bus dependent revision read function which is used to determine chipset's MAC before hardware is initialized. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Wojciech Dubowik <Wojciech.Dubowik@neratec.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath5k/pci.c')
-rw-r--r--drivers/net/wireless/ath/ath5k/pci.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath5k/pci.c b/drivers/net/wireless/ath/ath5k/pci.c
index 3f26cf200196..39f033128c5a 100644
--- a/drivers/net/wireless/ath/ath5k/pci.c
+++ b/drivers/net/wireless/ath/ath5k/pci.c
@@ -100,6 +100,12 @@ bool ath5k_pci_eeprom_read(struct ath_common *common, u32 offset, u16 *data)
return -ETIMEDOUT;
}
+int ath5k_hw_read_srev(struct ath5k_hw *ah)
+{
+ ah->ah_mac_srev = ath5k_hw_reg_read(ah, AR5K_SREV);
+ return 0;
+}
+
/* Common ath_bus_opts structure */
static const struct ath_bus_ops ath_pci_bus_ops = {
.ath_bus_type = ATH_PCI,