diff options
-rw-r--r-- | drivers/net/wireless/b43/phy_ht.c | 50 |
1 files changed, 49 insertions, 1 deletions
diff --git a/drivers/net/wireless/b43/phy_ht.c b/drivers/net/wireless/b43/phy_ht.c index 69412d1fb655..30b19c61037d 100644 --- a/drivers/net/wireless/b43/phy_ht.c +++ b/drivers/net/wireless/b43/phy_ht.c | |||
@@ -86,7 +86,10 @@ static void b43_radio_2059_channel_setup(struct b43_wldev *dev, | |||
86 | static void b43_radio_2059_init(struct b43_wldev *dev) | 86 | static void b43_radio_2059_init(struct b43_wldev *dev) |
87 | { | 87 | { |
88 | const u16 routing[] = { R2059_SYN, R2059_TXRX0, R2059_RXRX1 }; | 88 | const u16 routing[] = { R2059_SYN, R2059_TXRX0, R2059_RXRX1 }; |
89 | u8 i; | 89 | const u16 radio_values[3][2] = { |
90 | { 0x61, 0xE9 }, { 0x69, 0xD5 }, { 0x73, 0x99 }, | ||
91 | }; | ||
92 | u16 i, j; | ||
90 | 93 | ||
91 | b43_radio_write(dev, R2059_ALL | 0x51, 0x0070); | 94 | b43_radio_write(dev, R2059_ALL | 0x51, 0x0070); |
92 | b43_radio_write(dev, R2059_ALL | 0x5a, 0x0003); | 95 | b43_radio_write(dev, R2059_ALL | 0x5a, 0x0003); |
@@ -100,6 +103,51 @@ static void b43_radio_2059_init(struct b43_wldev *dev) | |||
100 | b43_radio_mask(dev, 0x2e, ~0x0078); | 103 | b43_radio_mask(dev, 0x2e, ~0x0078); |
101 | b43_radio_mask(dev, 0xc0, ~0x0080); | 104 | b43_radio_mask(dev, 0xc0, ~0x0080); |
102 | 105 | ||
106 | if (1) { /* FIXME */ | ||
107 | b43_radio_set(dev, R2059_RXRX1 | 0x4, 0x1); | ||
108 | udelay(10); | ||
109 | b43_radio_set(dev, R2059_RXRX1 | 0x0BF, 0x1); | ||
110 | b43_radio_maskset(dev, R2059_RXRX1 | 0x19B, 0x3, 0x2); | ||
111 | |||
112 | b43_radio_set(dev, R2059_RXRX1 | 0x4, 0x2); | ||
113 | udelay(100); | ||
114 | b43_radio_mask(dev, R2059_RXRX1 | 0x4, ~0x2); | ||
115 | |||
116 | for (i = 0; i < 10000; i++) { | ||
117 | if (b43_radio_read(dev, R2059_RXRX1 | 0x145) & 1) { | ||
118 | i = 0; | ||
119 | break; | ||
120 | } | ||
121 | udelay(100); | ||
122 | } | ||
123 | if (i) | ||
124 | b43err(dev->wl, "radio 0x945 timeout\n"); | ||
125 | |||
126 | b43_radio_mask(dev, R2059_RXRX1 | 0x4, ~0x1); | ||
127 | b43_radio_set(dev, 0xa, 0x60); | ||
128 | |||
129 | for (i = 0; i < 3; i++) { | ||
130 | b43_radio_write(dev, 0x17F, radio_values[i][0]); | ||
131 | b43_radio_write(dev, 0x13D, 0x6E); | ||
132 | b43_radio_write(dev, 0x13E, radio_values[i][1]); | ||
133 | b43_radio_write(dev, 0x13C, 0x55); | ||
134 | |||
135 | for (j = 0; j < 10000; j++) { | ||
136 | if (b43_radio_read(dev, 0x140) & 2) { | ||
137 | j = 0; | ||
138 | break; | ||
139 | } | ||
140 | udelay(500); | ||
141 | } | ||
142 | if (j) | ||
143 | b43err(dev->wl, "radio 0x140 timeout\n"); | ||
144 | |||
145 | b43_radio_write(dev, 0x13C, 0x15); | ||
146 | } | ||
147 | |||
148 | b43_radio_mask(dev, 0x17F, ~0x1); | ||
149 | } | ||
150 | |||
103 | b43_radio_mask(dev, 0x11, 0x0008); | 151 | b43_radio_mask(dev, 0x11, 0x0008); |
104 | } | 152 | } |
105 | 153 | ||