nl80211: Fix DFS radar event parsing
Incorrect nla_get variants were used to get event type and frequency. Kernel passes both as u32. This caused issues on tinynl/big-endian hosts - CAC finished was treated as radar detection and frequency was 0. Signed-hostap: Michal Kazior <michal.kazior@tieto.com>
This commit is contained in:
parent
2b72df6374
commit
cd3b0700df
1 changed files with 2 additions and 2 deletions
|
@ -2510,8 +2510,8 @@ static void nl80211_radar_event(struct wpa_driver_nl80211_data *drv,
|
|||
return;
|
||||
|
||||
os_memset(&data, 0, sizeof(data));
|
||||
data.dfs_event.freq = nla_get_u16(tb[NL80211_ATTR_WIPHY_FREQ]);
|
||||
event_type = nla_get_u8(tb[NL80211_ATTR_RADAR_EVENT]);
|
||||
data.dfs_event.freq = nla_get_u32(tb[NL80211_ATTR_WIPHY_FREQ]);
|
||||
event_type = nla_get_u32(tb[NL80211_ATTR_RADAR_EVENT]);
|
||||
|
||||
/* Check HT params */
|
||||
if (tb[NL80211_ATTR_WIPHY_CHANNEL_TYPE]) {
|
||||
|
|
Loading…
Reference in a new issue