summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-trans.h
diff options
context:
space:
mode:
authorMeenakshi Venkataraman <meenakshi.venkataraman@intel.com>2012-03-08 11:29:12 -0800
committerJohn W. Linville <linville@tuxdriver.com>2012-03-09 11:32:58 -0500
commitc6f600fcfe8a7e4f594fc4c80b2c7b66f248958b (patch)
treed96a59fa8cfd31fe94ff22fe2708c5bdeeadbc26 /drivers/net/wireless/iwlwifi/iwl-trans.h
parent8763848e03a9098e5b6f81428a98738dc960a436 (diff)
downloadblackbird-op-linux-c6f600fcfe8a7e4f594fc4c80b2c7b66f248958b.tar.gz
blackbird-op-linux-c6f600fcfe8a7e4f594fc4c80b2c7b66f248958b.zip
iwlwifi: move command queue number out of the iwl_shared struct
The command queue number is required by the transport layer, but it can be determined only by the op mode. Move this parameter to the dvm op mode, and configure the transport layer using an API. Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@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.h')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-trans.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans.h b/drivers/net/wireless/iwlwifi/iwl-trans.h
index b6fd42779624..a40c2726c190 100644
--- a/drivers/net/wireless/iwlwifi/iwl-trans.h
+++ b/drivers/net/wireless/iwlwifi/iwl-trans.h
@@ -279,9 +279,12 @@ static inline struct page *rxb_steal_page(struct iwl_rx_cmd_buffer *r)
*
* @op_mode: pointer to the upper layer.
* Must be set before any other call.
+ * @cmd_queue: the index of the command queue.
+ * Must be set before start_fw.
*/
struct iwl_trans_config {
struct iwl_op_mode *op_mode;
+ u8 cmd_queue;
};
/**
@@ -331,6 +334,8 @@ struct iwl_trans_config {
* @write8: write a u8 to a register at offset ofs from the BAR
* @write32: write a u32 to a register at offset ofs from the BAR
* @read32: read a u32 register at offset ofs from the BAR
+ * @configure: configure parameters required by the transport layer from
+ * the op_mode.
*/
struct iwl_trans_ops {
@@ -370,6 +375,8 @@ struct iwl_trans_ops {
void (*write8)(struct iwl_trans *trans, u32 ofs, u8 val);
void (*write32)(struct iwl_trans *trans, u32 ofs, u32 val);
u32 (*read32)(struct iwl_trans *trans, u32 ofs);
+ void (*configure)(struct iwl_trans *trans,
+ const struct iwl_trans_config *trans_cfg);
};
/**
@@ -425,6 +432,8 @@ static inline void iwl_trans_configure(struct iwl_trans *trans,
* more
*/
trans->op_mode = trans_cfg->op_mode;
+
+ trans->ops->configure(trans, trans_cfg);
}
static inline int iwl_trans_start_hw(struct iwl_trans *trans)
OpenPOWER on IntegriCloud