diff options
author | Winkler, Tomas <tomas.winkler@intel.com> | 2009-01-08 13:19:55 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-01-29 16:00:13 -0500 |
commit | 625a381ab870b190c1899c08467c0e6dcc5d94d4 (patch) | |
tree | d247031a25646333f2403a7ca37d3db961433aee /drivers | |
parent | 37d68317add2b769ad232a5d199bece41c59e13f (diff) |
iwl3945: kill iwl3945_x2_queue_used
This patch replaces iwl3945_x2_queue_used with iwl_queue_used.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-3945.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-3945.h | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl3945-base.c | 9 |
3 files changed, 2 insertions, 11 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c index 24d818d1b06b..db7b949020c2 100644 --- a/drivers/net/wireless/iwlwifi/iwl-3945.c +++ b/drivers/net/wireless/iwlwifi/iwl-3945.c | |||
@@ -344,7 +344,7 @@ static void iwl3945_rx_reply_tx(struct iwl_priv *priv, | |||
344 | int rate_idx; | 344 | int rate_idx; |
345 | int fail; | 345 | int fail; |
346 | 346 | ||
347 | if ((index >= txq->q.n_bd) || (iwl3945_x2_queue_used(&txq->q, index) == 0)) { | 347 | if ((index >= txq->q.n_bd) || (iwl_queue_used(&txq->q, index) == 0)) { |
348 | IWL_ERR(priv, "Read index for DMA queue txq_id (%d) index %d " | 348 | IWL_ERR(priv, "Read index for DMA queue txq_id (%d) index %d " |
349 | "is out of range [0-%d] %d %d\n", txq_id, | 349 | "is out of range [0-%d] %d %d\n", txq_id, |
350 | index, txq->q.n_bd, txq->q.write_ptr, | 350 | index, txq->q.n_bd, txq->q.write_ptr, |
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.h b/drivers/net/wireless/iwlwifi/iwl-3945.h index 3041616d39cc..be3013453359 100644 --- a/drivers/net/wireless/iwlwifi/iwl-3945.h +++ b/drivers/net/wireless/iwlwifi/iwl-3945.h | |||
@@ -106,8 +106,6 @@ enum iwl3945_antenna { | |||
106 | #define DEFAULT_SHORT_RETRY_LIMIT 7U | 106 | #define DEFAULT_SHORT_RETRY_LIMIT 7U |
107 | #define DEFAULT_LONG_RETRY_LIMIT 4U | 107 | #define DEFAULT_LONG_RETRY_LIMIT 4U |
108 | 108 | ||
109 | int iwl3945_x2_queue_used(const struct iwl_queue *q, int i); | ||
110 | |||
111 | #include "iwl-agn-rs.h" | 109 | #include "iwl-agn-rs.h" |
112 | 110 | ||
113 | #define IWL_TX_FIFO_AC0 0 | 111 | #define IWL_TX_FIFO_AC0 0 |
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index eacef54636a0..e05a9d604b9b 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -120,13 +120,6 @@ struct iwl_mod_params iwl3945_mod_params = { | |||
120 | * (#0-3) for data tx via EDCA. An additional 2 HCCA queues are unused. | 120 | * (#0-3) for data tx via EDCA. An additional 2 HCCA queues are unused. |
121 | ***************************************************/ | 121 | ***************************************************/ |
122 | 122 | ||
123 | int iwl3945_x2_queue_used(const struct iwl_queue *q, int i) | ||
124 | { | ||
125 | return q->write_ptr > q->read_ptr ? | ||
126 | (i >= q->read_ptr && i < q->write_ptr) : | ||
127 | !(i < q->read_ptr && i >= q->write_ptr); | ||
128 | } | ||
129 | |||
130 | /** | 123 | /** |
131 | * iwl3945_queue_init - Initialize queue's high/low-water and read/write indexes | 124 | * iwl3945_queue_init - Initialize queue's high/low-water and read/write indexes |
132 | */ | 125 | */ |
@@ -3079,7 +3072,7 @@ static void iwl3945_cmd_queue_reclaim(struct iwl_priv *priv, | |||
3079 | struct iwl_queue *q = &txq->q; | 3072 | struct iwl_queue *q = &txq->q; |
3080 | int nfreed = 0; | 3073 | int nfreed = 0; |
3081 | 3074 | ||
3082 | if ((index >= q->n_bd) || (iwl3945_x2_queue_used(q, index) == 0)) { | 3075 | if ((index >= q->n_bd) || (iwl_queue_used(q, index) == 0)) { |
3083 | IWL_ERR(priv, "Read index for DMA queue txq id (%d), index %d, " | 3076 | IWL_ERR(priv, "Read index for DMA queue txq id (%d), index %d, " |
3084 | "is out of range [0-%d] %d %d.\n", txq_id, | 3077 | "is out of range [0-%d] %d %d.\n", txq_id, |
3085 | index, q->n_bd, q->write_ptr, q->read_ptr); | 3078 | index, q->n_bd, q->write_ptr, q->read_ptr); |