Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 300990
b: refs/heads/master
c: 8e8b41f
h: refs/heads/master
v: v3
  • Loading branch information
Johannes Berg authored and John W. Linville committed Apr 16, 2012
1 parent 6f5de64 commit be94ae7
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 17 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0d920987f900573f9f86b7310147ebd1646657c9
refs/heads/master: 8e8b41f9d8c8e63fc92f899ace8da91a490ac573
6 changes: 1 addition & 5 deletions trunk/include/net/cfg80211.h
Original file line number Diff line number Diff line change
Expand Up @@ -1745,10 +1745,6 @@ struct cfg80211_ops {
* hints read the documenation for regulatory_hint_found_beacon()
* @WIPHY_FLAG_NETNS_OK: if not set, do not allow changing the netns of this
* wiphy at all
* @WIPHY_FLAG_ENFORCE_COMBINATIONS: Set this flag to enforce interface
* combinations for this device. This flag is used for backward
* compatibility only until all drivers advertise combinations and
* they will always be enforced.
* @WIPHY_FLAG_PS_ON_BY_DEFAULT: if set to true, powersave will be enabled
* by default -- this flag will be set depending on the kernel's default
* on wiphy_new(), but can be changed by the driver if it has a good
Expand Down Expand Up @@ -1793,7 +1789,7 @@ enum wiphy_flags {
WIPHY_FLAG_IBSS_RSN = BIT(8),
WIPHY_FLAG_MESH_AUTH = BIT(10),
WIPHY_FLAG_SUPPORTS_SCHED_SCAN = BIT(11),
WIPHY_FLAG_ENFORCE_COMBINATIONS = BIT(12),
/* use hole at 12 */
WIPHY_FLAG_SUPPORTS_FW_ROAM = BIT(13),
WIPHY_FLAG_AP_UAPSD = BIT(14),
WIPHY_FLAG_SUPPORTS_TDLS = BIT(15),
Expand Down
4 changes: 0 additions & 4 deletions trunk/net/wireless/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -422,10 +422,6 @@ static int wiphy_verify_combinations(struct wiphy *wiphy)
const struct ieee80211_iface_combination *c;
int i, j;

/* If we have combinations enforce them */
if (wiphy->n_iface_combinations)
wiphy->flags |= WIPHY_FLAG_ENFORCE_COMBINATIONS;

for (i = 0; i < wiphy->n_iface_combinations; i++) {
u32 cnt = 0;
u16 all_iftypes = 0;
Expand Down
10 changes: 3 additions & 7 deletions trunk/net/wireless/util.c
Original file line number Diff line number Diff line change
Expand Up @@ -946,13 +946,6 @@ int cfg80211_can_change_interface(struct cfg80211_registered_device *rdev,
if (rdev->wiphy.software_iftypes & BIT(iftype))
return 0;

/*
* Drivers will gradually all set this flag, until all
* have it we only enforce for those that set it.
*/
if (!(rdev->wiphy.flags & WIPHY_FLAG_ENFORCE_COMBINATIONS))
return 0;

memset(num, 0, sizeof(num));

num[iftype] = 1;
Expand All @@ -972,6 +965,9 @@ int cfg80211_can_change_interface(struct cfg80211_registered_device *rdev,
}
mutex_unlock(&rdev->devlist_mtx);

if (total == 1)
return 0;

for (i = 0; i < rdev->wiphy.n_iface_combinations; i++) {
const struct ieee80211_iface_combination *c;
struct ieee80211_iface_limit *limits;
Expand Down

0 comments on commit be94ae7

Please sign in to comment.