aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00dev.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00dev.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00dev.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c
index e1feab8b6b02..477a944167c4 100644
--- a/drivers/net/wireless/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/rt2x00/rt2x00dev.c
@@ -417,7 +417,7 @@ static void rt2x00lib_intf_scheduled_iter(void *data, u8 *mac,
417 */ 417 */
418 spin_lock(&intf->lock); 418 spin_lock(&intf->lock);
419 419
420 memcpy(&conf, &intf->conf, sizeof(conf)); 420 memcpy(&conf, &vif->bss_conf, sizeof(conf));
421 delayed_flags = intf->delayed_flags; 421 delayed_flags = intf->delayed_flags;
422 intf->delayed_flags = 0; 422 intf->delayed_flags = 0;
423 423
@@ -1056,10 +1056,16 @@ int rt2x00lib_probe_dev(struct rt2x00_dev *rt2x00dev)
1056 */ 1056 */
1057 rt2x00dev->hw->vif_data_size = sizeof(struct rt2x00_intf); 1057 rt2x00dev->hw->vif_data_size = sizeof(struct rt2x00_intf);
1058 1058
1059 rt2x00dev->hw->wiphy->interface_modes = 1059 /*
1060 BIT(NL80211_IFTYPE_AP) | 1060 * Determine which operating modes are supported, all modes
1061 BIT(NL80211_IFTYPE_STATION) | 1061 * which require beaconing, depend on the availability of
1062 BIT(NL80211_IFTYPE_ADHOC); 1062 * beacon entries.
1063 */
1064 rt2x00dev->hw->wiphy->interface_modes = BIT(NL80211_IFTYPE_STATION);
1065 if (rt2x00dev->ops->bcn->entry_num > 0)
1066 rt2x00dev->hw->wiphy->interface_modes |=
1067 BIT(NL80211_IFTYPE_ADHOC) |
1068 BIT(NL80211_IFTYPE_AP);
1063 1069
1064 /* 1070 /*
1065 * Let the driver probe the device to detect the capabilities. 1071 * Let the driver probe the device to detect the capabilities.