aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/p54common.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2008-02-29 13:56:33 +0100
committerJohn W. Linville <linville@tuxdriver.com>2008-03-04 18:36:36 -0500
commit8c28293f5514f64ba064bac7946aebeda4a663c6 (patch)
tree92a88fa9606aff0e0325b2cc4c328a395866541e /drivers/net/wireless/p54common.c
parentdc63644b0ee3b447e879ef8e124657b40e9ea81c (diff)
p54: fix EEPROM structure endianness
Since the EEPROM structure is read from hardware, it is always little endian, annotate that in the struct and make sure to convert where applicable. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Cc: Michael Wu <flamingice@sourmilk.net> Tested-by: Florian Fainelli <florian.fainelli@telecomint.eu> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/p54common.c')
-rw-r--r--drivers/net/wireless/p54common.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/p54common.c b/drivers/net/wireless/p54common.c
index 5cda49aff3a..56aabec73c2 100644
--- a/drivers/net/wireless/p54common.c
+++ b/drivers/net/wireless/p54common.c
@@ -172,7 +172,7 @@ int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len)
int err;
wrap = (struct eeprom_pda_wrap *) eeprom;
- entry = (void *)wrap->data + wrap->len;
+ entry = (void *)wrap->data + le16_to_cpu(wrap->len);
i += 2;
i += le16_to_cpu(entry->len)*2;
while (i < len) {