iwlwifi: remove TX_CMD id from transport layer
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Tue, 22 Oct 2013 08:27:55 +0000 (11:27 +0300)
committerEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Mon, 9 Dec 2013 20:27:56 +0000 (22:27 +0200)
The transport layer doesn't need to know the TX_CMD id.
It can be set by the op_mode.
The transport layer still needs to know the layout of the
Tx command because of alignment issues and because of the
scratch pointer.

Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
drivers/net/wireless/iwlwifi/dvm/tx.c
drivers/net/wireless/iwlwifi/mvm/tx.c
drivers/net/wireless/iwlwifi/pcie/tx.c

index 1fef5240e6adc07317b7128bf7d7617385fa9aa8..e12b1a63c484635f64a23f0e27904045a8185cc2 100644 (file)
@@ -368,6 +368,7 @@ int iwlagn_tx_skb(struct iwl_priv *priv,
                goto drop_unlock_priv;
 
        memset(dev_cmd, 0, sizeof(*dev_cmd));
+       dev_cmd->hdr.cmd = REPLY_TX;
        tx_cmd = (struct iwl_tx_cmd *) dev_cmd->payload;
 
        /* Total # bytes to be transmitted */
index 43d97c33a75abcbf3833958b0c5cbca5a91e0950..1f19458064219eb80615c1eed3423cc778c30a8f 100644 (file)
@@ -276,6 +276,7 @@ iwl_mvm_set_tx_params(struct iwl_mvm *mvm, struct sk_buff *skb,
                return NULL;
 
        memset(dev_cmd, 0, sizeof(*dev_cmd));
+       dev_cmd->hdr.cmd = TX_CMD;
        tx_cmd = (struct iwl_tx_cmd *)dev_cmd->payload;
 
        if (info->control.hw_key)
index 0adde919a258a65f9585651e8efb89add27f2add..ff977b08341155bcf190ccc8da3a6f0c2279c5be 100644 (file)
@@ -1674,7 +1674,6 @@ int iwl_trans_pcie_tx(struct iwl_trans *trans, struct sk_buff *skb,
        txq->entries[q->write_ptr].skb = skb;
        txq->entries[q->write_ptr].cmd = dev_cmd;
 
-       dev_cmd->hdr.cmd = REPLY_TX;
        dev_cmd->hdr.sequence =
                cpu_to_le16((u16)(QUEUE_TO_SEQ(txq_id) |
                            INDEX_TO_SEQ(q->write_ptr)));