diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2011-08-26 02:10:48 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-08-29 15:25:32 -0400 |
commit | e6bb4c9c00892c488f3218ea317dc6a71674faf4 (patch) | |
tree | 3afe043aee2c5e73978259393b8242baf2acd886 /drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c | |
parent | f39c95e8d7a152b409977687a999356f0e54bde6 (diff) |
iwlagn: bus layer chooses its transport layer
Remove iwl_transport_register which was a W/A. The bus layer knows what
transport to use. So now, the bus layer gives the upper layer a pointer to the
iwl_trans_ops struct that it wants to use. The upper layer then, allocates the
desired transport layer using iwl_trans_ops->alloc function.
As a result of this, priv->trans, no longer exists, priv holds a pointer to
iwl_shared, which holds a pointer to iwl_trans. This required to change all the
calls to the transport layer from upper layer. While we were at it, trans_X
inlines have been renamed to iwl_trans_X to avoid confusions, which of course
required to rename the functions inside the transport layer because of
conflicts in names. So the static API functions inside the transport layer
implementation have been renamed to iwl_trans_pcie_X.
Until now, the IRQ / Tasklet were initialized in iwl_transport_layer. This is
confusing since the registration doesn't mean to request IRQ, so I added a
handler for that.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c b/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c index b0ad127715f6..9d7287e7a992 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c +++ b/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c | |||
@@ -422,7 +422,7 @@ void iwl_trans_tx_queue_set_status(struct iwl_priv *priv, | |||
422 | scd_retry ? "BA" : "AC/CMD", txq_id, tx_fifo_id); | 422 | scd_retry ? "BA" : "AC/CMD", txq_id, tx_fifo_id); |
423 | } | 423 | } |
424 | 424 | ||
425 | void iwl_trans_txq_agg_setup(struct iwl_priv *priv, int sta_id, int tid, | 425 | void iwl_trans_pcie_txq_agg_setup(struct iwl_priv *priv, int sta_id, int tid, |
426 | int frame_limit) | 426 | int frame_limit) |
427 | { | 427 | { |
428 | int tx_fifo, txq_id, ssn_idx; | 428 | int tx_fifo, txq_id, ssn_idx; |
@@ -483,7 +483,7 @@ void iwl_trans_txq_agg_setup(struct iwl_priv *priv, int sta_id, int tid, | |||
483 | spin_unlock_irqrestore(&priv->shrd->lock, flags); | 483 | spin_unlock_irqrestore(&priv->shrd->lock, flags); |
484 | } | 484 | } |
485 | 485 | ||
486 | int iwl_trans_txq_agg_disable(struct iwl_priv *priv, u16 txq_id, | 486 | int iwl_trans_pcie_txq_agg_disable(struct iwl_priv *priv, u16 txq_id, |
487 | u16 ssn_idx, u8 tx_fifo) | 487 | u16 ssn_idx, u8 tx_fifo) |
488 | { | 488 | { |
489 | if ((IWLAGN_FIRST_AMPDU_QUEUE > txq_id) || | 489 | if ((IWLAGN_FIRST_AMPDU_QUEUE > txq_id) || |
@@ -1015,7 +1015,7 @@ fail: | |||
1015 | return ret; | 1015 | return ret; |
1016 | } | 1016 | } |
1017 | 1017 | ||
1018 | int iwl_send_cmd(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | 1018 | int iwl_trans_pcie_send_cmd(struct iwl_priv *priv, struct iwl_host_cmd *cmd) |
1019 | { | 1019 | { |
1020 | if (cmd->flags & CMD_ASYNC) | 1020 | if (cmd->flags & CMD_ASYNC) |
1021 | return iwl_send_cmd_async(priv, cmd); | 1021 | return iwl_send_cmd_async(priv, cmd); |
@@ -1023,8 +1023,8 @@ int iwl_send_cmd(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
1023 | return iwl_send_cmd_sync(priv, cmd); | 1023 | return iwl_send_cmd_sync(priv, cmd); |
1024 | } | 1024 | } |
1025 | 1025 | ||
1026 | int iwl_send_cmd_pdu(struct iwl_priv *priv, u8 id, u32 flags, u16 len, | 1026 | int iwl_trans_pcie_send_cmd_pdu(struct iwl_priv *priv, u8 id, u32 flags, |
1027 | const void *data) | 1027 | u16 len, const void *data) |
1028 | { | 1028 | { |
1029 | struct iwl_host_cmd cmd = { | 1029 | struct iwl_host_cmd cmd = { |
1030 | .id = id, | 1030 | .id = id, |
@@ -1033,5 +1033,5 @@ int iwl_send_cmd_pdu(struct iwl_priv *priv, u8 id, u32 flags, u16 len, | |||
1033 | .flags = flags, | 1033 | .flags = flags, |
1034 | }; | 1034 | }; |
1035 | 1035 | ||
1036 | return iwl_send_cmd(priv, &cmd); | 1036 | return iwl_trans_pcie_send_cmd(priv, &cmd); |
1037 | } | 1037 | } |