diff options
-rw-r--r-- | net/wireless/reg.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/net/wireless/reg.c b/net/wireless/reg.c index 2796b622890f..068cb4055a62 100644 --- a/net/wireless/reg.c +++ b/net/wireless/reg.c | |||
@@ -571,6 +571,20 @@ static bool freq_in_rule_band(const struct ieee80211_freq_range *freq_range, | |||
571 | } | 571 | } |
572 | 572 | ||
573 | /* | 573 | /* |
574 | * Later on we can perhaps use the more restrictive DFS | ||
575 | * region but we don't have information for that yet so | ||
576 | * for now simply disallow conflicts. | ||
577 | */ | ||
578 | static enum nl80211_dfs_regions | ||
579 | reg_intersect_dfs_region(const enum nl80211_dfs_regions dfs_region1, | ||
580 | const enum nl80211_dfs_regions dfs_region2) | ||
581 | { | ||
582 | if (dfs_region1 != dfs_region2) | ||
583 | return NL80211_DFS_UNSET; | ||
584 | return dfs_region1; | ||
585 | } | ||
586 | |||
587 | /* | ||
574 | * Helper for regdom_intersect(), this does the real | 588 | * Helper for regdom_intersect(), this does the real |
575 | * mathematical intersection fun | 589 | * mathematical intersection fun |
576 | */ | 590 | */ |
@@ -701,6 +715,8 @@ regdom_intersect(const struct ieee80211_regdomain *rd1, | |||
701 | rd->n_reg_rules = num_rules; | 715 | rd->n_reg_rules = num_rules; |
702 | rd->alpha2[0] = '9'; | 716 | rd->alpha2[0] = '9'; |
703 | rd->alpha2[1] = '8'; | 717 | rd->alpha2[1] = '8'; |
718 | rd->dfs_region = reg_intersect_dfs_region(rd1->dfs_region, | ||
719 | rd2->dfs_region); | ||
704 | 720 | ||
705 | return rd; | 721 | return rd; |
706 | } | 722 | } |