diff options
Diffstat (limited to 'drivers/net/wireless/iwmc3200wifi/hal.c')
-rw-r--r-- | drivers/net/wireless/iwmc3200wifi/hal.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/net/wireless/iwmc3200wifi/hal.c b/drivers/net/wireless/iwmc3200wifi/hal.c index 229de990379c..9531b18cf72a 100644 --- a/drivers/net/wireless/iwmc3200wifi/hal.c +++ b/drivers/net/wireless/iwmc3200wifi/hal.c | |||
@@ -105,6 +105,7 @@ | |||
105 | #include "hal.h" | 105 | #include "hal.h" |
106 | #include "umac.h" | 106 | #include "umac.h" |
107 | #include "debug.h" | 107 | #include "debug.h" |
108 | #include "trace.h" | ||
108 | 109 | ||
109 | static int iwm_nonwifi_cmd_init(struct iwm_priv *iwm, | 110 | static int iwm_nonwifi_cmd_init(struct iwm_priv *iwm, |
110 | struct iwm_nonwifi_cmd *cmd, | 111 | struct iwm_nonwifi_cmd *cmd, |
@@ -207,9 +208,9 @@ void iwm_cmd_flush(struct iwm_priv *iwm) | |||
207 | 208 | ||
208 | struct iwm_wifi_cmd *iwm_get_pending_wifi_cmd(struct iwm_priv *iwm, u16 seq_num) | 209 | struct iwm_wifi_cmd *iwm_get_pending_wifi_cmd(struct iwm_priv *iwm, u16 seq_num) |
209 | { | 210 | { |
210 | struct iwm_wifi_cmd *cmd, *next; | 211 | struct iwm_wifi_cmd *cmd; |
211 | 212 | ||
212 | list_for_each_entry_safe(cmd, next, &iwm->wifi_pending_cmd, pending) | 213 | list_for_each_entry(cmd, &iwm->wifi_pending_cmd, pending) |
213 | if (cmd->seq_num == seq_num) { | 214 | if (cmd->seq_num == seq_num) { |
214 | list_del(&cmd->pending); | 215 | list_del(&cmd->pending); |
215 | return cmd; | 216 | return cmd; |
@@ -218,12 +219,12 @@ struct iwm_wifi_cmd *iwm_get_pending_wifi_cmd(struct iwm_priv *iwm, u16 seq_num) | |||
218 | return NULL; | 219 | return NULL; |
219 | } | 220 | } |
220 | 221 | ||
221 | struct iwm_nonwifi_cmd * | 222 | struct iwm_nonwifi_cmd *iwm_get_pending_nonwifi_cmd(struct iwm_priv *iwm, |
222 | iwm_get_pending_nonwifi_cmd(struct iwm_priv *iwm, u8 seq_num, u8 cmd_opcode) | 223 | u8 seq_num, u8 cmd_opcode) |
223 | { | 224 | { |
224 | struct iwm_nonwifi_cmd *cmd, *next; | 225 | struct iwm_nonwifi_cmd *cmd; |
225 | 226 | ||
226 | list_for_each_entry_safe(cmd, next, &iwm->nonwifi_pending_cmd, pending) | 227 | list_for_each_entry(cmd, &iwm->nonwifi_pending_cmd, pending) |
227 | if ((cmd->seq_num == seq_num) && | 228 | if ((cmd->seq_num == seq_num) && |
228 | (cmd->udma_cmd.opcode == cmd_opcode) && | 229 | (cmd->udma_cmd.opcode == cmd_opcode) && |
229 | (cmd->resp_received)) { | 230 | (cmd->resp_received)) { |
@@ -277,6 +278,7 @@ static int iwm_send_udma_nonwifi_cmd(struct iwm_priv *iwm, | |||
277 | udma_cmd->handle_by_hw, cmd->seq_num, udma_cmd->addr, | 278 | udma_cmd->handle_by_hw, cmd->seq_num, udma_cmd->addr, |
278 | udma_cmd->op1_sz, udma_cmd->op2); | 279 | udma_cmd->op1_sz, udma_cmd->op2); |
279 | 280 | ||
281 | trace_iwm_tx_nonwifi_cmd(iwm, udma_hdr); | ||
280 | return iwm_bus_send_chunk(iwm, buf->start, buf->len); | 282 | return iwm_bus_send_chunk(iwm, buf->start, buf->len); |
281 | } | 283 | } |
282 | 284 | ||
@@ -363,6 +365,7 @@ static int iwm_send_udma_wifi_cmd(struct iwm_priv *iwm, | |||
363 | return ret; | 365 | return ret; |
364 | } | 366 | } |
365 | 367 | ||
368 | trace_iwm_tx_wifi_cmd(iwm, umac_hdr); | ||
366 | return iwm_bus_send_chunk(iwm, buf->start, buf->len); | 369 | return iwm_bus_send_chunk(iwm, buf->start, buf->len); |
367 | } | 370 | } |
368 | 371 | ||