mirror of https://gitee.com/openkylin/linux.git
b43: N-PHY: update switching analog on/off
Specs were recently updated. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
a6b7da5d2c
commit
2a87083177
|
@ -4025,11 +4025,24 @@ static void b43_nphy_op_software_rfkill(struct b43_wldev *dev,
|
||||||
/* http://bcm-v4.sipsolutions.net/802.11/PHY/Anacore */
|
/* http://bcm-v4.sipsolutions.net/802.11/PHY/Anacore */
|
||||||
static void b43_nphy_op_switch_analog(struct b43_wldev *dev, bool on)
|
static void b43_nphy_op_switch_analog(struct b43_wldev *dev, bool on)
|
||||||
{
|
{
|
||||||
u16 val = on ? 0 : 0x7FFF;
|
u16 override = on ? 0x0 : 0x7FFF;
|
||||||
|
u16 core = on ? 0xD : 0x00FD;
|
||||||
|
|
||||||
if (dev->phy.rev >= 3)
|
if (dev->phy.rev >= 3) {
|
||||||
b43_phy_write(dev, B43_NPHY_AFECTL_OVER1, val);
|
if (on) {
|
||||||
b43_phy_write(dev, B43_NPHY_AFECTL_OVER, val);
|
b43_phy_write(dev, B43_NPHY_AFECTL_C1, core);
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_OVER1, override);
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_C2, core);
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_OVER, override);
|
||||||
|
} else {
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_OVER1, override);
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_C1, core);
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_OVER, override);
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_C2, core);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
b43_phy_write(dev, B43_NPHY_AFECTL_OVER, override);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static int b43_nphy_op_switch_channel(struct b43_wldev *dev,
|
static int b43_nphy_op_switch_channel(struct b43_wldev *dev,
|
||||||
|
|
Loading…
Reference in New Issue