Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 134416
b: refs/heads/master
c: 99e0fca
h: refs/heads/master
v: v3
  • Loading branch information
Michael Buesch authored and John W. Linville committed Feb 9, 2009
1 parent 7b724ef commit e2c66ee
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 686aa5f2137d04f389e527f0391d65232338e599
refs/heads/master: 99e0fca6740b98aed1f604fc2e0acbdbc9e7578a
15 changes: 11 additions & 4 deletions trunk/drivers/net/wireless/b43/phy_lp.c
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@ struct b2062_freqdata {
/* Initialize the 2062 radio. */
static void lpphy_2062_init(struct b43_wldev *dev)
{
struct ssb_bus *bus = dev->dev->bus;
u32 crystalfreq, pdiv, tmp, ref;
unsigned int i;
const struct b2062_freqdata *fd = NULL;
Expand Down Expand Up @@ -193,7 +194,11 @@ static void lpphy_2062_init(struct b43_wldev *dev)
else
b43_radio_mask(dev, B2062_N_TSSI_CTL0, ~0x1);

crystalfreq = 0;//FIXME
/* Get the crystal freq, in Hz. */
crystalfreq = bus->chipco.pmu.crystalfreq * 1000;

B43_WARN_ON(!(bus->chipco.capabilities & SSB_CHIPCO_CAP_PMU));
B43_WARN_ON(crystalfreq == 0);

if (crystalfreq >= 30000000) {
pdiv = 1;
Expand All @@ -219,13 +224,15 @@ static void lpphy_2062_init(struct b43_wldev *dev)
break;
}
}
if (B43_WARN_ON(!fd))
return;
if (!fd)
fd = &freqdata_tab[ARRAY_SIZE(freqdata_tab) - 1];
b43dbg(dev->wl, "b2062: Using crystal tab entry %u kHz.\n",
fd->freq); /* FIXME: Keep this printk until the code is fully debugged. */

b43_radio_write(dev, B2062_S_RFPLL_CTL8,
((u16)(fd->data[1]) << 4) | fd->data[0]);
b43_radio_write(dev, B2062_S_RFPLL_CTL9,
((u16)(fd->data[3]) << 4) | fd->data[2]);//FIXME specs are different
((u16)(fd->data[3]) << 4) | fd->data[2]);
b43_radio_write(dev, B2062_S_RFPLL_CTL10, fd->data[4]);
b43_radio_write(dev, B2062_S_RFPLL_CTL11, fd->data[5]);
}
Expand Down

0 comments on commit e2c66ee

Please sign in to comment.