diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2009-12-14 23:12:09 +0100 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-12-21 17:32:07 +0100 |
commit | b7bb1756cb6a610cdbac8cfdad9e79bb5670b63b (patch) | |
tree | 5c4d75da72c31eb33f9c2c18827018a62ac3093c /drivers/net/wireless/iwlwifi/iwl-eeprom.h | |
parent | iwlwifi: fix EEPROM/OTP reading endian annotations and a bug (diff) | |
download | linux-b7bb1756cb6a610cdbac8cfdad9e79bb5670b63b.tar.xz linux-b7bb1756cb6a610cdbac8cfdad9e79bb5670b63b.zip |
iwlwifi: fix more eeprom endian bugs
I've also for a long time had a problem with the
temperature calculation code, which I had fixed
by byte-swapping the values, and now it turns out
that was the correct fix after all.
Also, any use of iwl_eeprom_query_addr() that is
for more than a u8 must be cast to little endian,
and some structs as well.
Fix all this. Again, no real impact on platforms
that already are little endian.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Cc: stable@kernel.org
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-eeprom.h')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-eeprom.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-eeprom.h b/drivers/net/wireless/iwlwifi/iwl-eeprom.h index 5cd2b66bbe45..0cd9c02ee044 100644 --- a/drivers/net/wireless/iwlwifi/iwl-eeprom.h +++ b/drivers/net/wireless/iwlwifi/iwl-eeprom.h @@ -137,7 +137,7 @@ struct iwl_eeprom_channel { * */ struct iwl_eeprom_enhanced_txpwr { - u16 common; + __le16 common; s8 chain_a_max; s8 chain_b_max; s8 chain_c_max; @@ -360,7 +360,7 @@ struct iwl_eeprom_calib_subband_info { struct iwl_eeprom_calib_info { u8 saturation_power24; /* half-dBm (e.g. "34" = 17 dBm) */ u8 saturation_power52; /* half-dBm */ - s16 voltage; /* signed */ + __le16 voltage; /* signed */ struct iwl_eeprom_calib_subband_info band_info[EEPROM_TX_POWER_BANDS]; } __attribute__ ((packed)); |