1 --- a/drivers/ssb/driver_chipcommon_pmu.c
2 +++ b/drivers/ssb/driver_chipcommon_pmu.c
3 @@ -28,6 +28,21 @@ static void ssb_chipco_pll_write(struct
4 chipco_write32(cc, SSB_CHIPCO_PLLCTL_DATA, value);
7 +static void ssb_chipco_regctl_maskset(struct ssb_chipcommon *cc,
8 + u32 offset, u32 mask, u32 set)
12 + chipco_read32(cc, SSB_CHIPCO_REGCTL_ADDR);
13 + chipco_write32(cc, SSB_CHIPCO_REGCTL_ADDR, offset);
14 + chipco_read32(cc, SSB_CHIPCO_REGCTL_ADDR);
15 + value = chipco_read32(cc, SSB_CHIPCO_REGCTL_DATA);
18 + chipco_write32(cc, SSB_CHIPCO_REGCTL_DATA, value);
19 + chipco_read32(cc, SSB_CHIPCO_REGCTL_DATA);
22 struct pmu0_plltab_entry {
23 u16 freq; /* Crystal frequency in kHz.*/
24 u8 xf; /* Crystal frequency value for PMU control */
25 @@ -506,3 +521,82 @@ void ssb_pmu_init(struct ssb_chipcommon
27 ssb_pmu_resources_init(cc);
30 +void ssb_pmu_set_ldo_voltage(struct ssb_chipcommon *cc,
31 + enum ssb_pmu_ldo_volt_id id, u32 voltage)
33 + struct ssb_bus *bus = cc->dev->bus;
34 + u32 addr, shift, mask;
36 + switch (bus->chip_id) {
66 + if (SSB_WARN_ON(id != LDO_PAREF))
76 + ssb_chipco_regctl_maskset(cc, addr, ~(mask << shift),
77 + (voltage & mask) << shift);
80 +void ssb_pmu_set_ldo_paref(struct ssb_chipcommon *cc, bool on)
82 + struct ssb_bus *bus = cc->dev->bus;
85 + switch (bus->chip_id) {
87 + ldo = SSB_PMURES_4312_PA_REF_LDO;
90 + ldo = SSB_PMURES_4328_PA_REF_LDO;
93 + ldo = SSB_PMURES_5354_PA_REF_LDO;
100 + chipco_set32(cc, SSB_CHIPCO_PMU_MINRES_MSK, 1 << ldo);
102 + chipco_mask32(cc, SSB_CHIPCO_PMU_MINRES_MSK, ~(1 << ldo));
103 + chipco_read32(cc, SSB_CHIPCO_PMU_MINRES_MSK); //SPEC FIXME found via mmiotrace - dummy read?
106 +EXPORT_SYMBOL(ssb_pmu_set_ldo_voltage);
107 +EXPORT_SYMBOL(ssb_pmu_set_ldo_paref);
108 --- a/drivers/ssb/main.c
109 +++ b/drivers/ssb/main.c
110 @@ -469,6 +469,8 @@ static int ssb_devices_register(struct s
111 dev->parent = &bus->host_pcmcia->dev;
114 + case SSB_BUSTYPE_SDIO:
116 case SSB_BUSTYPE_SSB:
117 dev->dma_mask = &dev->coherent_dma_mask;
119 @@ -1358,8 +1360,10 @@ static int __init ssb_modinit(void)
121 err = ssb_attach_queued_buses();
125 bus_unregister(&ssb_bustype);
129 err = b43_pci_ssb_bridge_init();
131 @@ -1375,7 +1379,7 @@ static int __init ssb_modinit(void)
132 /* don't fail SSB init because of this */
139 /* ssb must be initialized after PCI but before the ssb drivers.
140 --- a/drivers/ssb/pci.c
141 +++ b/drivers/ssb/pci.c
142 @@ -169,8 +169,14 @@ err_pci:
143 /* Get the word-offset for a SSB_SPROM_XXX define. */
144 #define SPOFF(offset) (((offset) - SSB_SPROM_BASE) / sizeof(u16))
145 /* Helper to extract some _offset, which is one of the SSB_SPROM_XXX defines. */
146 -#define SPEX(_outvar, _offset, _mask, _shift) \
147 +#define SPEX16(_outvar, _offset, _mask, _shift) \
148 out->_outvar = ((in[SPOFF(_offset)] & (_mask)) >> (_shift))
149 +#define SPEX32(_outvar, _offset, _mask, _shift) \
150 + out->_outvar = ((((u32)in[SPOFF((_offset)+2)] << 16 | \
151 + in[SPOFF(_offset)]) & (_mask)) >> (_shift))
152 +#define SPEX(_outvar, _offset, _mask, _shift) \
153 + SPEX16(_outvar, _offset, _mask, _shift)
156 static inline u8 ssb_crc8(u8 crc, u8 data)
158 @@ -474,12 +480,14 @@ static void sprom_extract_r8(struct ssb_
160 /* extract the MAC address */
161 for (i = 0; i < 3; i++) {
162 - v = in[SPOFF(SSB_SPROM1_IL0MAC) + i];
163 + v = in[SPOFF(SSB_SPROM8_IL0MAC) + i];
164 *(((__be16 *)out->il0mac) + i) = cpu_to_be16(v);
166 SPEX(country_code, SSB_SPROM8_CCODE, 0xFFFF, 0);
167 SPEX(boardflags_lo, SSB_SPROM8_BFLLO, 0xFFFF, 0);
168 SPEX(boardflags_hi, SSB_SPROM8_BFLHI, 0xFFFF, 0);
169 + SPEX(boardflags2_lo, SSB_SPROM8_BFL2LO, 0xFFFF, 0);
170 + SPEX(boardflags2_hi, SSB_SPROM8_BFL2HI, 0xFFFF, 0);
171 SPEX(ant_available_a, SSB_SPROM8_ANTAVAIL, SSB_SPROM8_ANTAVAIL_A,
172 SSB_SPROM8_ANTAVAIL_A_SHIFT);
173 SPEX(ant_available_bg, SSB_SPROM8_ANTAVAIL, SSB_SPROM8_ANTAVAIL_BG,
174 @@ -490,12 +498,55 @@ static void sprom_extract_r8(struct ssb_
175 SPEX(maxpwr_a, SSB_SPROM8_MAXP_A, SSB_SPROM8_MAXP_A_MASK, 0);
176 SPEX(itssi_a, SSB_SPROM8_MAXP_A, SSB_SPROM8_ITSSI_A,
177 SSB_SPROM8_ITSSI_A_SHIFT);
178 + SPEX(maxpwr_ah, SSB_SPROM8_MAXP_AHL, SSB_SPROM8_MAXP_AH_MASK, 0);
179 + SPEX(maxpwr_al, SSB_SPROM8_MAXP_AHL, SSB_SPROM8_MAXP_AL_MASK,
180 + SSB_SPROM8_MAXP_AL_SHIFT);
181 SPEX(gpio0, SSB_SPROM8_GPIOA, SSB_SPROM8_GPIOA_P0, 0);
182 SPEX(gpio1, SSB_SPROM8_GPIOA, SSB_SPROM8_GPIOA_P1,
183 SSB_SPROM8_GPIOA_P1_SHIFT);
184 SPEX(gpio2, SSB_SPROM8_GPIOB, SSB_SPROM8_GPIOB_P2, 0);
185 SPEX(gpio3, SSB_SPROM8_GPIOB, SSB_SPROM8_GPIOB_P3,
186 SSB_SPROM8_GPIOB_P3_SHIFT);
187 + SPEX(tri2g, SSB_SPROM8_TRI25G, SSB_SPROM8_TRI2G, 0);
188 + SPEX(tri5g, SSB_SPROM8_TRI25G, SSB_SPROM8_TRI5G,
189 + SSB_SPROM8_TRI5G_SHIFT);
190 + SPEX(tri5gl, SSB_SPROM8_TRI5GHL, SSB_SPROM8_TRI5GL, 0);
191 + SPEX(tri5gh, SSB_SPROM8_TRI5GHL, SSB_SPROM8_TRI5GH,
192 + SSB_SPROM8_TRI5GH_SHIFT);
193 + SPEX(rxpo2g, SSB_SPROM8_RXPO, SSB_SPROM8_RXPO2G, 0);
194 + SPEX(rxpo5g, SSB_SPROM8_RXPO, SSB_SPROM8_RXPO5G,
195 + SSB_SPROM8_RXPO5G_SHIFT);
196 + SPEX(rssismf2g, SSB_SPROM8_RSSIPARM2G, SSB_SPROM8_RSSISMF2G, 0);
197 + SPEX(rssismc2g, SSB_SPROM8_RSSIPARM2G, SSB_SPROM8_RSSISMC2G,
198 + SSB_SPROM8_RSSISMC2G_SHIFT);
199 + SPEX(rssisav2g, SSB_SPROM8_RSSIPARM2G, SSB_SPROM8_RSSISAV2G,
200 + SSB_SPROM8_RSSISAV2G_SHIFT);
201 + SPEX(bxa2g, SSB_SPROM8_RSSIPARM2G, SSB_SPROM8_BXA2G,
202 + SSB_SPROM8_BXA2G_SHIFT);
203 + SPEX(rssismf5g, SSB_SPROM8_RSSIPARM5G, SSB_SPROM8_RSSISMF5G, 0);
204 + SPEX(rssismc5g, SSB_SPROM8_RSSIPARM5G, SSB_SPROM8_RSSISMC5G,
205 + SSB_SPROM8_RSSISMC5G_SHIFT);
206 + SPEX(rssisav5g, SSB_SPROM8_RSSIPARM5G, SSB_SPROM8_RSSISAV5G,
207 + SSB_SPROM8_RSSISAV5G_SHIFT);
208 + SPEX(bxa5g, SSB_SPROM8_RSSIPARM5G, SSB_SPROM8_BXA5G,
209 + SSB_SPROM8_BXA5G_SHIFT);
210 + SPEX(pa0b0, SSB_SPROM8_PA0B0, 0xFFFF, 0);
211 + SPEX(pa0b1, SSB_SPROM8_PA0B1, 0xFFFF, 0);
212 + SPEX(pa0b2, SSB_SPROM8_PA0B2, 0xFFFF, 0);
213 + SPEX(pa1b0, SSB_SPROM8_PA1B0, 0xFFFF, 0);
214 + SPEX(pa1b1, SSB_SPROM8_PA1B1, 0xFFFF, 0);
215 + SPEX(pa1b2, SSB_SPROM8_PA1B2, 0xFFFF, 0);
216 + SPEX(pa1lob0, SSB_SPROM8_PA1LOB0, 0xFFFF, 0);
217 + SPEX(pa1lob1, SSB_SPROM8_PA1LOB1, 0xFFFF, 0);
218 + SPEX(pa1lob2, SSB_SPROM8_PA1LOB2, 0xFFFF, 0);
219 + SPEX(pa1hib0, SSB_SPROM8_PA1HIB0, 0xFFFF, 0);
220 + SPEX(pa1hib1, SSB_SPROM8_PA1HIB1, 0xFFFF, 0);
221 + SPEX(pa1hib2, SSB_SPROM8_PA1HIB2, 0xFFFF, 0);
222 + SPEX(cck2gpo, SSB_SPROM8_CCK2GPO, 0xFFFF, 0);
223 + SPEX32(ofdm2gpo, SSB_SPROM8_OFDM2GPO, 0xFFFFFFFF, 0);
224 + SPEX32(ofdm5glpo, SSB_SPROM8_OFDM5GLPO, 0xFFFFFFFF, 0);
225 + SPEX32(ofdm5gpo, SSB_SPROM8_OFDM5GPO, 0xFFFFFFFF, 0);
226 + SPEX32(ofdm5ghpo, SSB_SPROM8_OFDM5GHPO, 0xFFFFFFFF, 0);
228 /* Extract the antenna gain values. */
229 SPEX(antenna_gain.ghz24.a0, SSB_SPROM8_AGAIN01,
230 @@ -549,6 +600,7 @@ static int sprom_extract(struct ssb_bus
231 ssb_printk(KERN_WARNING PFX "Unsupported SPROM"
232 " revision %d detected. Will extract"
233 " v1\n", out->revision);
235 sprom_extract_r123(out, in);
238 --- a/drivers/ssb/scan.c
239 +++ b/drivers/ssb/scan.c
240 @@ -175,6 +175,9 @@ static u32 scan_read32(struct ssb_bus *b
242 ssb_pcmcia_switch_segment(bus, 0);
244 + case SSB_BUSTYPE_SDIO:
245 + offset += current_coreidx * SSB_CORE_SIZE;
246 + return ssb_sdio_scan_read32(bus, offset);
248 return readl(bus->mmio + offset);
250 @@ -188,6 +191,8 @@ static int scan_switchcore(struct ssb_bu
251 return ssb_pci_switch_coreidx(bus, coreidx);
252 case SSB_BUSTYPE_PCMCIA:
253 return ssb_pcmcia_switch_coreidx(bus, coreidx);
254 + case SSB_BUSTYPE_SDIO:
259 @@ -206,6 +211,8 @@ void ssb_iounmap(struct ssb_bus *bus)
260 SSB_BUG_ON(1); /* Can't reach this code. */
263 + case SSB_BUSTYPE_SDIO:
267 bus->mapped_device = NULL;
268 @@ -230,6 +237,8 @@ static void __iomem *ssb_ioremap(struct
269 SSB_BUG_ON(1); /* Can't reach this code. */
272 + case SSB_BUSTYPE_SDIO:
277 --- a/include/linux/ssb/ssb.h
278 +++ b/include/linux/ssb/ssb.h
279 @@ -27,24 +27,54 @@ struct ssb_sprom {
280 u8 et1mdcport; /* MDIO for enet1 */
281 u8 board_rev; /* Board revision number from SPROM. */
282 u8 country_code; /* Country Code */
283 - u8 ant_available_a; /* A-PHY antenna available bits (up to 4) */
284 - u8 ant_available_bg; /* B/G-PHY antenna available bits (up to 4) */
285 + u8 ant_available_a; /* 2GHz antenna available bits (up to 4) */
286 + u8 ant_available_bg; /* 5GHz antenna available bits (up to 4) */
299 u8 gpio0; /* GPIO pin 0 */
300 u8 gpio1; /* GPIO pin 1 */
301 u8 gpio2; /* GPIO pin 2 */
302 u8 gpio3; /* GPIO pin 3 */
303 - u16 maxpwr_a; /* A-PHY Amplifier Max Power (in dBm Q5.2) */
304 - u16 maxpwr_bg; /* B/G-PHY Amplifier Max Power (in dBm Q5.2) */
305 + u16 maxpwr_bg; /* 2.4GHz Amplifier Max Power (in dBm Q5.2) */
306 + u16 maxpwr_al; /* 5.2GHz Amplifier Max Power (in dBm Q5.2) */
307 + u16 maxpwr_a; /* 5.3GHz Amplifier Max Power (in dBm Q5.2) */
308 + u16 maxpwr_ah; /* 5.8GHz Amplifier Max Power (in dBm Q5.2) */
309 u8 itssi_a; /* Idle TSSI Target for A-PHY */
310 u8 itssi_bg; /* Idle TSSI Target for B/G-PHY */
311 - u16 boardflags_lo; /* Boardflags (low 16 bits) */
312 - u16 boardflags_hi; /* Boardflags (high 16 bits) */
313 + u8 tri2g; /* 2.4GHz TX isolation */
314 + u8 tri5gl; /* 5.2GHz TX isolation */
315 + u8 tri5g; /* 5.3GHz TX isolation */
316 + u8 tri5gh; /* 5.8GHz TX isolation */
317 + u8 rxpo2g; /* 2GHz RX power offset */
318 + u8 rxpo5g; /* 5GHz RX power offset */
319 + u8 rssisav2g; /* 2GHz RSSI params */
322 + u8 bxa2g; /* 2GHz BX arch */
323 + u8 rssisav5g; /* 5GHz RSSI params */
326 + u8 bxa5g; /* 5GHz BX arch */
327 + u16 cck2gpo; /* CCK power offset */
328 + u32 ofdm2gpo; /* 2.4GHz OFDM power offset */
329 + u32 ofdm5glpo; /* 5.2GHz OFDM power offset */
330 + u32 ofdm5gpo; /* 5.3GHz OFDM power offset */
331 + u32 ofdm5ghpo; /* 5.8GHz OFDM power offset */
332 + u16 boardflags_lo; /* Board flags (bits 0-15) */
333 + u16 boardflags_hi; /* Board flags (bits 16-31) */
334 + u16 boardflags2_lo; /* Board flags (bits 32-47) */
335 + u16 boardflags2_hi; /* Board flags (bits 48-63) */
336 + /* TODO store board flags in a single u64 */
338 /* Antenna gain values for up to 4 antennas
339 * on each band. Values in dBm/4 (Q5.2). Negative gain means the
340 @@ -58,7 +88,7 @@ struct ssb_sprom {
341 } ghz5; /* 5GHz band */
344 - /* TODO - add any parameters needed from rev 2, 3, or 4 SPROMs */
345 + /* TODO - add any parameters needed from rev 2, 3, 4, 5 or 8 SPROMs */
348 /* Information about the PCB the circuitry is soldered on. */
349 @@ -208,6 +238,7 @@ enum ssb_bustype {
350 SSB_BUSTYPE_SSB, /* This SSB bus is the system bus */
351 SSB_BUSTYPE_PCI, /* SSB is connected to PCI bus */
352 SSB_BUSTYPE_PCMCIA, /* SSB is connected to PCMCIA bus */
353 + SSB_BUSTYPE_SDIO, /* SSB is connected to SDIO bus */
357 @@ -240,8 +271,12 @@ struct ssb_bus {
359 /* The core in the basic address register window. (PCI bus only) */
360 struct ssb_device *mapped_device;
361 - /* Currently mapped PCMCIA segment. (bustype == SSB_BUSTYPE_PCMCIA only) */
362 - u8 mapped_pcmcia_seg;
364 + /* Currently mapped PCMCIA segment. (bustype == SSB_BUSTYPE_PCMCIA only) */
365 + u8 mapped_pcmcia_seg;
366 + /* Current SSB base address window for SDIO. */
369 /* Lock for core and segment switching.
370 * On PCMCIA-host busses this is used to protect the whole MMIO access. */
372 @@ -252,6 +287,11 @@ struct ssb_bus {
373 struct pci_dev *host_pci;
374 /* Pointer to the PCMCIA device (only if bustype == SSB_BUSTYPE_PCMCIA). */
375 struct pcmcia_device *host_pcmcia;
376 + /* Pointer to the SDIO device (only if bustype == SSB_BUSTYPE_SDIO). */
377 + struct sdio_func *host_sdio;
379 + /* See enum ssb_quirks */
380 + unsigned int quirks;
382 #ifdef CONFIG_SSB_SPROM
383 /* Mutex to protect the SPROM writing. */
384 @@ -306,6 +346,11 @@ struct ssb_bus {
389 + /* SDIO connected card requires performing a read after writing a 32-bit value */
390 + SSB_QUIRK_SDIO_READ_AFTER_WRITE32 = (1 << 0),
393 /* The initialization-invariants. */
394 struct ssb_init_invariants {
395 /* Versioning information about the PCB. */
396 --- a/include/linux/ssb/ssb_driver_chipcommon.h
397 +++ b/include/linux/ssb/ssb_driver_chipcommon.h
398 @@ -629,5 +629,15 @@ extern int ssb_chipco_serial_init(struct
400 extern void ssb_pmu_init(struct ssb_chipcommon *cc);
402 +enum ssb_pmu_ldo_volt_id {
409 +void ssb_pmu_set_ldo_voltage(struct ssb_chipcommon *cc,
410 + enum ssb_pmu_ldo_volt_id id, u32 voltage);
411 +void ssb_pmu_set_ldo_paref(struct ssb_chipcommon *cc, bool on);
413 #endif /* LINUX_SSB_CHIPCO_H_ */
414 --- a/include/linux/ssb/ssb_regs.h
415 +++ b/include/linux/ssb/ssb_regs.h
418 /* SPROM shadow area. If not otherwise noted, fields are
419 * two bytes wide. Note that the SPROM can _only_ be read
420 - * in two-byte quantinies.
421 + * in two-byte quantities.
423 #define SSB_SPROMSIZE_WORDS 64
424 #define SSB_SPROMSIZE_BYTES (SSB_SPROMSIZE_WORDS * sizeof(u16))
426 #define SSB_SPROM5_GPIOB_P3_SHIFT 8
428 /* SPROM Revision 8 */
429 -#define SSB_SPROM8_BFLLO 0x1084 /* Boardflags (low 16 bits) */
430 -#define SSB_SPROM8_BFLHI 0x1086 /* Boardflags Hi */
431 +#define SSB_SPROM8_BOARDREV 0x1082 /* Board revision */
432 +#define SSB_SPROM8_BFLLO 0x1084 /* Board flags (bits 0-15) */
433 +#define SSB_SPROM8_BFLHI 0x1086 /* Board flags (bits 16-31) */
434 +#define SSB_SPROM8_BFL2LO 0x1088 /* Board flags (bits 32-47) */
435 +#define SSB_SPROM8_BFL2HI 0x108A /* Board flags (bits 48-63) */
436 #define SSB_SPROM8_IL0MAC 0x108C /* 6 byte MAC address */
437 #define SSB_SPROM8_CCODE 0x1092 /* 2 byte country code */
438 #define SSB_SPROM8_ANTAVAIL 0x109C /* Antenna available bitfields*/
439 @@ -354,14 +357,63 @@
440 #define SSB_SPROM8_GPIOB_P2 0x00FF /* Pin 2 */
441 #define SSB_SPROM8_GPIOB_P3 0xFF00 /* Pin 3 */
442 #define SSB_SPROM8_GPIOB_P3_SHIFT 8
443 -#define SSB_SPROM8_MAXP_BG 0x10C0 /* Max Power BG in path 1 */
444 -#define SSB_SPROM8_MAXP_BG_MASK 0x00FF /* Mask for Max Power BG */
445 +#define SSB_SPROM8_RSSIPARM2G 0x10A4 /* RSSI params for 2GHz */
446 +#define SSB_SPROM8_RSSISMF2G 0x000F
447 +#define SSB_SPROM8_RSSISMC2G 0x00F0
448 +#define SSB_SPROM8_RSSISMC2G_SHIFT 4
449 +#define SSB_SPROM8_RSSISAV2G 0x0700
450 +#define SSB_SPROM8_RSSISAV2G_SHIFT 8
451 +#define SSB_SPROM8_BXA2G 0x1800
452 +#define SSB_SPROM8_BXA2G_SHIFT 11
453 +#define SSB_SPROM8_RSSIPARM5G 0x10A6 /* RSSI params for 5GHz */
454 +#define SSB_SPROM8_RSSISMF5G 0x000F
455 +#define SSB_SPROM8_RSSISMC5G 0x00F0
456 +#define SSB_SPROM8_RSSISMC5G_SHIFT 4
457 +#define SSB_SPROM8_RSSISAV5G 0x0700
458 +#define SSB_SPROM8_RSSISAV5G_SHIFT 8
459 +#define SSB_SPROM8_BXA5G 0x1800
460 +#define SSB_SPROM8_BXA5G_SHIFT 11
461 +#define SSB_SPROM8_TRI25G 0x10A8 /* TX isolation 2.4&5.3GHz */
462 +#define SSB_SPROM8_TRI2G 0x00FF /* TX isolation 2.4GHz */
463 +#define SSB_SPROM8_TRI5G 0xFF00 /* TX isolation 5.3GHz */
464 +#define SSB_SPROM8_TRI5G_SHIFT 8
465 +#define SSB_SPROM8_TRI5GHL 0x10AA /* TX isolation 5.2/5.8GHz */
466 +#define SSB_SPROM8_TRI5GL 0x00FF /* TX isolation 5.2GHz */
467 +#define SSB_SPROM8_TRI5GH 0xFF00 /* TX isolation 5.8GHz */
468 +#define SSB_SPROM8_TRI5GH_SHIFT 8
469 +#define SSB_SPROM8_RXPO 0x10AC /* RX power offsets */
470 +#define SSB_SPROM8_RXPO2G 0x00FF /* 2GHz RX power offset */
471 +#define SSB_SPROM8_RXPO5G 0xFF00 /* 5GHz RX power offset */
472 +#define SSB_SPROM8_RXPO5G_SHIFT 8
473 +#define SSB_SPROM8_MAXP_BG 0x10C0 /* Max Power 2GHz in path 1 */
474 +#define SSB_SPROM8_MAXP_BG_MASK 0x00FF /* Mask for Max Power 2GHz */
475 #define SSB_SPROM8_ITSSI_BG 0xFF00 /* Mask for path 1 itssi_bg */
476 #define SSB_SPROM8_ITSSI_BG_SHIFT 8
477 -#define SSB_SPROM8_MAXP_A 0x10C8 /* Max Power A in path 1 */
478 -#define SSB_SPROM8_MAXP_A_MASK 0x00FF /* Mask for Max Power A */
479 +#define SSB_SPROM8_PA0B0 0x10C2 /* 2GHz power amp settings */
480 +#define SSB_SPROM8_PA0B1 0x10C4
481 +#define SSB_SPROM8_PA0B2 0x10C6
482 +#define SSB_SPROM8_MAXP_A 0x10C8 /* Max Power 5.3GHz */
483 +#define SSB_SPROM8_MAXP_A_MASK 0x00FF /* Mask for Max Power 5.3GHz */
484 #define SSB_SPROM8_ITSSI_A 0xFF00 /* Mask for path 1 itssi_a */
485 #define SSB_SPROM8_ITSSI_A_SHIFT 8
486 +#define SSB_SPROM8_MAXP_AHL 0x10CA /* Max Power 5.2/5.8GHz */
487 +#define SSB_SPROM8_MAXP_AH_MASK 0x00FF /* Mask for Max Power 5.8GHz */
488 +#define SSB_SPROM8_MAXP_AL_MASK 0xFF00 /* Mask for Max Power 5.2GHz */
489 +#define SSB_SPROM8_MAXP_AL_SHIFT 8
490 +#define SSB_SPROM8_PA1B0 0x10CC /* 5.3GHz power amp settings */
491 +#define SSB_SPROM8_PA1B1 0x10CE
492 +#define SSB_SPROM8_PA1B2 0x10D0
493 +#define SSB_SPROM8_PA1LOB0 0x10D2 /* 5.2GHz power amp settings */
494 +#define SSB_SPROM8_PA1LOB1 0x10D4
495 +#define SSB_SPROM8_PA1LOB2 0x10D6
496 +#define SSB_SPROM8_PA1HIB0 0x10D8 /* 5.8GHz power amp settings */
497 +#define SSB_SPROM8_PA1HIB1 0x10DA
498 +#define SSB_SPROM8_PA1HIB2 0x10DC
499 +#define SSB_SPROM8_CCK2GPO 0x1140 /* CCK power offset */
500 +#define SSB_SPROM8_OFDM2GPO 0x1142 /* 2.4GHz OFDM power offset */
501 +#define SSB_SPROM8_OFDM5GPO 0x1146 /* 5.3GHz OFDM power offset */
502 +#define SSB_SPROM8_OFDM5GLPO 0x114A /* 5.2GHz OFDM power offset */
503 +#define SSB_SPROM8_OFDM5GHPO 0x114E /* 5.8GHz OFDM power offset */
505 /* Values for SSB_SPROM1_BINF_CCODE */