|
@@ -118,7 +118,7 @@
|
|
|
#define IBSS_CFG_PROTECTION_ENABLE_MASK 0x8282
|
|
|
|
|
|
#define HDD2GHZCHAN(freq, chan, flag) { \
|
|
|
- .band = IEEE80211_BAND_2GHZ, \
|
|
|
+ .band = NL80211_BAND_2GHZ, \
|
|
|
.center_freq = (freq), \
|
|
|
.hw_value = (chan), \
|
|
|
.flags = (flag), \
|
|
@@ -127,7 +127,7 @@
|
|
|
}
|
|
|
|
|
|
#define HDD5GHZCHAN(freq, chan, flag) { \
|
|
|
- .band = IEEE80211_BAND_5GHZ, \
|
|
|
+ .band = NL80211_BAND_5GHZ, \
|
|
|
.center_freq = (freq), \
|
|
|
.hw_value = (chan), \
|
|
|
.flags = (flag), \
|
|
@@ -265,7 +265,7 @@ static struct ieee80211_rate a_mode_rates[] = {
|
|
|
static struct ieee80211_supported_band wlan_hdd_band_2_4_ghz = {
|
|
|
.channels = NULL,
|
|
|
.n_channels = ARRAY_SIZE(hdd_channels_2_4_ghz),
|
|
|
- .band = IEEE80211_BAND_2GHZ,
|
|
|
+ .band = NL80211_BAND_2GHZ,
|
|
|
.bitrates = g_mode_rates,
|
|
|
.n_bitrates = g_mode_rates_size,
|
|
|
.ht_cap.ht_supported = 1,
|
|
@@ -284,7 +284,7 @@ static struct ieee80211_supported_band wlan_hdd_band_2_4_ghz = {
|
|
|
static struct ieee80211_supported_band wlan_hdd_band_5_ghz = {
|
|
|
.channels = NULL,
|
|
|
.n_channels = ARRAY_SIZE(hdd_channels_5_ghz),
|
|
|
- .band = IEEE80211_BAND_5GHZ,
|
|
|
+ .band = NL80211_BAND_5GHZ,
|
|
|
.bitrates = a_mode_rates,
|
|
|
.n_bitrates = a_mode_rates_size,
|
|
|
.ht_cap.ht_supported = 1,
|
|
@@ -5265,11 +5265,11 @@ static int __wlan_hdd_cfg80211_get_preferred_freq_list(struct wiphy *wiphy,
|
|
|
if (pcl[i] <= ARRAY_SIZE(hdd_channels_2_4_ghz))
|
|
|
freq_list[i] =
|
|
|
ieee80211_channel_to_frequency(pcl[i],
|
|
|
- IEEE80211_BAND_2GHZ);
|
|
|
+ NL80211_BAND_2GHZ);
|
|
|
else
|
|
|
freq_list[i] =
|
|
|
ieee80211_channel_to_frequency(pcl[i],
|
|
|
- IEEE80211_BAND_5GHZ);
|
|
|
+ NL80211_BAND_5GHZ);
|
|
|
}
|
|
|
|
|
|
/* send the freq_list back to supplicant */
|
|
@@ -8625,7 +8625,7 @@ int wlan_hdd_cfg80211_update_band(struct wiphy *wiphy, eCsrBand eBand)
|
|
|
|
|
|
ENTER();
|
|
|
|
|
|
- for (i = 0; i < IEEE80211_NUM_BANDS; i++) {
|
|
|
+ for (i = 0; i < NUM_NL80211_BANDS; i++) {
|
|
|
|
|
|
if (NULL == wiphy->bands[i])
|
|
|
continue;
|
|
@@ -8637,7 +8637,7 @@ int wlan_hdd_cfg80211_update_band(struct wiphy *wiphy, eCsrBand eBand)
|
|
|
cds_get_channel_state(band->channels[j].
|
|
|
hw_value);
|
|
|
|
|
|
- if (IEEE80211_BAND_2GHZ == i && eCSR_BAND_5G == eBand) {
|
|
|
+ if (NL80211_BAND_2GHZ == i && eCSR_BAND_5G == eBand) {
|
|
|
/* 5G only */
|
|
|
#ifdef WLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY
|
|
|
/* Enable Social channels for P2P */
|
|
@@ -8652,7 +8652,7 @@ int wlan_hdd_cfg80211_update_band(struct wiphy *wiphy, eCsrBand eBand)
|
|
|
band->channels[j].flags |=
|
|
|
IEEE80211_CHAN_DISABLED;
|
|
|
continue;
|
|
|
- } else if (IEEE80211_BAND_5GHZ == i &&
|
|
|
+ } else if (NL80211_BAND_5GHZ == i &&
|
|
|
eCSR_BAND_24 == eBand) {
|
|
|
/* 2G only */
|
|
|
band->channels[j].flags |=
|
|
@@ -8812,14 +8812,14 @@ int wlan_hdd_cfg80211_init(struct device *dev,
|
|
|
* wiphy flags don't get reset because of static memory.
|
|
|
* It's better not to store channel in static memory.
|
|
|
*/
|
|
|
- wiphy->bands[IEEE80211_BAND_2GHZ] = &wlan_hdd_band_2_4_ghz;
|
|
|
- wiphy->bands[IEEE80211_BAND_2GHZ]->channels =
|
|
|
+ wiphy->bands[NL80211_BAND_2GHZ] = &wlan_hdd_band_2_4_ghz;
|
|
|
+ wiphy->bands[NL80211_BAND_2GHZ]->channels =
|
|
|
qdf_mem_malloc(sizeof(hdd_channels_2_4_ghz));
|
|
|
- if (wiphy->bands[IEEE80211_BAND_2GHZ]->channels == NULL) {
|
|
|
+ if (wiphy->bands[NL80211_BAND_2GHZ]->channels == NULL) {
|
|
|
hdd_err("Not enough memory to allocate channels");
|
|
|
return -ENOMEM;
|
|
|
}
|
|
|
- qdf_mem_copy(wiphy->bands[IEEE80211_BAND_2GHZ]->channels,
|
|
|
+ qdf_mem_copy(wiphy->bands[NL80211_BAND_2GHZ]->channels,
|
|
|
&hdd_channels_2_4_ghz[0],
|
|
|
sizeof(hdd_channels_2_4_ghz));
|
|
|
if ((hdd_is_5g_supported(pHddCtx)) &&
|
|
@@ -8827,22 +8827,22 @@ int wlan_hdd_cfg80211_init(struct device *dev,
|
|
|
(eHDD_DOT11_MODE_11g != pCfg->dot11Mode) &&
|
|
|
(eHDD_DOT11_MODE_11b_ONLY != pCfg->dot11Mode) &&
|
|
|
(eHDD_DOT11_MODE_11g_ONLY != pCfg->dot11Mode))) {
|
|
|
- wiphy->bands[IEEE80211_BAND_5GHZ] = &wlan_hdd_band_5_ghz;
|
|
|
- wiphy->bands[IEEE80211_BAND_5GHZ]->channels =
|
|
|
+ wiphy->bands[NL80211_BAND_5GHZ] = &wlan_hdd_band_5_ghz;
|
|
|
+ wiphy->bands[NL80211_BAND_5GHZ]->channels =
|
|
|
qdf_mem_malloc(sizeof(hdd_channels_5_ghz));
|
|
|
- if (wiphy->bands[IEEE80211_BAND_5GHZ]->channels == NULL) {
|
|
|
+ if (wiphy->bands[NL80211_BAND_5GHZ]->channels == NULL) {
|
|
|
hdd_err("Not enough memory to allocate channels");
|
|
|
qdf_mem_free(wiphy->
|
|
|
- bands[IEEE80211_BAND_2GHZ]->channels);
|
|
|
- wiphy->bands[IEEE80211_BAND_2GHZ]->channels = NULL;
|
|
|
+ bands[NL80211_BAND_2GHZ]->channels);
|
|
|
+ wiphy->bands[NL80211_BAND_2GHZ]->channels = NULL;
|
|
|
return -ENOMEM;
|
|
|
}
|
|
|
- qdf_mem_copy(wiphy->bands[IEEE80211_BAND_5GHZ]->channels,
|
|
|
+ qdf_mem_copy(wiphy->bands[NL80211_BAND_5GHZ]->channels,
|
|
|
&hdd_channels_5_ghz[0],
|
|
|
sizeof(hdd_channels_5_ghz));
|
|
|
}
|
|
|
|
|
|
- for (i = 0; i < IEEE80211_NUM_BANDS; i++) {
|
|
|
+ for (i = 0; i < NUM_NL80211_BANDS; i++) {
|
|
|
|
|
|
if (NULL == wiphy->bands[i])
|
|
|
continue;
|
|
@@ -8850,7 +8850,7 @@ int wlan_hdd_cfg80211_init(struct device *dev,
|
|
|
for (j = 0; j < wiphy->bands[i]->n_channels; j++) {
|
|
|
struct ieee80211_supported_band *band = wiphy->bands[i];
|
|
|
|
|
|
- if (IEEE80211_BAND_2GHZ == i &&
|
|
|
+ if (NL80211_BAND_2GHZ == i &&
|
|
|
eCSR_BAND_5G == pCfg->nBandCapability) {
|
|
|
/* 5G only */
|
|
|
#ifdef WLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY
|
|
@@ -8864,7 +8864,7 @@ int wlan_hdd_cfg80211_init(struct device *dev,
|
|
|
band->channels[j].flags |=
|
|
|
IEEE80211_CHAN_DISABLED;
|
|
|
continue;
|
|
|
- } else if (IEEE80211_BAND_5GHZ == i &&
|
|
|
+ } else if (NL80211_BAND_5GHZ == i &&
|
|
|
eCSR_BAND_24 == pCfg->nBandCapability) {
|
|
|
/* 2G only */
|
|
|
band->channels[j].flags |=
|
|
@@ -8921,7 +8921,7 @@ void wlan_hdd_cfg80211_deinit(struct wiphy *wiphy)
|
|
|
{
|
|
|
int i;
|
|
|
|
|
|
- for (i = 0; i < IEEE80211_NUM_BANDS; i++) {
|
|
|
+ for (i = 0; i < NUM_NL80211_BANDS; i++) {
|
|
|
if (NULL != wiphy->bands[i] &&
|
|
|
(NULL != wiphy->bands[i]->channels)) {
|
|
|
qdf_mem_free(wiphy->bands[i]->channels);
|
|
@@ -10698,15 +10698,15 @@ struct cfg80211_bss *wlan_hdd_cfg80211_inform_bss_frame(hdd_adapter_t *pAdapter,
|
|
|
}
|
|
|
|
|
|
if (chan_no <= ARRAY_SIZE(hdd_channels_2_4_ghz) &&
|
|
|
- (wiphy->bands[IEEE80211_BAND_2GHZ] != NULL)) {
|
|
|
+ (wiphy->bands[NL80211_BAND_2GHZ] != NULL)) {
|
|
|
freq =
|
|
|
ieee80211_channel_to_frequency(chan_no,
|
|
|
- IEEE80211_BAND_2GHZ);
|
|
|
+ NL80211_BAND_2GHZ);
|
|
|
} else if ((chan_no > ARRAY_SIZE(hdd_channels_2_4_ghz))
|
|
|
- && (wiphy->bands[IEEE80211_BAND_5GHZ] != NULL)) {
|
|
|
+ && (wiphy->bands[NL80211_BAND_5GHZ] != NULL)) {
|
|
|
freq =
|
|
|
ieee80211_channel_to_frequency(chan_no,
|
|
|
- IEEE80211_BAND_5GHZ);
|
|
|
+ NL80211_BAND_5GHZ);
|
|
|
} else {
|
|
|
hdd_err("Invalid chan_no %d", chan_no);
|
|
|
kfree(mgmt);
|