Skip to content

Commit

Permalink
iwlwifi: Fix uCode error on association
Browse files Browse the repository at this point in the history
The problem is that priv->assoc_id is set when assoc. resp frame is
received. But, when it is set, LQ cmd is still not sent to the uCode, it is
done from bg_post_assoc, which is called through a workqueue.

On the other hand, when a tx arrives at the moment when this flag is set,
but LQ is still not sent, the if condition in tx_skb will not hold and
the frame will not be dropped.  Thus, it will be sent through
which is still not in the sta table in the uCoded.

Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Gregory Greenman authored and David S. Miller committed Feb 1, 2008
1 parent 25c03d8 commit 76f3915
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 0 additions & 1 deletion drivers/net/wireless/iwlwifi/iwl-3945.h
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,6 @@ struct iwl3945_priv {
u16 active_rate_basic;

u8 call_post_assoc_from_beacon;
u8 assoc_station_added;
/* Rate scaling data */
s8 data_retry_limit;
u8 retry_rate;
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/wireless/iwlwifi/iwl3945-base.c
Original file line number Diff line number Diff line change
Expand Up @@ -2806,7 +2806,7 @@ static int iwl3945_tx_skb(struct iwl3945_priv *priv,
#endif

/* drop all data frame if we are not associated */
if (!iwl3945_is_associated(priv) && !priv->assoc_id &&
if ((!iwl3945_is_associated(priv) || !priv->assoc_id) &&
((fc & IEEE80211_FCTL_FTYPE) == IEEE80211_FTYPE_DATA)) {
IWL_DEBUG_DROP("Dropping - !iwl3945_is_associated\n");
goto drop_unlock;
Expand Down
6 changes: 4 additions & 2 deletions drivers/net/wireless/iwlwifi/iwl4965-base.c
Original file line number Diff line number Diff line change
Expand Up @@ -2933,8 +2933,10 @@ static int iwl4965_tx_skb(struct iwl4965_priv *priv,
#endif

/* drop all data frame if we are not associated */
if (!iwl4965_is_associated(priv) && !priv->assoc_id &&
((fc & IEEE80211_FCTL_FTYPE) == IEEE80211_FTYPE_DATA)) {
if (((fc & IEEE80211_FCTL_FTYPE) == IEEE80211_FTYPE_DATA) &&
(!iwl4965_is_associated(priv) ||
!priv->assoc_id ||
!priv->assoc_station_added)) {
IWL_DEBUG_DROP("Dropping - !iwl4965_is_associated\n");
goto drop_unlock;
}
Expand Down

0 comments on commit 76f3915

Please sign in to comment.