aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/p54/p54common.h
diff options
context:
space:
mode:
authorChristian Lamparter <chunkeey@web.de>2008-08-23 16:15:25 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-08-29 16:24:08 -0400
commit154e3af17fdce617605b63f3534dac2c10c90922 (patch)
tree48331503716ff5a5f1848237017d06c808f80a18 /drivers/net/wireless/p54/p54common.h
parenta3ec233c90f0b8a5c00bf182f2c3ea9119b46caa (diff)
p54: fix rssi auto calibration
Ever wondered why the signal was so bad with p54 compared to madwifi, or intel? Well, if you have revision 1 rssi calibration curve points in your EEPROM, then wonder no more. The firmware wants a extra 1 byte padding for every curve point. But someone forgot to put them into the EEPROM's data structure... So now, big question: what happens when we blindly "memcpy" these data points? Signed-off-by: Christian Lamparter <chunkeey@web.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/p54/p54common.h')
-rw-r--r--drivers/net/wireless/p54/p54common.h23
1 files changed, 19 insertions, 4 deletions
diff --git a/drivers/net/wireless/p54/p54common.h b/drivers/net/wireless/p54/p54common.h
index 9bc2a1cf4b57..a79c1a146917 100644
--- a/drivers/net/wireless/p54/p54common.h
+++ b/drivers/net/wireless/p54/p54common.h
@@ -89,6 +89,16 @@ struct pda_pa_curve_data_sample_rev1 {
89 u8 data_qpsk; 89 u8 data_qpsk;
90 u8 data_16qam; 90 u8 data_16qam;
91 u8 data_64qam; 91 u8 data_64qam;
92} __attribute__ ((packed));
93
94struct p54_pa_curve_data_sample {
95 u8 rf_power;
96 u8 pa_detector;
97 u8 data_barker;
98 u8 data_bpsk;
99 u8 data_qpsk;
100 u8 data_16qam;
101 u8 data_64qam;
92 u8 padding; 102 u8 padding;
93} __attribute__ ((packed)); 103} __attribute__ ((packed));
94 104
@@ -212,8 +222,8 @@ struct p54_tx_control_filter {
212} __attribute__ ((packed)); 222} __attribute__ ((packed));
213 223
214struct p54_tx_control_channel { 224struct p54_tx_control_channel {
215 __le16 magic1; 225 __le16 flags;
216 __le16 magic2; 226 __le16 dwell;
217 u8 padding1[20]; 227 u8 padding1[20];
218 struct pda_iq_autocal_entry iq_autocal; 228 struct pda_iq_autocal_entry iq_autocal;
219 u8 pa_points_per_curve; 229 u8 pa_points_per_curve;
@@ -222,8 +232,13 @@ struct p54_tx_control_channel {
222 u8 val_qpsk; 232 u8 val_qpsk;
223 u8 val_16qam; 233 u8 val_16qam;
224 u8 val_64qam; 234 u8 val_64qam;
225 struct pda_pa_curve_data_sample_rev1 curve_data[0]; 235 struct pda_pa_curve_data_sample_rev1 curve_data[8];
226 /* additional padding/data after curve_data */ 236 u8 dup_bpsk;
237 u8 dup_qpsk;
238 u8 dup_16qam;
239 u8 dup_64qam;
240 __le16 rssical_mul;
241 __le16 rssical_add;
227} __attribute__ ((packed)); 242} __attribute__ ((packed));
228 243
229struct p54_tx_control_led { 244struct p54_tx_control_led {