diff options
author | Winkler, Tomas <tomas.winkler@intel.com> | 2008-12-18 21:37:33 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-01-29 15:59:17 -0500 |
commit | 15b1687cb4f45b87ddbe4dfc7759ff5bb69497d2 (patch) | |
tree | c4e3e70b0d9b7ba877e52cd0a5116c4411bbf8e1 /drivers/net/wireless/iwlwifi/iwl-hcmd.c | |
parent | 39aadf8c29ad959e823efca15381bea9d0770b1e (diff) |
iwlwifi: replace IWL_ERROR with IWL_ERR
IWL_ERR doesn't use hidden priv pointer.
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/net/wireless/iwlwifi/iwl-hcmd.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-hcmd.c | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-hcmd.c b/drivers/net/wireless/iwlwifi/iwl-hcmd.c index 4b35b30e493e..af14d8fdcc79 100644 --- a/drivers/net/wireless/iwlwifi/iwl-hcmd.c +++ b/drivers/net/wireless/iwlwifi/iwl-hcmd.c | |||
@@ -109,14 +109,14 @@ static int iwl_generic_cmd_callback(struct iwl_priv *priv, | |||
109 | struct iwl_rx_packet *pkt = NULL; | 109 | struct iwl_rx_packet *pkt = NULL; |
110 | 110 | ||
111 | if (!skb) { | 111 | if (!skb) { |
112 | IWL_ERROR("Error: Response NULL in %s.\n", | 112 | IWL_ERR(priv, "Error: Response NULL in %s.\n", |
113 | get_cmd_string(cmd->hdr.cmd)); | 113 | get_cmd_string(cmd->hdr.cmd)); |
114 | return 1; | 114 | return 1; |
115 | } | 115 | } |
116 | 116 | ||
117 | pkt = (struct iwl_rx_packet *)skb->data; | 117 | pkt = (struct iwl_rx_packet *)skb->data; |
118 | if (pkt->hdr.flags & IWL_CMD_FAILED_MSK) { | 118 | if (pkt->hdr.flags & IWL_CMD_FAILED_MSK) { |
119 | IWL_ERROR("Bad return from %s (0x%08X)\n", | 119 | IWL_ERR(priv, "Bad return from %s (0x%08X)\n", |
120 | get_cmd_string(cmd->hdr.cmd), pkt->hdr.flags); | 120 | get_cmd_string(cmd->hdr.cmd), pkt->hdr.flags); |
121 | return 1; | 121 | return 1; |
122 | } | 122 | } |
@@ -156,7 +156,7 @@ static int iwl_send_cmd_async(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
156 | 156 | ||
157 | ret = iwl_enqueue_hcmd(priv, cmd); | 157 | ret = iwl_enqueue_hcmd(priv, cmd); |
158 | if (ret < 0) { | 158 | if (ret < 0) { |
159 | IWL_ERROR("Error sending %s: enqueue_hcmd failed: %d\n", | 159 | IWL_ERR(priv, "Error sending %s: enqueue_hcmd failed: %d\n", |
160 | get_cmd_string(cmd->id), ret); | 160 | get_cmd_string(cmd->id), ret); |
161 | return ret; | 161 | return ret; |
162 | } | 162 | } |
@@ -174,8 +174,9 @@ int iwl_send_cmd_sync(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
174 | BUG_ON(cmd->meta.u.callback != NULL); | 174 | BUG_ON(cmd->meta.u.callback != NULL); |
175 | 175 | ||
176 | if (test_and_set_bit(STATUS_HCMD_SYNC_ACTIVE, &priv->status)) { | 176 | if (test_and_set_bit(STATUS_HCMD_SYNC_ACTIVE, &priv->status)) { |
177 | IWL_ERROR("Error sending %s: Already sending a host command\n", | 177 | IWL_ERR(priv, |
178 | get_cmd_string(cmd->id)); | 178 | "Error sending %s: Already sending a host command\n", |
179 | get_cmd_string(cmd->id)); | ||
179 | ret = -EBUSY; | 180 | ret = -EBUSY; |
180 | goto out; | 181 | goto out; |
181 | } | 182 | } |
@@ -188,7 +189,7 @@ int iwl_send_cmd_sync(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
188 | cmd_idx = iwl_enqueue_hcmd(priv, cmd); | 189 | cmd_idx = iwl_enqueue_hcmd(priv, cmd); |
189 | if (cmd_idx < 0) { | 190 | if (cmd_idx < 0) { |
190 | ret = cmd_idx; | 191 | ret = cmd_idx; |
191 | IWL_ERROR("Error sending %s: enqueue_hcmd failed: %d\n", | 192 | IWL_ERR(priv, "Error sending %s: enqueue_hcmd failed: %d\n", |
192 | get_cmd_string(cmd->id), ret); | 193 | get_cmd_string(cmd->id), ret); |
193 | goto out; | 194 | goto out; |
194 | } | 195 | } |
@@ -198,9 +199,10 @@ int iwl_send_cmd_sync(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
198 | HOST_COMPLETE_TIMEOUT); | 199 | HOST_COMPLETE_TIMEOUT); |
199 | if (!ret) { | 200 | if (!ret) { |
200 | if (test_bit(STATUS_HCMD_ACTIVE, &priv->status)) { | 201 | if (test_bit(STATUS_HCMD_ACTIVE, &priv->status)) { |
201 | IWL_ERROR("Error sending %s: time out after %dms.\n", | 202 | IWL_ERR(priv, |
202 | get_cmd_string(cmd->id), | 203 | "Error sending %s: time out after %dms.\n", |
203 | jiffies_to_msecs(HOST_COMPLETE_TIMEOUT)); | 204 | get_cmd_string(cmd->id), |
205 | jiffies_to_msecs(HOST_COMPLETE_TIMEOUT)); | ||
204 | 206 | ||
205 | clear_bit(STATUS_HCMD_ACTIVE, &priv->status); | 207 | clear_bit(STATUS_HCMD_ACTIVE, &priv->status); |
206 | ret = -ETIMEDOUT; | 208 | ret = -ETIMEDOUT; |
@@ -221,7 +223,7 @@ int iwl_send_cmd_sync(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
221 | goto fail; | 223 | goto fail; |
222 | } | 224 | } |
223 | if ((cmd->meta.flags & CMD_WANT_SKB) && !cmd->meta.u.skb) { | 225 | if ((cmd->meta.flags & CMD_WANT_SKB) && !cmd->meta.u.skb) { |
224 | IWL_ERROR("Error: Response NULL in '%s'\n", | 226 | IWL_ERR(priv, "Error: Response NULL in '%s'\n", |
225 | get_cmd_string(cmd->id)); | 227 | get_cmd_string(cmd->id)); |
226 | ret = -EIO; | 228 | ret = -EIO; |
227 | goto cancel; | 229 | goto cancel; |