Commit 4f89122d authored by Amitkumar Karwar's avatar Amitkumar Karwar Committed by Greg Kroah-Hartman

mwifiex: add missing endian conversion for fw_tsf

commit 97952297 upstream.

It is u64 data received from firmware. Little endian to cpu
conversion is required here.
Signed-off-by: default avatarAmitkumar Karwar <akarwar@marvell.com>
Signed-off-by: default avatarBing Zhao <bzhao@marvell.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent dc0abfd7
...@@ -1622,7 +1622,7 @@ int mwifiex_ret_802_11_scan(struct mwifiex_private *priv, ...@@ -1622,7 +1622,7 @@ int mwifiex_ret_802_11_scan(struct mwifiex_private *priv,
const u8 *ie_buf; const u8 *ie_buf;
size_t ie_len; size_t ie_len;
u16 channel = 0; u16 channel = 0;
u64 fw_tsf = 0; __le64 fw_tsf = 0;
u16 beacon_size = 0; u16 beacon_size = 0;
u32 curr_bcn_bytes; u32 curr_bcn_bytes;
u32 freq; u32 freq;
...@@ -1749,7 +1749,7 @@ int mwifiex_ret_802_11_scan(struct mwifiex_private *priv, ...@@ -1749,7 +1749,7 @@ int mwifiex_ret_802_11_scan(struct mwifiex_private *priv,
ie_buf, ie_len, rssi, GFP_KERNEL); ie_buf, ie_len, rssi, GFP_KERNEL);
bss_priv = (struct mwifiex_bss_priv *)bss->priv; bss_priv = (struct mwifiex_bss_priv *)bss->priv;
bss_priv->band = band; bss_priv->band = band;
bss_priv->fw_tsf = fw_tsf; bss_priv->fw_tsf = le64_to_cpu(fw_tsf);
if (priv->media_connected && if (priv->media_connected &&
!memcmp(bssid, !memcmp(bssid,
priv->curr_bss_params.bss_descriptor priv->curr_bss_params.bss_descriptor
......
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