diff options
Diffstat (limited to 'drivers/net/wireless/ipw2x00/libipw_module.c')
-rw-r--r-- | drivers/net/wireless/ipw2x00/libipw_module.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/drivers/net/wireless/ipw2x00/libipw_module.c b/drivers/net/wireless/ipw2x00/libipw_module.c index a0e9f6aed7da..be5b809ec97a 100644 --- a/drivers/net/wireless/ipw2x00/libipw_module.c +++ b/drivers/net/wireless/ipw2x00/libipw_module.c | |||
@@ -235,16 +235,19 @@ void free_ieee80211(struct net_device *dev, int monitor) | |||
235 | libipw_networks_free(ieee); | 235 | libipw_networks_free(ieee); |
236 | 236 | ||
237 | /* free cfg80211 resources */ | 237 | /* free cfg80211 resources */ |
238 | if (!monitor) { | 238 | if (!monitor) |
239 | wiphy_unregister(ieee->wdev.wiphy); | ||
240 | kfree(ieee->a_band.channels); | ||
241 | kfree(ieee->bg_band.channels); | ||
242 | wiphy_free(ieee->wdev.wiphy); | 239 | wiphy_free(ieee->wdev.wiphy); |
243 | } | ||
244 | 240 | ||
245 | free_netdev(dev); | 241 | free_netdev(dev); |
246 | } | 242 | } |
247 | 243 | ||
244 | void unregister_ieee80211(struct libipw_device *ieee) | ||
245 | { | ||
246 | wiphy_unregister(ieee->wdev.wiphy); | ||
247 | kfree(ieee->a_band.channels); | ||
248 | kfree(ieee->bg_band.channels); | ||
249 | } | ||
250 | |||
248 | #ifdef CONFIG_LIBIPW_DEBUG | 251 | #ifdef CONFIG_LIBIPW_DEBUG |
249 | 252 | ||
250 | static int debug = 0; | 253 | static int debug = 0; |
@@ -330,3 +333,4 @@ module_init(libipw_init); | |||
330 | 333 | ||
331 | EXPORT_SYMBOL(alloc_ieee80211); | 334 | EXPORT_SYMBOL(alloc_ieee80211); |
332 | EXPORT_SYMBOL(free_ieee80211); | 335 | EXPORT_SYMBOL(free_ieee80211); |
336 | EXPORT_SYMBOL(unregister_ieee80211); | ||