Skip to content

Commit

Permalink
iwlwifi: fix mis-merge that breaks the driver
Browse files Browse the repository at this point in the history
My laptop that uses the intel 7680 iwlwifi module would no longer
connects to the network.  It would fail with a "Microcode SW error
detected." and spew out register state over and over again without ever
connecting to the network.

The cause is mis-merge in commit 909b27f, where David seems to have
lost some of the changes to iwl_mvm_set_tx_cmd() from commit
5c08b0f ("iwlwifi: mvm: don't override the rate with the AMSDU
len").

The reason seems to be a conflict with commit d8fe484 ("iwlwifi:
mvm: add support for new TX CMD API"), which touched a line adjacent to
the changes in 909b27f.

David missed the fact that "info->driver_data[0]" had become
"skb_info->driver_data[0]".  Then he removed the skb_info because it was
unused.

This just re-updates iwl_mvm_set_tx_cmd() with the lost two lines.

Reported-and-tested-by: Linus Torvalds <torvalds@linux-foundation.org>
Reported-by: Reinoud Koornstra <reinoudkoornstra@gmail.com>
Cc: Luciano Coelho <luciano.coelho@intel.com>
Cc: Kalle Valo <kvalo@codeaurora.org>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Linus Torvalds committed May 18, 2016
1 parent 9e17632 commit 0e034f5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/wireless/intel/iwlwifi/mvm/tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
struct iwl_tx_cmd *tx_cmd,
struct ieee80211_tx_info *info, u8 sta_id)
{
struct ieee80211_tx_info *skb_info = IEEE80211_SKB_CB(skb);
struct ieee80211_hdr *hdr = (void *)skb->data;
__le16 fc = hdr->frame_control;
u32 tx_flags = le32_to_cpu(tx_cmd->tx_flags);
Expand Down Expand Up @@ -294,7 +295,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
tx_cmd->tx_flags = cpu_to_le32(tx_flags);
/* Total # bytes to be transmitted */
tx_cmd->len = cpu_to_le16((u16)skb->len +
(uintptr_t)info->driver_data[0]);
(uintptr_t)skb_info->driver_data[0]);
tx_cmd->life_time = cpu_to_le32(TX_CMD_LIFE_TIME_INFINITE);
tx_cmd->sta_id = sta_id;

Expand Down

0 comments on commit 0e034f5

Please sign in to comment.