mirror of
https://github.com/open-sdr/openwifi.git
synced 2024-12-19 05:38:09 +00:00
Only support allowed channel to avoid:
the issue of Let openwifi work at arbitrary frequency: ./sdrctl dev sdr0 set reg rf 1/5 NMPQ the wpa_supplicant scanning does scan those not allowed channel (originally reported by our driver capabilities), but hostpad already actually uses a not allowed channel (by sdrctl) while beacon still indicates an allowed channel (hostapd rejects to run on not allowed channel). So, after wpa_supplicant discovers the beacon on a not allowed channel while the beacon contains an allowed channel, it gets confused
This commit is contained in:
parent
ab74dd7433
commit
1895c3ae46
92
driver/sdr.h
92
driver/sdr.h
@ -259,12 +259,12 @@ static const struct ieee80211_channel openwifi_2GHz_channels[] = {
|
||||
CHAN2G(11, 2462, 0),
|
||||
CHAN2G(12, 2467, 0),
|
||||
CHAN2G(13, 2472, 0),
|
||||
CHAN2G(14, 2484, 0),
|
||||
// CHAN2G(14, 2484, 0),
|
||||
};
|
||||
|
||||
static const struct ieee80211_channel openwifi_5GHz_channels[] = {
|
||||
CHAN5G(32, 5160, 0),
|
||||
CHAN5G(34, 5170, 0),
|
||||
// CHAN5G(32, 5160, 0),
|
||||
// CHAN5G(34, 5170, 0),
|
||||
CHAN5G(36, 5180, 0),
|
||||
CHAN5G(38, 5190, 0),
|
||||
CHAN5G(40, 5200, 0),
|
||||
@ -272,51 +272,51 @@ static const struct ieee80211_channel openwifi_5GHz_channels[] = {
|
||||
CHAN5G(44, 5220, 0),
|
||||
CHAN5G(46, 5230, 0),
|
||||
CHAN5G(48, 5240, 0),
|
||||
CHAN5G( 50, 5250, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G( 50, 5250, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 52, 5260, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 54, 5270, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G( 54, 5270, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 56, 5280, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 58, 5290, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G( 58, 5290, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 60, 5300, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 62, 5310, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G( 62, 5310, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 64, 5320, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 68, 5340, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G( 96, 5480, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(100, 5500, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(102, 5510, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(104, 5520, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(106, 5530, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(108, 5540, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(110, 5550, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(112, 5560, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(114, 5570, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(116, 5580, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(118, 5590, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(120, 5600, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(122, 5610, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(124, 5620, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(126, 5630, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(128, 5640, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(132, 5660, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(134, 5670, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(136, 5680, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(138, 5690, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(140, 5700, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(142, 5710, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(144, 5720, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(149, 5745, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(151, 5755, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(153, 5765, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(155, 5775, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(157, 5785, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(159, 5795, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(161, 5805, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(163, 5815, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(165, 5825, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(167, 5835, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(169, 5845, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(171, 5855, IEEE80211_CHAN_RADAR),
|
||||
CHAN5G(173, 5865, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G( 68, 5340, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G( 96, 5480, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(100, 5500, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(102, 5510, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(104, 5520, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(106, 5530, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(108, 5540, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(110, 5550, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(112, 5560, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(114, 5570, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(116, 5580, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(118, 5590, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(120, 5600, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(122, 5610, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(124, 5620, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(126, 5630, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(128, 5640, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(132, 5660, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(134, 5670, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(136, 5680, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(138, 5690, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(140, 5700, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(142, 5710, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(144, 5720, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(149, 5745, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(151, 5755, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(153, 5765, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(155, 5775, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(157, 5785, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(159, 5795, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(161, 5805, IEEE80211_CHAN_RADAR),
|
||||
// // CHAN5G(163, 5815, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(165, 5825, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(167, 5835, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(169, 5845, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(171, 5855, IEEE80211_CHAN_RADAR),
|
||||
// CHAN5G(173, 5865, IEEE80211_CHAN_RADAR),
|
||||
};
|
||||
|
||||
static const struct ieee80211_iface_limit openwifi_if_limits[] = {
|
||||
@ -465,8 +465,8 @@ struct openwifi_priv {
|
||||
|
||||
struct ieee80211_rate rates_2GHz[12];
|
||||
struct ieee80211_rate rates_5GHz[12];
|
||||
struct ieee80211_channel channels_2GHz[14];
|
||||
struct ieee80211_channel channels_5GHz[53];
|
||||
struct ieee80211_channel channels_2GHz[13];
|
||||
struct ieee80211_channel channels_5GHz[11];
|
||||
struct ieee80211_supported_band band_2GHz;
|
||||
struct ieee80211_supported_band band_5GHz;
|
||||
bool rfkill_off;
|
||||
|
Loading…
Reference in New Issue
Block a user