diff options
Diffstat (limited to 'net/mac80211/util.c')
-rw-r--r-- | net/mac80211/util.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/net/mac80211/util.c b/net/mac80211/util.c index 07686bda26cd..c970996ba6f9 100644 --- a/net/mac80211/util.c +++ b/net/mac80211/util.c | |||
@@ -20,6 +20,7 @@ | |||
20 | #include <linux/if_arp.h> | 20 | #include <linux/if_arp.h> |
21 | #include <linux/wireless.h> | 21 | #include <linux/wireless.h> |
22 | #include <linux/bitmap.h> | 22 | #include <linux/bitmap.h> |
23 | #include <net/net_namespace.h> | ||
23 | #include <net/cfg80211.h> | 24 | #include <net/cfg80211.h> |
24 | 25 | ||
25 | #include "ieee80211_i.h" | 26 | #include "ieee80211_i.h" |
@@ -318,7 +319,7 @@ __le16 ieee80211_generic_frame_duration(struct ieee80211_hw *hw, int if_id, | |||
318 | size_t frame_len, int rate) | 319 | size_t frame_len, int rate) |
319 | { | 320 | { |
320 | struct ieee80211_local *local = hw_to_local(hw); | 321 | struct ieee80211_local *local = hw_to_local(hw); |
321 | struct net_device *bdev = dev_get_by_index(if_id); | 322 | struct net_device *bdev = dev_get_by_index(&init_net, if_id); |
322 | struct ieee80211_sub_if_data *sdata; | 323 | struct ieee80211_sub_if_data *sdata; |
323 | u16 dur; | 324 | u16 dur; |
324 | int erp; | 325 | int erp; |
@@ -342,7 +343,7 @@ __le16 ieee80211_rts_duration(struct ieee80211_hw *hw, int if_id, | |||
342 | { | 343 | { |
343 | struct ieee80211_local *local = hw_to_local(hw); | 344 | struct ieee80211_local *local = hw_to_local(hw); |
344 | struct ieee80211_rate *rate; | 345 | struct ieee80211_rate *rate; |
345 | struct net_device *bdev = dev_get_by_index(if_id); | 346 | struct net_device *bdev = dev_get_by_index(&init_net, if_id); |
346 | struct ieee80211_sub_if_data *sdata; | 347 | struct ieee80211_sub_if_data *sdata; |
347 | int short_preamble; | 348 | int short_preamble; |
348 | int erp; | 349 | int erp; |
@@ -378,7 +379,7 @@ __le16 ieee80211_ctstoself_duration(struct ieee80211_hw *hw, int if_id, | |||
378 | { | 379 | { |
379 | struct ieee80211_local *local = hw_to_local(hw); | 380 | struct ieee80211_local *local = hw_to_local(hw); |
380 | struct ieee80211_rate *rate; | 381 | struct ieee80211_rate *rate; |
381 | struct net_device *bdev = dev_get_by_index(if_id); | 382 | struct net_device *bdev = dev_get_by_index(&init_net, if_id); |
382 | struct ieee80211_sub_if_data *sdata; | 383 | struct ieee80211_sub_if_data *sdata; |
383 | int short_preamble; | 384 | int short_preamble; |
384 | int erp; | 385 | int erp; |