Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 303200 Details for
Bug 439249
iwl4965 is not able to connect to wifi network
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
revert-iwlwifi-refactor-init-geos.patch
revert.patch (text/plain), 6.80 KB, created by
John W. Linville
on 2008-04-21 20:26:22 UTC
(
hide
)
Description:
revert-iwlwifi-refactor-init-geos.patch
Filename:
MIME Type:
Creator:
John W. Linville
Created:
2008-04-21 20:26:22 UTC
Size:
6.80 KB
patch
obsolete
>diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c >index 1a5678f..8947254 100644 >--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c >+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c >@@ -4840,12 +4840,11 @@ static int iwl3945_init_channel_map(struct iwl3945_priv *priv) > ch_info->scan_power = eeprom_ch_info[ch].max_power_avg; > ch_info->min_power = 0; > >- IWL_DEBUG_INFO("Ch. %d [%sGHz] %s%s%s%s%s%s%s(0x%02x" >+ IWL_DEBUG_INFO("Ch. %d [%sGHz] %s%s%s%s%s%s(0x%02x" > " %ddBm): Ad-Hoc %ssupported\n", > ch_info->channel, > is_channel_a_band(ch_info) ? > "5.2" : "2.4", >- CHECK_AND_PRINT(VALID), > CHECK_AND_PRINT(IBSS), > CHECK_AND_PRINT(ACTIVE), > CHECK_AND_PRINT(RADAR), >@@ -5058,7 +5057,7 @@ static void iwl3945_init_hw_rates(struct iwl3945_priv *priv, > static int iwl3945_init_geos(struct iwl3945_priv *priv) > { > struct iwl3945_channel_info *ch; >- struct ieee80211_supported_band *sband; >+ struct ieee80211_supported_band *band; > struct ieee80211_channel *channels; > struct ieee80211_channel *geo_ch; > struct ieee80211_rate *rates; >@@ -5076,7 +5075,7 @@ static int iwl3945_init_geos(struct iwl3945_priv *priv) > if (!channels) > return -ENOMEM; > >- rates = kzalloc((sizeof(struct ieee80211_rate) * (IWL_RATE_COUNT + 1)), >+ rates = kzalloc((sizeof(struct ieee80211_rate) * (IWL_MAX_RATES + 1)), > GFP_KERNEL); > if (!rates) { > kfree(channels); >@@ -5084,38 +5083,38 @@ static int iwl3945_init_geos(struct iwl3945_priv *priv) > } > > /* 5.2GHz channels start after the 2.4GHz channels */ >- sband = &priv->bands[IEEE80211_BAND_5GHZ]; >- sband->channels = &channels[ARRAY_SIZE(iwl3945_eeprom_band_1)]; >- /* just OFDM */ >- sband->bitrates = &rates[IWL_FIRST_OFDM_RATE]; >- sband->n_bitrates = IWL_RATE_COUNT - IWL_FIRST_OFDM_RATE; >- >- sband = &priv->bands[IEEE80211_BAND_2GHZ]; >- sband->channels = channels; >- /* OFDM & CCK */ >- sband->bitrates = rates; >- sband->n_bitrates = IWL_RATE_COUNT; >+ band = &priv->bands[IEEE80211_BAND_5GHZ]; >+ band->channels = &channels[ARRAY_SIZE(iwl3945_eeprom_band_1)]; >+ band->bitrates = &rates[4]; >+ band->n_bitrates = 8; /* just OFDM */ >+ >+ band = &priv->bands[IEEE80211_BAND_2GHZ]; >+ band->channels = channels; >+ band->bitrates = rates; >+ band->n_bitrates = 12; /* OFDM & CCK */ > > priv->ieee_channels = channels; > priv->ieee_rates = rates; > > iwl3945_init_hw_rates(priv, rates); > >- for (i = 0; i < priv->channel_count; i++) { >+ for (i = 0, geo_ch = channels; i < priv->channel_count; i++) { > ch = &priv->channel_info[i]; > >- /* FIXME: might be removed if scan is OK*/ >- if (!is_channel_valid(ch)) >+ if (!is_channel_valid(ch)) { >+ IWL_DEBUG_INFO("Channel %d [%sGHz] is restricted -- " >+ "skipping.\n", >+ ch->channel, is_channel_a_band(ch) ? >+ "5.2" : "2.4"); > continue; >+ } > > if (is_channel_a_band(ch)) >- sband = &priv->bands[IEEE80211_BAND_5GHZ]; >+ geo_ch = &priv->bands[IEEE80211_BAND_5GHZ].channels[priv->bands[IEEE80211_BAND_5GHZ].n_channels++]; > else >- sband = &priv->bands[IEEE80211_BAND_2GHZ]; >+ geo_ch = &priv->bands[IEEE80211_BAND_2GHZ].channels[priv->bands[IEEE80211_BAND_2GHZ].n_channels++]; > >- geo_ch = &sband->channels[sband->n_channels++]; >- >- geo_ch->center_freq = ieee80211_channel_to_frequency(ch->channel); >+ geo_ch->center_freq = ieee80211chan2mhz(ch->channel); > geo_ch->max_power = ch->max_power_avg; > geo_ch->max_antenna_gain = 0xff; > geo_ch->hw_value = ch->channel; >@@ -5133,19 +5132,8 @@ static int iwl3945_init_geos(struct iwl3945_priv *priv) > if (ch->max_power_avg > priv->max_channel_txpower_limit) > priv->max_channel_txpower_limit = > ch->max_power_avg; >- } else { >+ } else > geo_ch->flags |= IEEE80211_CHAN_DISABLED; >- } >- >- /* Save flags for reg domain usage */ >- geo_ch->orig_flags = geo_ch->flags; >- >- IWL_DEBUG_INFO("Channel %d Freq=%d[%sGHz] %s flag=0%X\n", >- ch->channel, geo_ch->center_freq, >- is_channel_a_band(ch) ? "5.2" : "2.4", >- geo_ch->flags & IEEE80211_CHAN_DISABLED ? >- "restricted" : "valid", >- geo_ch->flags); > } > > if ((priv->bands[IEEE80211_BAND_5GHZ].n_channels == 0) && >diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c >index d7e2358..3e1a152 100644 >--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c >+++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c >@@ -4743,7 +4743,7 @@ int iwl4965_init_geos(struct iwl_priv *priv) > if (!channels) > return -ENOMEM; > >- rates = kzalloc((sizeof(struct ieee80211_rate) * (IWL_RATE_COUNT + 1)), >+ rates = kzalloc((sizeof(struct ieee80211_rate) * (IWL_MAX_RATES + 1)), > GFP_KERNEL); > if (!rates) { > kfree(channels); >@@ -4761,9 +4761,8 @@ int iwl4965_init_geos(struct iwl_priv *priv) > > sband = &priv->bands[IEEE80211_BAND_2GHZ]; > sband->channels = channels; >- /* OFDM & CCK */ > sband->bitrates = rates; >- sband->n_bitrates = IWL_RATE_COUNT; >+ sband->n_bitrates = 12; /* OFDM & CCK */ > > iwl4965_init_ht_hw_capab(priv, &sband->ht_info, IEEE80211_BAND_2GHZ); > >@@ -4772,21 +4771,23 @@ int iwl4965_init_geos(struct iwl_priv *priv) > > iwl4965_init_hw_rates(priv, rates); > >- for (i = 0; i < priv->channel_count; i++) { >+ for (i = 0, geo_ch = channels; i < priv->channel_count; i++) { > ch = &priv->channel_info[i]; > >- /* FIXME: might be removed if scan is OK */ >- if (!is_channel_valid(ch)) >+ if (!is_channel_valid(ch)) { >+ IWL_DEBUG_INFO("Channel %d [%sGHz] is restricted -- " >+ "skipping.\n", >+ ch->channel, is_channel_a_band(ch) ? >+ "5.2" : "2.4"); > continue; >+ } > >- if (is_channel_a_band(ch)) >- sband = &priv->bands[IEEE80211_BAND_5GHZ]; >- else >- sband = &priv->bands[IEEE80211_BAND_2GHZ]; >- >- geo_ch = &sband->channels[sband->n_channels++]; >+ if (is_channel_a_band(ch)) { >+ geo_ch = &priv->bands[IEEE80211_BAND_5GHZ].channels[priv->bands[IEEE80211_BAND_5GHZ].n_channels++]; >+ } else >+ geo_ch = &priv->bands[IEEE80211_BAND_2GHZ].channels[priv->bands[IEEE80211_BAND_2GHZ].n_channels++]; > >- geo_ch->center_freq = ieee80211_channel_to_frequency(ch->channel); >+ geo_ch->center_freq = ieee80211chan2mhz(ch->channel); > geo_ch->max_power = ch->max_power_avg; > geo_ch->max_antenna_gain = 0xff; > geo_ch->hw_value = ch->channel; >@@ -4804,19 +4805,8 @@ int iwl4965_init_geos(struct iwl_priv *priv) > if (ch->max_power_avg > priv->max_channel_txpower_limit) > priv->max_channel_txpower_limit = > ch->max_power_avg; >- } else { >+ } else > geo_ch->flags |= IEEE80211_CHAN_DISABLED; >- } >- >- /* Save flags for reg domain usage */ >- geo_ch->orig_flags = geo_ch->flags; >- >- IWL_DEBUG_INFO("Channel %d Freq=%d[%sGHz] %s flag=0%X\n", >- ch->channel, geo_ch->center_freq, >- is_channel_a_band(ch) ? "5.2" : "2.4", >- geo_ch->flags & IEEE80211_CHAN_DISABLED ? >- "restricted" : "valid", >- geo_ch->flags); > } > > if ((priv->bands[IEEE80211_BAND_5GHZ].n_channels == 0) &&
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 439249
:
299368
|
301528
|
301529
| 303200