aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/hw.c
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-09-10 15:12:23 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-10-07 16:39:27 -0400
commit867633f026456ff71d4c4890f502c7a61b2adac0 (patch)
treed961a66c05c2d729cc4ff3259021c98fce782f6d /drivers/net/wireless/ath/ath9k/hw.c
parentdb7197184802578314d974e4b2bc961bdcec8f8c (diff)
ath9k: Define bus agnostic bluetooth coex prep helper
We disable ASPM when enabling bluetooth coexistance. Disabling ASPM is a bus specific operation. In the future other buses may support bluetooth coexistance, an example is USB. To this end move the current routine which disables ASPM into pci.c, and declare it the PCI bt_coex_prep() helper. Additionally, since ASPM is a PCI-Express primitive ensure we don't ever try to muck with ASPM registers on non PCI-express devices. This also cleans up hw.c to not include bus specific headers or utilities. Cc: Vasanthakumar Thiagarajan <vasanth@atheros.com> Cc: Stephen Chen <stephen.chen@atheros.com> Cc: Zhifeng Cai <zhifeng.cai@atheros.com> Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/hw.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/hw.c14
1 files changed, 0 insertions, 14 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c
index 4e14c307b3d..a3b1ce32cfc 100644
--- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -16,7 +16,6 @@
16 16
17#include <linux/io.h> 17#include <linux/io.h>
18#include <asm/unaligned.h> 18#include <asm/unaligned.h>
19#include <linux/pci.h>
20 19
21#include "hw.h" 20#include "hw.h"
22#include "ath9k.h" 21#include "ath9k.h"
@@ -4294,16 +4293,3 @@ void ath_gen_timer_isr(struct ath_hw *ah)
4294 timer->trigger(timer->arg); 4293 timer->trigger(timer->arg);
4295 } 4294 }
4296} 4295}
4297
4298/*
4299 * Primitive to disable ASPM
4300 */
4301void ath_pcie_aspm_disable(struct ath_softc *sc)
4302{
4303 struct pci_dev *pdev = to_pci_dev(sc->dev);
4304 u8 aspm;
4305
4306 pci_read_config_byte(pdev, ATH_PCIE_CAP_LINK_CTRL, &aspm);
4307 aspm &= ~(ATH_PCIE_CAP_LINK_L0S | ATH_PCIE_CAP_LINK_L1);
4308 pci_write_config_byte(pdev, ATH_PCIE_CAP_LINK_CTRL, aspm);
4309}