summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
authorKarl Beldan <karl.beldan@rivierawaves.com>2013-02-15 00:03:14 +0100
committerJohannes Berg <johannes.berg@intel.com>2013-02-15 09:41:45 +0100
commit93c78c5debeb9c7101ecc73347d4730c26a98c05 (patch)
tree0496508c95d627e2bdf35456a44495086490d900 /drivers/net/wireless
parent586e01ededf9b713a1512dd658806791a7ca1a50 (diff)
downloadblackbird-op-linux-93c78c5debeb9c7101ecc73347d4730c26a98c05.tar.gz
blackbird-op-linux-93c78c5debeb9c7101ecc73347d4730c26a98c05.zip
mac80211_hwsim: ask mac80211 to reserve space for chanctx.drv_priv
Otherwise memory corruption occurs when using channel contexts (ATM when param 'channel' > 1). Signed-off-by: Karl Beldan <karl.beldan@rivierawaves.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/mac80211_hwsim.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index b73e497fe770..cffdf4fbf161 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -2247,6 +2247,7 @@ static int __init init_mac80211_hwsim(void)
/* ask mac80211 to reserve space for magic */
hw->vif_data_size = sizeof(struct hwsim_vif_priv);
hw->sta_data_size = sizeof(struct hwsim_sta_priv);
+ hw->chanctx_data_size = sizeof(struct hwsim_chanctx_priv);
memcpy(data->channels_2ghz, hwsim_channels_2ghz,
sizeof(hwsim_channels_2ghz));
OpenPOWER on IntegriCloud