sunxi: improve A20 Lime2 upload speed
[openwrt/staging/lynxis.git] / package / kernel / mac80211 / patches / 020-08-rt2x00-rt2800lib-move-rt2800_drv_data-declaration-in.patch
1 From 96609f366c6f792421e1939c5c834abbe24eb88a Mon Sep 17 00:00:00 2001
2 From: Gabor Juhos <juhosg@openwrt.org>
3 Date: Wed, 15 Feb 2017 10:25:04 +0100
4 Subject: [PATCH 08/19] rt2x00: rt2800lib: move rt2800_drv_data declaration
5 into rt2800lib.h
6
7 The rt2800_drv_data structure contains driver specific
8 information. Move the declaration into the rt2800lib.h
9 header which is a more logical place for it. Also fix
10 the comment style to avoid checkpatch warning.
11
12 The patch contains no functional changes, it is in
13 preparation for the next patch.
14
15 Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
16 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
17 Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
18 Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
19 ---
20 drivers/net/wireless/ralink/rt2x00/rt2800.h | 25 -------------------------
21 drivers/net/wireless/ralink/rt2x00/rt2800lib.h | 23 +++++++++++++++++++++++
22 2 files changed, 23 insertions(+), 25 deletions(-)
23
24 --- a/drivers/net/wireless/ralink/rt2x00/rt2800.h
25 +++ b/drivers/net/wireless/ralink/rt2x00/rt2800.h
26 @@ -2987,29 +2987,4 @@ enum rt2800_eeprom_word {
27 */
28 #define BCN_TBTT_OFFSET 64
29
30 -/*
31 - * Hardware has 255 WCID table entries. First 32 entries are reserved for
32 - * shared keys. Since parts of the pairwise key table might be shared with
33 - * the beacon frame buffers 6 & 7 we could only use the first 222 entries.
34 - */
35 -#define WCID_START 33
36 -#define WCID_END 222
37 -#define STA_IDS_SIZE (WCID_END - WCID_START + 2)
38 -
39 -/*
40 - * RT2800 driver data structure
41 - */
42 -struct rt2800_drv_data {
43 - u8 calibration_bw20;
44 - u8 calibration_bw40;
45 - u8 bbp25;
46 - u8 bbp26;
47 - u8 txmixer_gain_24g;
48 - u8 txmixer_gain_5g;
49 - u8 max_psdu;
50 - unsigned int tbtt_tick;
51 - unsigned int ampdu_factor_cnt[4];
52 - DECLARE_BITMAP(sta_ids, STA_IDS_SIZE);
53 -};
54 -
55 #endif /* RT2800_H */
56 --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.h
57 +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.h
58 @@ -20,6 +20,29 @@
59 #ifndef RT2800LIB_H
60 #define RT2800LIB_H
61
62 +/*
63 + * Hardware has 255 WCID table entries. First 32 entries are reserved for
64 + * shared keys. Since parts of the pairwise key table might be shared with
65 + * the beacon frame buffers 6 & 7 we could only use the first 222 entries.
66 + */
67 +#define WCID_START 33
68 +#define WCID_END 222
69 +#define STA_IDS_SIZE (WCID_END - WCID_START + 2)
70 +
71 +/* RT2800 driver data structure */
72 +struct rt2800_drv_data {
73 + u8 calibration_bw20;
74 + u8 calibration_bw40;
75 + u8 bbp25;
76 + u8 bbp26;
77 + u8 txmixer_gain_24g;
78 + u8 txmixer_gain_5g;
79 + u8 max_psdu;
80 + unsigned int tbtt_tick;
81 + unsigned int ampdu_factor_cnt[4];
82 + DECLARE_BITMAP(sta_ids, STA_IDS_SIZE);
83 +};
84 +
85 struct rt2800_ops {
86 void (*register_read)(struct rt2x00_dev *rt2x00dev,
87 const unsigned int offset, u32 *value);