Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
[pandora-kernel.git] / drivers / net / wireless / p54 / p54common.h
1 #ifndef P54COMMON_H
2 #define P54COMMON_H
3
4 /*
5  * Common code specific definitions for mac80211 Prism54 drivers
6  *
7  * Copyright (c) 2006, Michael Wu <flamingice@sourmilk.net>
8  * Copyright (c) 2007, Christian Lamparter <chunkeey@web.de>
9  *
10  * Based on:
11  * - the islsm (softmac prism54) driver, which is:
12  *   Copyright 2004-2006 Jean-Baptiste Note <jbnote@gmail.com>, et al.
13  *
14  * - LMAC API interface header file for STLC4560 (lmac_longbow.h)
15  *   Copyright (C) 2007 Conexant Systems, Inc.
16  *
17  * This program is free software; you can redistribute it and/or modify
18  * it under the terms of the GNU General Public License version 2 as
19  * published by the Free Software Foundation.
20  */
21
22 struct bootrec {
23         __le32 code;
24         __le32 len;
25         u32 data[10];
26 } __attribute__((packed));
27
28 #define PDR_SYNTH_FRONTEND_MASK         0x0007
29 #define PDR_SYNTH_FRONTEND_DUETTE3      0x0001
30 #define PDR_SYNTH_FRONTEND_DUETTE2      0x0002
31 #define PDR_SYNTH_FRONTEND_FRISBEE      0x0003
32 #define PDR_SYNTH_FRONTEND_XBOW         0x0004
33 #define PDR_SYNTH_FRONTEND_LONGBOW      0x0005
34 #define PDR_SYNTH_IQ_CAL_MASK           0x0018
35 #define PDR_SYNTH_IQ_CAL_PA_DETECTOR    0x0000
36 #define PDR_SYNTH_IQ_CAL_DISABLED       0x0008
37 #define PDR_SYNTH_IQ_CAL_ZIF            0x0010
38 #define PDR_SYNTH_FAA_SWITCH_MASK       0x0020
39 #define PDR_SYNTH_FAA_SWITCH_ENABLED    0x0020
40 #define PDR_SYNTH_24_GHZ_MASK           0x0040
41 #define PDR_SYNTH_24_GHZ_DISABLED       0x0040
42 #define PDR_SYNTH_5_GHZ_MASK            0x0080
43 #define PDR_SYNTH_5_GHZ_DISABLED        0x0080
44 #define PDR_SYNTH_RX_DIV_MASK           0x0100
45 #define PDR_SYNTH_RX_DIV_SUPPORTED      0x0100
46 #define PDR_SYNTH_TX_DIV_MASK           0x0200
47 #define PDR_SYNTH_TX_DIV_SUPPORTED      0x0200
48
49 struct bootrec_exp_if {
50         __le16 role;
51         __le16 if_id;
52         __le16 variant;
53         __le16 btm_compat;
54         __le16 top_compat;
55 } __attribute__((packed));
56
57 #define BR_DESC_PRIV_CAP_WEP            BIT(0)
58 #define BR_DESC_PRIV_CAP_TKIP           BIT(1)
59 #define BR_DESC_PRIV_CAP_MICHAEL        BIT(2)
60 #define BR_DESC_PRIV_CAP_CCX_CP         BIT(3)
61 #define BR_DESC_PRIV_CAP_CCX_MIC        BIT(4)
62 #define BR_DESC_PRIV_CAP_AESCCMP        BIT(5)
63
64 struct bootrec_desc {
65         __le16 modes;
66         __le16 flags;
67         __le32 rx_start;
68         __le32 rx_end;
69         u8 headroom;
70         u8 tailroom;
71         u8 tx_queues;
72         u8 tx_depth;
73         u8 privacy_caps;
74         u8 rx_keycache_size;
75         u8 time_size;
76         u8 padding;
77         u8 rates[16];
78         u8 padding2[4];
79         __le16 rx_mtu;
80 } __attribute__((packed));
81
82 #define BR_CODE_MIN                     0x80000000
83 #define BR_CODE_COMPONENT_ID            0x80000001
84 #define BR_CODE_COMPONENT_VERSION       0x80000002
85 #define BR_CODE_DEPENDENT_IF            0x80000003
86 #define BR_CODE_EXPOSED_IF              0x80000004
87 #define BR_CODE_DESCR                   0x80000101
88 #define BR_CODE_MAX                     0x8FFFFFFF
89 #define BR_CODE_END_OF_BRA              0xFF0000FF
90 #define LEGACY_BR_CODE_END_OF_BRA       0xFFFFFFFF
91
92 #define P54_HDR_FLAG_DATA_ALIGN         BIT(14)
93 #define P54_HDR_FLAG_DATA_OUT_PROMISC   BIT(0)
94 #define P54_HDR_FLAG_DATA_OUT_TIMESTAMP BIT(1)
95 #define P54_HDR_FLAG_DATA_OUT_SEQNR     BIT(2)
96 #define P54_HDR_FLAG_DATA_OUT_BIT3      BIT(3)
97 #define P54_HDR_FLAG_DATA_OUT_BURST     BIT(4)
98 #define P54_HDR_FLAG_DATA_OUT_NOCANCEL  BIT(5)
99 #define P54_HDR_FLAG_DATA_OUT_CLEARTIM  BIT(6)
100 #define P54_HDR_FLAG_DATA_OUT_HITCHHIKE BIT(7)
101 #define P54_HDR_FLAG_DATA_OUT_COMPRESS  BIT(8)
102 #define P54_HDR_FLAG_DATA_OUT_CONCAT    BIT(9)
103 #define P54_HDR_FLAG_DATA_OUT_PCS_ACCEPT BIT(10)
104 #define P54_HDR_FLAG_DATA_OUT_WAITEOSP  BIT(11)
105
106 #define P54_HDR_FLAG_DATA_IN_FCS_GOOD   BIT(0)
107 #define P54_HDR_FLAG_DATA_IN_MATCH_MAC  BIT(1)
108 #define P54_HDR_FLAG_DATA_IN_MCBC       BIT(2)
109 #define P54_HDR_FLAG_DATA_IN_BEACON     BIT(3)
110 #define P54_HDR_FLAG_DATA_IN_MATCH_BSS  BIT(4)
111 #define P54_HDR_FLAG_DATA_IN_BCAST_BSS  BIT(5)
112 #define P54_HDR_FLAG_DATA_IN_DATA       BIT(6)
113 #define P54_HDR_FLAG_DATA_IN_TRUNCATED  BIT(7)
114 #define P54_HDR_FLAG_DATA_IN_BIT8       BIT(8)
115 #define P54_HDR_FLAG_DATA_IN_TRANSPARENT BIT(9)
116
117 /* PDA defines are Copyright (C) 2005 Nokia Corporation (taken from islsm_pda.h) */
118
119 struct pda_entry {
120         __le16 len;     /* includes both code and data */
121         __le16 code;
122         u8 data[0];
123 } __attribute__ ((packed));
124
125 struct eeprom_pda_wrap {
126         __le32 magic;
127         __le16 pad;
128         __le16 len;
129         __le32 arm_opcode;
130         u8 data[0];
131 } __attribute__ ((packed));
132
133 struct p54_iq_autocal_entry {
134         __le16 iq_param[4];
135 } __attribute__ ((packed));
136
137 struct pda_iq_autocal_entry {
138         __le16 freq;
139         struct p54_iq_autocal_entry params;
140 } __attribute__ ((packed));
141
142 struct pda_channel_output_limit {
143         __le16 freq;
144         u8 val_bpsk;
145         u8 val_qpsk;
146         u8 val_16qam;
147         u8 val_64qam;
148         u8 rate_set_mask;
149         u8 rate_set_size;
150 } __attribute__ ((packed));
151
152 struct pda_pa_curve_data_sample_rev0 {
153         u8 rf_power;
154         u8 pa_detector;
155         u8 pcv;
156 } __attribute__ ((packed));
157
158 struct pda_pa_curve_data_sample_rev1 {
159         u8 rf_power;
160         u8 pa_detector;
161         u8 data_barker;
162         u8 data_bpsk;
163         u8 data_qpsk;
164         u8 data_16qam;
165         u8 data_64qam;
166 } __attribute__ ((packed));
167
168 struct p54_pa_curve_data_sample {
169         u8 rf_power;
170         u8 pa_detector;
171         u8 data_barker;
172         u8 data_bpsk;
173         u8 data_qpsk;
174         u8 data_16qam;
175         u8 data_64qam;
176         u8 padding;
177 } __attribute__ ((packed));
178
179 struct pda_pa_curve_data {
180         u8 cal_method_rev;
181         u8 channels;
182         u8 points_per_channel;
183         u8 padding;
184         u8 data[0];
185 } __attribute__ ((packed));
186
187 struct pda_rssi_cal_entry {
188         __le16 mul;
189         __le16 add;
190 } __attribute__ ((packed));
191
192 struct pda_country {
193         u8 regdomain;
194         u8 alpha2[2];
195         u8 flags;
196 } __attribute__ ((packed));
197
198 /*
199  * Warning: Longbow's structures are bogus.
200  */
201 struct p54_channel_output_limit_longbow {
202         __le16 rf_power_points[12];
203 } __attribute__ ((packed));
204
205 struct p54_pa_curve_data_sample_longbow {
206         __le16 rf_power;
207         __le16 pa_detector;
208         struct {
209                 __le16 data[4];
210         } points[3] __attribute__ ((packed));
211 } __attribute__ ((packed));
212
213 struct pda_custom_wrapper {
214         __le16 entries;
215         __le16 entry_size;
216         __le16 offset;
217         __le16 len;
218         u8 data[0];
219 } __attribute__ ((packed));
220
221 /*
222  * this defines the PDR codes used to build PDAs as defined in document
223  * number 553155. The current implementation mirrors version 1.1 of the
224  * document and lists only PDRs supported by the ARM platform.
225  */
226
227 /* common and choice range (0x0000 - 0x0fff) */
228 #define PDR_END                                 0x0000
229 #define PDR_MANUFACTURING_PART_NUMBER           0x0001
230 #define PDR_PDA_VERSION                         0x0002
231 #define PDR_NIC_SERIAL_NUMBER                   0x0003
232
233 #define PDR_MAC_ADDRESS                         0x0101
234 #define PDR_REGULATORY_DOMAIN_LIST              0x0103
235 #define PDR_TEMPERATURE_TYPE                    0x0107
236
237 #define PDR_PRISM_PCI_IDENTIFIER                0x0402
238
239 /* ARM range (0x1000 - 0x1fff) */
240 #define PDR_COUNTRY_INFORMATION                 0x1000
241 #define PDR_INTERFACE_LIST                      0x1001
242 #define PDR_HARDWARE_PLATFORM_COMPONENT_ID      0x1002
243 #define PDR_OEM_NAME                            0x1003
244 #define PDR_PRODUCT_NAME                        0x1004
245 #define PDR_UTF8_OEM_NAME                       0x1005
246 #define PDR_UTF8_PRODUCT_NAME                   0x1006
247 #define PDR_COUNTRY_LIST                        0x1007
248 #define PDR_DEFAULT_COUNTRY                     0x1008
249
250 #define PDR_ANTENNA_GAIN                        0x1100
251
252 #define PDR_PRISM_INDIGO_PA_CALIBRATION_DATA    0x1901
253 #define PDR_RSSI_LINEAR_APPROXIMATION           0x1902
254 #define PDR_PRISM_PA_CAL_OUTPUT_POWER_LIMITS    0x1903
255 #define PDR_PRISM_PA_CAL_CURVE_DATA             0x1904
256 #define PDR_RSSI_LINEAR_APPROXIMATION_DUAL_BAND 0x1905
257 #define PDR_PRISM_ZIF_TX_IQ_CALIBRATION         0x1906
258 #define PDR_REGULATORY_POWER_LIMITS             0x1907
259 #define PDR_RSSI_LINEAR_APPROXIMATION_EXTENDED  0x1908
260 #define PDR_RADIATED_TRANSMISSION_CORRECTION    0x1909
261 #define PDR_PRISM_TX_IQ_CALIBRATION             0x190a
262
263 /* reserved range (0x2000 - 0x7fff) */
264
265 /* customer range (0x8000 - 0xffff) */
266 #define PDR_BASEBAND_REGISTERS                          0x8000
267 #define PDR_PER_CHANNEL_BASEBAND_REGISTERS              0x8001
268
269 /* used by our modificated eeprom image */
270 #define PDR_RSSI_LINEAR_APPROXIMATION_CUSTOM            0xDEAD
271 #define PDR_PRISM_PA_CAL_OUTPUT_POWER_LIMITS_CUSTOM     0xBEEF
272 #define PDR_PRISM_PA_CAL_CURVE_DATA_CUSTOM              0xB05D
273
274 /* PDR definitions for default country & country list */
275 #define PDR_COUNTRY_CERT_CODE           0x80
276 #define PDR_COUNTRY_CERT_CODE_REAL      0x00
277 #define PDR_COUNTRY_CERT_CODE_PSEUDO    0x80
278 #define PDR_COUNTRY_CERT_BAND           0x40
279 #define PDR_COUNTRY_CERT_BAND_2GHZ      0x00
280 #define PDR_COUNTRY_CERT_BAND_5GHZ      0x40
281 #define PDR_COUNTRY_CERT_IODOOR         0x30
282 #define PDR_COUNTRY_CERT_IODOOR_BOTH    0x00
283 #define PDR_COUNTRY_CERT_IODOOR_INDOOR  0x20
284 #define PDR_COUNTRY_CERT_IODOOR_OUTDOOR 0x30
285 #define PDR_COUNTRY_CERT_INDEX          0x0F
286
287 struct p54_eeprom_lm86 {
288         union {
289                 struct {
290                         __le16 offset;
291                         __le16 len;
292                         u8 data[0];
293                 } v1;
294                 struct {
295                         __le32 offset;
296                         __le16 len;
297                         u8 magic2;
298                         u8 pad;
299                         u8 magic[4];
300                         u8 data[0];
301                 } v2;
302         }  __attribute__ ((packed));
303 } __attribute__ ((packed));
304
305 enum p54_rx_decrypt_status {
306         P54_DECRYPT_NONE = 0,
307         P54_DECRYPT_OK,
308         P54_DECRYPT_NOKEY,
309         P54_DECRYPT_NOMICHAEL,
310         P54_DECRYPT_NOCKIPMIC,
311         P54_DECRYPT_FAIL_WEP,
312         P54_DECRYPT_FAIL_TKIP,
313         P54_DECRYPT_FAIL_MICHAEL,
314         P54_DECRYPT_FAIL_CKIPKP,
315         P54_DECRYPT_FAIL_CKIPMIC,
316         P54_DECRYPT_FAIL_AESCCMP
317 };
318
319 struct p54_rx_data {
320         __le16 flags;
321         __le16 len;
322         __le16 freq;
323         u8 antenna;
324         u8 rate;
325         u8 rssi;
326         u8 quality;
327         u8 decrypt_status;
328         u8 rssi_raw;
329         __le32 tsf32;
330         __le32 unalloc0;
331         u8 align[0];
332 } __attribute__ ((packed));
333
334 enum p54_trap_type {
335         P54_TRAP_SCAN = 0,
336         P54_TRAP_TIMER,
337         P54_TRAP_BEACON_TX,
338         P54_TRAP_FAA_RADIO_ON,
339         P54_TRAP_FAA_RADIO_OFF,
340         P54_TRAP_RADAR,
341         P54_TRAP_NO_BEACON,
342         P54_TRAP_TBTT,
343         P54_TRAP_SCO_ENTER,
344         P54_TRAP_SCO_EXIT
345 };
346
347 struct p54_trap {
348         __le16 event;
349         __le16 frequency;
350 } __attribute__ ((packed));
351
352 enum p54_frame_sent_status {
353         P54_TX_OK = 0,
354         P54_TX_FAILED,
355         P54_TX_PSM,
356         P54_TX_PSM_CANCELLED = 4
357 };
358
359 struct p54_frame_sent {
360         u8 status;
361         u8 tries;
362         u8 ack_rssi;
363         u8 quality;
364         __le16 seq;
365         u8 antenna;
366         u8 padding;
367 } __attribute__ ((packed));
368
369 enum p54_tx_data_crypt {
370         P54_CRYPTO_NONE = 0,
371         P54_CRYPTO_WEP,
372         P54_CRYPTO_TKIP,
373         P54_CRYPTO_TKIPMICHAEL,
374         P54_CRYPTO_CCX_WEPMIC,
375         P54_CRYPTO_CCX_KPMIC,
376         P54_CRYPTO_CCX_KP,
377         P54_CRYPTO_AESCCMP
378 };
379
380 enum p54_tx_data_queue {
381         P54_QUEUE_BEACON        = 0,
382         P54_QUEUE_FWSCAN        = 1,
383         P54_QUEUE_MGMT          = 2,
384         P54_QUEUE_CAB           = 3,
385         P54_QUEUE_DATA          = 4,
386
387         P54_QUEUE_AC_NUM        = 4,
388         P54_QUEUE_AC_VO         = 4,
389         P54_QUEUE_AC_VI         = 5,
390         P54_QUEUE_AC_BE         = 6,
391         P54_QUEUE_AC_BK         = 7,
392
393         /* keep last */
394         P54_QUEUE_NUM           = 8,
395 };
396
397 struct p54_tx_data {
398         u8 rateset[8];
399         u8 rts_rate_idx;
400         u8 crypt_offset;
401         u8 key_type;
402         u8 key_len;
403         u8 key[16];
404         u8 hw_queue;
405         u8 backlog;
406         __le16 durations[4];
407         u8 tx_antenna;
408         union {
409                 struct {
410                         u8 cts_rate;
411                         __le16 output_power;
412                 } __attribute__((packed)) longbow;
413                 struct {
414                         u8 output_power;
415                         u8 cts_rate;
416                         u8 unalloc;
417                 } __attribute__ ((packed)) normal;
418         } __attribute__ ((packed));
419         u8 unalloc2[2];
420         u8 align[0];
421 } __attribute__ ((packed));
422
423 /* unit is ms */
424 #define P54_TX_FRAME_LIFETIME 2000
425 #define P54_TX_TIMEOUT 4000
426 #define P54_STATISTICS_UPDATE 5000
427
428 #define P54_FILTER_TYPE_NONE            0
429 #define P54_FILTER_TYPE_STATION         BIT(0)
430 #define P54_FILTER_TYPE_IBSS            BIT(1)
431 #define P54_FILTER_TYPE_AP              BIT(2)
432 #define P54_FILTER_TYPE_TRANSPARENT     BIT(3)
433 #define P54_FILTER_TYPE_PROMISCUOUS     BIT(4)
434 #define P54_FILTER_TYPE_HIBERNATE       BIT(5)
435 #define P54_FILTER_TYPE_NOACK           BIT(6)
436 #define P54_FILTER_TYPE_RX_DISABLED     BIT(7)
437
438 struct p54_setup_mac {
439         __le16 mac_mode;
440         u8 mac_addr[ETH_ALEN];
441         u8 bssid[ETH_ALEN];
442         u8 rx_antenna;
443         u8 rx_align;
444         union {
445                 struct {
446                         __le32 basic_rate_mask;
447                         u8 rts_rates[8];
448                         __le32 rx_addr;
449                         __le16 max_rx;
450                         __le16 rxhw;
451                         __le16 wakeup_timer;
452                         __le16 unalloc0;
453                 } v1 __attribute__ ((packed));
454                 struct {
455                         __le32 rx_addr;
456                         __le16 max_rx;
457                         __le16 rxhw;
458                         __le16 timer;
459                         __le16 truncate;
460                         __le32 basic_rate_mask;
461                         u8 sbss_offset;
462                         u8 mcast_window;
463                         u8 rx_rssi_threshold;
464                         u8 rx_ed_threshold;
465                         __le32 ref_clock;
466                         __le16 lpf_bandwidth;
467                         __le16 osc_start_delay;
468                 } v2 __attribute__ ((packed));
469         } __attribute__ ((packed));
470 } __attribute__ ((packed));
471
472 #define P54_SETUP_V1_LEN 40
473 #define P54_SETUP_V2_LEN (sizeof(struct p54_setup_mac))
474
475 #define P54_SCAN_EXIT   BIT(0)
476 #define P54_SCAN_TRAP   BIT(1)
477 #define P54_SCAN_ACTIVE BIT(2)
478 #define P54_SCAN_FILTER BIT(3)
479
480 struct p54_scan_head {
481         __le16 mode;
482         __le16 dwell;
483         u8 scan_params[20];
484         __le16 freq;
485 } __attribute__ ((packed));
486
487 struct p54_scan_body {
488         u8 pa_points_per_curve;
489         u8 val_barker;
490         u8 val_bpsk;
491         u8 val_qpsk;
492         u8 val_16qam;
493         u8 val_64qam;
494         struct p54_pa_curve_data_sample curve_data[8];
495         u8 dup_bpsk;
496         u8 dup_qpsk;
497         u8 dup_16qam;
498         u8 dup_64qam;
499 } __attribute__ ((packed));
500
501 struct p54_scan_body_longbow {
502         struct p54_channel_output_limit_longbow power_limits;
503         struct p54_pa_curve_data_sample_longbow curve_data[8];
504         __le16 unkn[6];         /* maybe more power_limits or rate_mask */
505 } __attribute__ ((packed));
506
507 union p54_scan_body_union {
508         struct p54_scan_body normal;
509         struct p54_scan_body_longbow longbow;
510 } __attribute__ ((packed));
511
512 struct p54_scan_tail_rate {
513         __le32 basic_rate_mask;
514         u8 rts_rates[8];
515 } __attribute__ ((packed));
516
517 struct p54_led {
518         __le16 flags;
519         __le16 mask[2];
520         __le16 delay[2];
521 } __attribute__ ((packed));
522
523 struct p54_edcf {
524         u8 flags;
525         u8 slottime;
526         u8 sifs;
527         u8 eofpad;
528         struct p54_edcf_queue_param queue[8];
529         u8 mapping[4];
530         __le16 frameburst;
531         __le16 round_trip_delay;
532 } __attribute__ ((packed));
533
534 struct p54_statistics {
535         __le32 rx_success;
536         __le32 rx_bad_fcs;
537         __le32 rx_abort;
538         __le32 rx_abort_phy;
539         __le32 rts_success;
540         __le32 rts_fail;
541         __le32 tsf32;
542         __le32 airtime;
543         __le32 noise;
544         __le32 sample_noise[8];
545         __le32 sample_cca;
546         __le32 sample_tx;
547 } __attribute__ ((packed));
548
549 struct p54_xbow_synth {
550         __le16 magic1;
551         __le16 magic2;
552         __le16 freq;
553         u32 padding[5];
554 } __attribute__ ((packed));
555
556 struct p54_timer {
557         __le32 interval;
558 } __attribute__ ((packed));
559
560 struct p54_keycache {
561         u8 entry;
562         u8 key_id;
563         u8 mac[ETH_ALEN];
564         u8 padding[2];
565         u8 key_type;
566         u8 key_len;
567         u8 key[24];
568 } __attribute__ ((packed));
569
570 struct p54_burst {
571         u8 flags;
572         u8 queue;
573         u8 backlog;
574         u8 pad;
575         __le16 durations[32];
576 } __attribute__ ((packed));
577
578 struct p54_psm_interval {
579         __le16 interval;
580         __le16 periods;
581 } __attribute__ ((packed));
582
583 #define P54_PSM_CAM                     0
584 #define P54_PSM                         BIT(0)
585 #define P54_PSM_DTIM                    BIT(1)
586 #define P54_PSM_MCBC                    BIT(2)
587 #define P54_PSM_CHECKSUM                BIT(3)
588 #define P54_PSM_SKIP_MORE_DATA          BIT(4)
589 #define P54_PSM_BEACON_TIMEOUT          BIT(5)
590 #define P54_PSM_HFOSLEEP                BIT(6)
591 #define P54_PSM_AUTOSWITCH_SLEEP        BIT(7)
592 #define P54_PSM_LPIT                    BIT(8)
593 #define P54_PSM_BF_UCAST_SKIP           BIT(9)
594 #define P54_PSM_BF_MCAST_SKIP           BIT(10)
595
596 struct p54_psm {
597         __le16 mode;
598         __le16 aid;
599         struct p54_psm_interval intervals[4];
600         u8 beacon_rssi_skip_max;
601         u8 rssi_delta_threshold;
602         u8 nr;
603         u8 exclude[1];
604 } __attribute__ ((packed));
605
606 #define MC_FILTER_ADDRESS_NUM 4
607
608 struct p54_group_address_table {
609         __le16 filter_enable;
610         __le16 num_address;
611         u8 mac_list[MC_FILTER_ADDRESS_NUM][ETH_ALEN];
612 } __attribute__ ((packed));
613
614 struct p54_txcancel {
615         __le32 req_id;
616 } __attribute__ ((packed));
617
618 struct p54_sta_unlock {
619         u8 addr[ETH_ALEN];
620         u16 padding;
621 } __attribute__ ((packed));
622
623 #define P54_TIM_CLEAR BIT(15)
624 struct p54_tim {
625         u8 count;
626         u8 padding[3];
627         __le16 entry[8];
628 } __attribute__ ((packed));
629
630 struct p54_cce_quiet {
631         __le32 period;
632 } __attribute__ ((packed));
633
634 struct p54_bt_balancer {
635         __le16 prio_thresh;
636         __le16 acl_thresh;
637 } __attribute__ ((packed));
638
639 struct p54_arp_table {
640         __le16 filter_enable;
641         u8 ipv4_addr[4];
642 } __attribute__ ((packed));
643
644 #endif /* P54COMMON_H */