Commit c4e382d2 authored by Arend van Spriel's avatar Arend van Spriel Committed by John W. Linville

brcm80211: use endian annotations for assoc ie length request

The driver requests the device for number of ie's in assoc request
and response. This needed to be endian annotated.
Reported-by: default avatarJohannes Berg <johannes@sipsolutions.net>
Reviewed-by: default avatarRoland Vossen <rvossen@broadcom.com>
Reviewed-by: default avatarFranky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 40c8e95a
...@@ -2767,7 +2767,7 @@ static void brcmf_clear_assoc_ies(struct brcmf_cfg80211_priv *cfg_priv) ...@@ -2767,7 +2767,7 @@ static void brcmf_clear_assoc_ies(struct brcmf_cfg80211_priv *cfg_priv)
static s32 brcmf_get_assoc_ies(struct brcmf_cfg80211_priv *cfg_priv) static s32 brcmf_get_assoc_ies(struct brcmf_cfg80211_priv *cfg_priv)
{ {
struct net_device *ndev = cfg_to_ndev(cfg_priv); struct net_device *ndev = cfg_to_ndev(cfg_priv);
struct brcmf_cfg80211_assoc_ielen *assoc_info; struct brcmf_cfg80211_assoc_ielen_le *assoc_info;
struct brcmf_cfg80211_connect_info *conn_info = cfg_to_conn(cfg_priv); struct brcmf_cfg80211_connect_info *conn_info = cfg_to_conn(cfg_priv);
u32 req_len; u32 req_len;
u32 resp_len; u32 resp_len;
...@@ -2781,9 +2781,10 @@ static s32 brcmf_get_assoc_ies(struct brcmf_cfg80211_priv *cfg_priv) ...@@ -2781,9 +2781,10 @@ static s32 brcmf_get_assoc_ies(struct brcmf_cfg80211_priv *cfg_priv)
WL_ERR("could not get assoc info (%d)\n", err); WL_ERR("could not get assoc info (%d)\n", err);
return err; return err;
} }
assoc_info = (struct brcmf_cfg80211_assoc_ielen *)cfg_priv->extra_buf; assoc_info =
req_len = assoc_info->req_len; (struct brcmf_cfg80211_assoc_ielen_le *)cfg_priv->extra_buf;
resp_len = assoc_info->resp_len; req_len = le32_to_cpu(assoc_info->req_len);
resp_len = le32_to_cpu(assoc_info->resp_len);
if (req_len) { if (req_len) {
err = brcmf_dev_bufvar_get(ndev, "assoc_req_ies", err = brcmf_dev_bufvar_get(ndev, "assoc_req_ies",
cfg_priv->extra_buf, cfg_priv->extra_buf,
......
...@@ -264,9 +264,9 @@ struct brcmf_cfg80211_connect_info { ...@@ -264,9 +264,9 @@ struct brcmf_cfg80211_connect_info {
}; };
/* assoc ie length */ /* assoc ie length */
struct brcmf_cfg80211_assoc_ielen { struct brcmf_cfg80211_assoc_ielen_le {
u32 req_len; __le32 req_len;
u32 resp_len; __le32 resp_len;
}; };
/* wpa2 pmk list */ /* wpa2 pmk list */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment