aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-3945.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-3945.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c
index 59e2fa270924..077fa1023fe5 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.c
@@ -96,7 +96,7 @@ const struct iwl_rate_info iwl_rates[IWL_RATE_COUNT] = {
96 * ... and set IWL_EVT_DISABLE to 1. */ 96 * ... and set IWL_EVT_DISABLE to 1. */
97void iwl_disable_events(struct iwl_priv *priv) 97void iwl_disable_events(struct iwl_priv *priv)
98{ 98{
99 int rc; 99 int ret;
100 int i; 100 int i;
101 u32 base; /* SRAM address of event log header */ 101 u32 base; /* SRAM address of event log header */
102 u32 disable_ptr; /* SRAM address of event-disable bitmap array */ 102 u32 disable_ptr; /* SRAM address of event-disable bitmap array */
@@ -157,25 +157,24 @@ void iwl_disable_events(struct iwl_priv *priv)
157 return; 157 return;
158 } 158 }
159 159
160 rc = iwl_grab_restricted_access(priv); 160 ret = iwl_grab_restricted_access(priv);
161 if (rc) { 161 if (ret) {
162 IWL_WARNING("Can not read from adapter at this time.\n"); 162 IWL_WARNING("Can not read from adapter at this time.\n");
163 return; 163 return;
164 } 164 }
165 165
166 disable_ptr = iwl_read_restricted_mem(priv, base + (4 * sizeof(u32))); 166 disable_ptr = iwl_read_targ_mem(priv, base + (4 * sizeof(u32)));
167 array_size = iwl_read_restricted_mem(priv, base + (5 * sizeof(u32))); 167 array_size = iwl_read_targ_mem(priv, base + (5 * sizeof(u32)));
168 iwl_release_restricted_access(priv); 168 iwl_release_restricted_access(priv);
169 169
170 if (IWL_EVT_DISABLE && (array_size == IWL_EVT_DISABLE_SIZE)) { 170 if (IWL_EVT_DISABLE && (array_size == IWL_EVT_DISABLE_SIZE)) {
171 IWL_DEBUG_INFO("Disabling selected uCode log events at 0x%x\n", 171 IWL_DEBUG_INFO("Disabling selected uCode log events at 0x%x\n",
172 disable_ptr); 172 disable_ptr);
173 rc = iwl_grab_restricted_access(priv); 173 ret = iwl_grab_restricted_access(priv);
174 for (i = 0; i < IWL_EVT_DISABLE_SIZE; i++) 174 for (i = 0; i < IWL_EVT_DISABLE_SIZE; i++)
175 iwl_write_restricted_mem(priv, 175 iwl_write_targ_mem(priv,
176 disable_ptr + 176 disable_ptr + (i * sizeof(u32)),
177 (i * sizeof(u32)), 177 evt_disable[i]);
178 evt_disable[i]);
179 178
180 iwl_release_restricted_access(priv); 179 iwl_release_restricted_access(priv);
181 } else { 180 } else {