mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-12 08:48:48 +00:00
cfg80211: allow drivers that can't scan for specific ssids
Signed-off-by: David Kilroy <kilroyd@googlemail.com> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
3daf097594
commit
51cd4aabd0
@ -346,9 +346,6 @@ int wiphy_register(struct wiphy *wiphy)
|
|||||||
int i;
|
int i;
|
||||||
u16 ifmodes = wiphy->interface_modes;
|
u16 ifmodes = wiphy->interface_modes;
|
||||||
|
|
||||||
if (WARN_ON(wiphy->max_scan_ssids < 1))
|
|
||||||
return -EINVAL;
|
|
||||||
|
|
||||||
/* sanity check ifmodes */
|
/* sanity check ifmodes */
|
||||||
WARN_ON(!ifmodes);
|
WARN_ON(!ifmodes);
|
||||||
ifmodes &= ((1 << __NL80211_IFTYPE_AFTER_LAST) - 1) & ~1;
|
ifmodes &= ((1 << __NL80211_IFTYPE_AFTER_LAST) - 1) & ~1;
|
||||||
|
@ -247,6 +247,7 @@ int cfg80211_wext_giwrange(struct net_device *dev,
|
|||||||
IW_EVENT_CAPA_SET(range->event_capa, SIOCGIWAP);
|
IW_EVENT_CAPA_SET(range->event_capa, SIOCGIWAP);
|
||||||
IW_EVENT_CAPA_SET(range->event_capa, SIOCGIWSCAN);
|
IW_EVENT_CAPA_SET(range->event_capa, SIOCGIWSCAN);
|
||||||
|
|
||||||
|
if (wdev->wiphy->max_scan_ssids > 0)
|
||||||
range->scan_capa |= IW_SCAN_CAPA_ESSID;
|
range->scan_capa |= IW_SCAN_CAPA_ESSID;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user