diff options
author | Rafał Miłecki <zajec5@gmail.com> | 2011-06-19 02:18:11 +0200 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-06-22 16:09:41 -0400 |
commit | e7c62552ec43c094ca523fc46b98181df364f49f (patch) | |
tree | 768f3590264360000f0c36dee2829708a5433e6b /drivers/net/wireless/b43/phy_ht.c | |
parent | 1c1236e3af9c0a52e63c1c386413f13627e68e67 (diff) | |
download | op-kernel-dev-e7c62552ec43c094ca523fc46b98181df364f49f.zip op-kernel-dev-e7c62552ec43c094ca523fc46b98181df364f49f.tar.gz |
b43: HT-PHY: implement killing radio
Closed drivers kill radio right after reading radio version and MACCTL,
so it was easy to find related PHY ops:
phy_read(0x0810) -> 0x0000
phy_write(0x0810) <- 0x0000
To find out the mask of above OP, MMIO hack was used to fake read val:
phy_read(0x0810) -> 0xffff
phy_write(0x0810) <- 0x0000
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/b43/phy_ht.c')
-rw-r--r-- | drivers/net/wireless/b43/phy_ht.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/net/wireless/b43/phy_ht.c b/drivers/net/wireless/b43/phy_ht.c index 5777cdb..e84d4c1 100644 --- a/drivers/net/wireless/b43/phy_ht.c +++ b/drivers/net/wireless/b43/phy_ht.c @@ -59,6 +59,19 @@ static void b43_phy_ht_op_free(struct b43_wldev *dev) phy->ht = NULL; } +/* http://bcm-v4.sipsolutions.net/802.11/Radio/Switch%20Radio */ +static void b43_phy_ht_op_software_rfkill(struct b43_wldev *dev, + bool blocked) +{ + if (b43_read32(dev, B43_MMIO_MACCTL) & B43_MACCTL_ENABLED) + b43err(dev->wl, "MAC not suspended\n"); + + if (blocked) { + b43_phy_mask(dev, B43_PHY_HT_RF_CTL1, ~0); + } else { + } +} + static void b43_phy_ht_op_switch_analog(struct b43_wldev *dev, bool on) { if (on) { @@ -141,9 +154,7 @@ const struct b43_phy_operations b43_phyops_ht = { .phy_maskset = b43_phy_ht_op_maskset, .radio_read = b43_phy_ht_op_radio_read, .radio_write = b43_phy_ht_op_radio_write, - /* .software_rfkill = b43_phy_ht_op_software_rfkill, - */ .switch_analog = b43_phy_ht_op_switch_analog, /* .switch_channel = b43_phy_ht_op_switch_channel, |