> --- a/drivers/net/wireless/iwlwifi/iwl4965-base.c > +++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c > @@ -1936,7 +1936,7 @@ static void iwl4965_build_tx_cmd_hwcrypto(struct iwl_priv *priv, > struct iwl_wep_key *wepkey; > int keyidx = 0; > > - BUG_ON(ctl->key_idx > 3); > + BUG_ON(ctl->hw_key->hw_key_idx > 3); > > switch (keyinfo->alg) { > case ALG_CCMP: > @@ -1955,11 +1955,11 @@ static void iwl4965_build_tx_cmd_hwcrypto(struct iwl_priv *priv, > break; > > case ALG_WEP: > - wepkey = &priv->wep_keys[ctl->key_idx]; > + wepkey = &priv->wep_keys[ctl->hw_key->hw_key_idx]; > cmd->cmd.tx.sec_ctl = 0; > if (priv->default_wep_key) { > /* the WEP key was sent as static */ > - keyidx = ctl->key_idx; > + keyidx = ctl->hw_key->hw_key_idx; > memcpy(&cmd->cmd.tx.key[3], wepkey->key, > wepkey->key_size); > if (wepkey->key_size == WEP_KEY_LEN_128) All this is rather odd. I think you (Intel) may want to change it to use hw_key->keyidx and just leave the hw_key_idx alone, it seems to be a copy of keyidx in iwl4965 but an actual index as it was meant to be used in iwl3945? johannes
Attachment:
signature.asc
Description: This is a digitally signed message part