Commit 9406f797 authored by Stanislaw Gruszka's avatar Stanislaw Gruszka

iwlegacy: remove il argument from IWL_ERR/INFO/WARN/CRIT

Signed-off-by: default avatarStanislaw Gruszka <sgruszka@redhat.com>
parent 58de00a4
......@@ -71,7 +71,7 @@ ssize_t il3945_ucode_rx_stats_read(struct file *file,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -341,7 +341,7 @@ ssize_t il3945_ucode_tx_stats_read(struct file *file,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -440,7 +440,7 @@ ssize_t il3945_ucode_general_stats_read(struct file *file,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......
......@@ -166,7 +166,7 @@ void il3945_disable_events(struct il_priv *il)
base = le32_to_cpu(il->card_alive.log_event_table_ptr);
if (!il3945_hw_valid_rtc_data_addr(base)) {
IL_ERR(il, "Invalid event log pointer 0x%08X\n", base);
IL_ERR("Invalid event log pointer 0x%08X\n", base);
return;
}
......@@ -317,7 +317,7 @@ static void il3945_rx_reply_tx(struct il_priv *il,
int fail;
if ((index >= txq->q.n_bd) || (il_queue_used(&txq->q, index) == 0)) {
IL_ERR(il, "Read index for DMA queue txq_id (%d) index %d "
IL_ERR("Read index for DMA queue txq_id (%d) index %d "
"is out of range [0-%d] %d %d\n", txq_id,
index, txq->q.n_bd, txq->q.write_ptr,
txq->q.read_ptr);
......@@ -350,7 +350,7 @@ static void il3945_rx_reply_tx(struct il_priv *il,
il3945_tx_queue_reclaim(il, txq_id, index);
if (status & TX_ABORT_REQUIRED_MSK)
IL_ERR(il, "TODO: Implement Tx ABORT REQUIRED!!!\n");
IL_ERR("TODO: Implement Tx ABORT REQUIRED!!!\n");
}
......@@ -484,7 +484,7 @@ static void il3945_pass_packet_to_mac80211(struct il_priv *il,
skb = dev_alloc_skb(128);
if (!skb) {
IL_ERR(il, "dev_alloc_skb failed\n");
IL_ERR("dev_alloc_skb failed\n");
return;
}
......@@ -600,7 +600,7 @@ int il3945_hw_txq_attach_buf_to_tfd(struct il_priv *il,
count = TFD_CTL_COUNT_GET(le32_to_cpu(tfd->control_flags));
if ((count >= NUM_TFD_CHUNKS) || (count < 0)) {
IL_ERR(il, "Error can not send more than %d chunks\n",
IL_ERR("Error can not send more than %d chunks\n",
NUM_TFD_CHUNKS);
return -EINVAL;
}
......@@ -633,7 +633,7 @@ void il3945_hw_txq_free_tfd(struct il_priv *il, struct il_tx_queue *txq)
/* sanity check */
counter = TFD_CTL_COUNT_GET(le32_to_cpu(tfd->control_flags));
if (counter > NUM_TFD_CHUNKS) {
IL_ERR(il, "Too many chunks: %i\n", counter);
IL_ERR("Too many chunks: %i\n", counter);
/* @todo issue fatal error, it is quite serious situation */
return;
}
......@@ -855,7 +855,7 @@ static int il3945_txq_ctx_reset(struct il_priv *il)
rc = il_tx_queue_init(il, &il->txq[txq_id],
slots_num, txq_id);
if (rc) {
IL_ERR(il, "Tx %d queue init failed\n", txq_id);
IL_ERR("Tx %d queue init failed\n", txq_id);
goto error;
}
}
......@@ -971,7 +971,7 @@ int il3945_hw_nic_init(struct il_priv *il)
if (!rxq->bd) {
rc = il_rx_queue_alloc(il);
if (rc) {
IL_ERR(il, "Unable to initialize Rx queue\n");
IL_ERR("Unable to initialize Rx queue\n");
return -ENOMEM;
}
} else
......@@ -1078,7 +1078,7 @@ static int il3945_hw_reg_txpower_get_temperature(struct il_priv *il)
/* handle insane temp reading */
if (il3945_hw_reg_temp_out_of_range(temperature)) {
IL_ERR(il, "Error bad temperature value %d\n", temperature);
IL_ERR("Error bad temperature value %d\n", temperature);
/* if really really hot(?),
* substitute the 3rd band/group's temp measured at factory */
......@@ -1388,7 +1388,7 @@ static int il3945_send_tx_power(struct il_priv *il)
txpower.band = (il->band == IEEE80211_BAND_5GHZ) ? 0 : 1;
ch_info = il_get_channel_info(il, il->band, chan);
if (!ch_info) {
IL_ERR(il,
IL_ERR(
"Failed to get channel info for channel %d [%d]\n",
chan, il->band);
return -EINVAL;
......@@ -1686,7 +1686,7 @@ static int il3945_send_rxon_assoc(struct il_priv *il,
pkt = (struct il_rx_packet *)cmd.reply_page;
if (pkt->hdr.flags & IL_CMD_FAILED_MSK) {
IL_ERR(il, "Bad return from REPLY_RXON_ASSOC command\n");
IL_ERR("Bad return from REPLY_RXON_ASSOC command\n");
rc = -EIO;
}
......@@ -1727,7 +1727,7 @@ int il3945_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
rc = il_check_rxon_cmd(il, ctx);
if (rc) {
IL_ERR(il, "Invalid RXON configuration. Not committing.\n");
IL_ERR("Invalid RXON configuration. Not committing.\n");
return -EINVAL;
}
......@@ -1739,7 +1739,7 @@ int il3945_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
rc = il_send_rxon_assoc(il,
&il->contexts[IL_RXON_CTX_BSS]);
if (rc) {
IL_ERR(il, "Error setting RXON_ASSOC "
IL_ERR("Error setting RXON_ASSOC "
"configuration (%d).\n", rc);
return rc;
}
......@@ -1775,7 +1775,7 @@ int il3945_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
* active_rxon back to what it was previously */
if (rc) {
active_rxon->filter_flags |= RXON_FILTER_ASSOC_MSK;
IL_ERR(il, "Error clearing ASSOC_MSK on current "
IL_ERR("Error clearing ASSOC_MSK on current "
"configuration (%d).\n", rc);
return rc;
}
......@@ -1807,7 +1807,7 @@ int il3945_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
sizeof(struct il3945_rxon_cmd),
staging_rxon);
if (rc) {
IL_ERR(il, "Error setting new configuration (%d).\n", rc);
IL_ERR("Error setting new configuration (%d).\n", rc);
return rc;
}
......@@ -1824,14 +1824,14 @@ int il3945_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
* send a new TXPOWER command or we won't be able to Tx any frames */
rc = il_set_tx_power(il, il->tx_power_next, true);
if (rc) {
IL_ERR(il, "Error setting Tx power (%d).\n", rc);
IL_ERR("Error setting Tx power (%d).\n", rc);
return rc;
}
/* Init the hardware's rate fallback order based on the band */
rc = il3945_init_hw_rate_table(il);
if (rc) {
IL_ERR(il, "Error setting HW rate table: %02X\n", rc);
IL_ERR("Error setting HW rate table: %02X\n", rc);
return -EIO;
}
......@@ -1989,7 +1989,7 @@ static void il3945_hw_reg_init_channel_groups(struct il_priv *il)
/* sanity check on factory saturation power value */
if (group->saturation_power < 40) {
IL_WARN(il, "Error: saturation power is %d, "
IL_WARN("Error: saturation power is %d, "
"less than minimum expected 40\n",
group->saturation_power);
return;
......@@ -2119,7 +2119,7 @@ int il3945_txpower_set_from_eeprom(struct il_priv *il)
ch_info->group_index,
&power_idx);
if (rc) {
IL_ERR(il, "Invalid power index\n");
IL_ERR("Invalid power index\n");
return rc;
}
pwr_info->base_power_index = (u8) power_idx;
......@@ -2187,7 +2187,7 @@ int il3945_hw_rxq_stop(struct il_priv *il)
rc = il_poll_direct_bit(il, FH39_RSSR_STATUS,
FH39_RSSR_CHNL0_RX_STATUS_CHNL_IDLE, 1000);
if (rc < 0)
IL_ERR(il, "Can't stop Rx DMA.\n");
IL_ERR("Can't stop Rx DMA.\n");
return 0;
}
......@@ -2263,7 +2263,7 @@ static int il3945_add_bssid_station(struct il_priv *il,
ret = il_add_station_common(il, ctx, addr, 0, NULL, &sta_id);
if (ret) {
IL_ERR(il, "Unable to add station %pM\n", addr);
IL_ERR("Unable to add station %pM\n", addr);
return ret;
}
......@@ -2390,7 +2390,7 @@ int il3945_hw_set_hw_params(struct il_priv *il)
sizeof(struct il3945_shared),
&il->_3945.shared_phys, GFP_KERNEL);
if (!il->_3945.shared_virt) {
IL_ERR(il, "failed to allocate pci memory\n");
IL_ERR("failed to allocate pci memory\n");
return -ENOMEM;
}
......@@ -2481,7 +2481,7 @@ static int il3945_verify_bsm(struct il_priv *il)
reg += sizeof(u32), image++) {
val = il_read_prph(il, reg);
if (val != le32_to_cpu(*image)) {
IL_ERR(il, "BSM uCode verification failed at "
IL_ERR("BSM uCode verification failed at "
"addr 0x%08X+%u (of %u), is 0x%x, s/b 0x%x\n",
BSM_SRAM_LOWER_BOUND,
reg - BSM_SRAM_LOWER_BOUND, len,
......@@ -2620,7 +2620,7 @@ static int il3945_load_bsm(struct il_priv *il)
if (i < 100)
D_INFO("BSM write complete, poll %d iterations\n", i);
else {
IL_ERR(il, "BSM write did not complete!\n");
IL_ERR("BSM write did not complete!\n");
return -EIO;
}
......
......@@ -75,7 +75,7 @@ ssize_t il4965_ucode_rx_stats_read(struct file *file, char __user *user_buf,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -501,7 +501,7 @@ ssize_t il4965_ucode_tx_stats_read(struct file *file,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -679,7 +679,7 @@ il4965_ucode_general_stats_read(struct file *file, char __user *user_buf,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......
......@@ -129,12 +129,12 @@ int il4965_eeprom_check_version(struct il_priv *il)
calib_ver < il->cfg->eeprom_calib_ver)
goto err;
IL_INFO(il, "device EEPROM VER=0x%x, CALIB=0x%x\n",
IL_INFO("device EEPROM VER=0x%x, CALIB=0x%x\n",
eeprom_ver, calib_ver);
return 0;
err:
IL_ERR(il, "Unsupported (too old) EEPROM VER=0x%x < 0x%x "
IL_ERR("Unsupported (too old) EEPROM VER=0x%x < 0x%x "
"CALIB=0x%x < 0x%x\n",
eeprom_ver, il->cfg->eeprom_ver,
calib_ver, il->cfg->eeprom_calib_ver);
......
......@@ -44,7 +44,7 @@ void il4965_check_abort_status(struct il_priv *il,
u8 frame_count, u32 status)
{
if (frame_count == 1 && status == TX_STATUS_FAIL_RFKILL_FLUSH) {
IL_ERR(il, "Tx flush command to flush out all frames\n");
IL_ERR("Tx flush command to flush out all frames\n");
if (!test_bit(STATUS_EXIT_PENDING, &il->status))
queue_work(il->workqueue, &il->tx_flush);
}
......@@ -176,7 +176,7 @@ int il4965_hw_nic_init(struct il_priv *il)
if (!rxq->bd) {
ret = il_rx_queue_alloc(il);
if (ret) {
IL_ERR(il, "Unable to initialize Rx queue\n");
IL_ERR("Unable to initialize Rx queue\n");
return -ENOMEM;
}
} else
......@@ -309,7 +309,7 @@ static void il4965_rx_allocate(struct il_priv *il, gfp_t priority)
if ((rxq->free_count <= RX_LOW_WATERMARK) &&
net_ratelimit())
IL_CRIT(il,
IL_CRIT(
"Failed to alloc_pages with %s. "
"Only %u free buffers remaining.\n",
priority == GFP_ATOMIC ?
......@@ -549,7 +549,7 @@ static void il4965_pass_packet_to_mac80211(struct il_priv *il,
skb = dev_alloc_skb(128);
if (!skb) {
IL_ERR(il, "dev_alloc_skb failed\n");
IL_ERR("dev_alloc_skb failed\n");
return;
}
......@@ -598,7 +598,7 @@ void il4965_rx_reply_rx(struct il_priv *il,
ampdu_status = le32_to_cpu(rx_pkt_status);
} else {
if (!il->_4965.last_phy_res_valid) {
IL_ERR(il, "MPDU frame without cached PHY data\n");
IL_ERR("MPDU frame without cached PHY data\n");
return;
}
phy_res = &il->_4965.last_phy_res;
......@@ -880,7 +880,7 @@ int il4965_request_scan(struct il_priv *il, struct ieee80211_vif *vif)
rate = IL_RATE_6M_PLCP;
break;
default:
IL_WARN(il, "Invalid scan band\n");
IL_WARN("Invalid scan band\n");
return -EIO;
}
......@@ -1184,9 +1184,9 @@ int il4965_dump_fh(struct il_priv *il, char **buf, bool display)
return pos;
}
#endif
IL_ERR(il, "FH register values:\n");
IL_ERR("FH register values:\n");
for (i = 0; i < ARRAY_SIZE(fh_tbl); i++) {
IL_ERR(il, " %34s: 0X%08x\n",
IL_ERR(" %34s: 0X%08x\n",
il4965_get_fh_string(fh_tbl[i]),
il_read_direct32(il, fh_tbl[i]));
}
......
......@@ -367,12 +367,12 @@ static int il4965_rs_tl_turn_on_agg_for_tid(struct il_priv *il,
* this might be cause by reloading firmware
* stop the tx ba session here
*/
IL_ERR(il, "Fail start Tx agg on tid: %d\n",
IL_ERR("Fail start Tx agg on tid: %d\n",
tid);
ieee80211_stop_tx_ba_session(sta, tid);
}
} else {
IL_ERR(il, "Aggregation not enabled for tid %d "
IL_ERR("Aggregation not enabled for tid %d "
"because load = %u\n", tid, load);
}
return ret;
......@@ -385,7 +385,7 @@ static void il4965_rs_tl_turn_on_agg(struct il_priv *il, u8 tid,
if (tid < TID_MAX_LOAD_COUNT)
il4965_rs_tl_turn_on_agg_for_tid(il, lq_data, tid, sta);
else
IL_ERR(il, "tid exceeds max load count: %d/%d\n",
IL_ERR("tid exceeds max load count: %d/%d\n",
tid, TID_MAX_LOAD_COUNT);
}
......@@ -505,7 +505,7 @@ static u32 il4965_rate_n_flags_from_tbl(struct il_priv *il,
} else if (is_Ht(tbl->lq_type)) {
if (index > IL_LAST_OFDM_RATE) {
IL_ERR(il, "Invalid HT rate index %d\n", index);
IL_ERR("Invalid HT rate index %d\n", index);
index = IL_LAST_OFDM_RATE;
}
rate_n_flags = RATE_MCS_HT_MSK;
......@@ -515,7 +515,7 @@ static u32 il4965_rate_n_flags_from_tbl(struct il_priv *il,
else
rate_n_flags |= il_rates[index].plcp_mimo2;
} else {
IL_ERR(il, "Invalid tbl->lq_type %d\n", tbl->lq_type);
IL_ERR("Invalid tbl->lq_type %d\n", tbl->lq_type);
}
rate_n_flags |= ((tbl->ant_type << RATE_MCS_ANT_POS) &
......@@ -535,7 +535,7 @@ static u32 il4965_rate_n_flags_from_tbl(struct il_priv *il,
rate_n_flags |= RATE_MCS_GF_MSK;
if (is_siso(tbl->lq_type) && tbl->is_SGI) {
rate_n_flags &= ~RATE_MCS_SGI_MSK;
IL_ERR(il, "GF was set with SGI:SISO\n");
IL_ERR("GF was set with SGI:SISO\n");
}
}
}
......@@ -1480,7 +1480,7 @@ static int il4965_rs_move_siso_to_other(struct il_priv *il,
if (!tbl->is_SGI)
break;
else
IL_ERR(il,
IL_ERR(
"SGI was set in GF+SISO\n");
}
search_tbl->is_SGI = !tbl->is_SGI;
......@@ -1851,7 +1851,7 @@ static void il4965_rs_rate_scale_perform(struct il_priv *il,
rate_scale_index_msk = rate_mask;
if (!((1 << index) & rate_scale_index_msk)) {
IL_ERR(il, "Current Rate is not valid\n");
IL_ERR("Current Rate is not valid\n");
if (lq_sta->search_better_tbl) {
/* revert to active table if search table is not valid*/
tbl->lq_type = LQ_NONE;
......@@ -1867,7 +1867,7 @@ static void il4965_rs_rate_scale_perform(struct il_priv *il,
/* Get expected throughput table and history window for current rate */
if (!tbl->expected_tpt) {
IL_ERR(il, "tbl->expected_tpt is NULL\n");
IL_ERR("tbl->expected_tpt is NULL\n");
return;
}
......@@ -1909,7 +1909,7 @@ static void il4965_rs_rate_scale_perform(struct il_priv *il,
* actual average throughput */
if (window->average_tpt != ((window->success_ratio *
tbl->expected_tpt[index] + 64) / 128)) {
IL_ERR(il,
IL_ERR(
"expected_tpt should have been calculated by now\n");
window->average_tpt = ((window->success_ratio *
tbl->expected_tpt[index] + 64) / 128);
......@@ -2590,7 +2590,7 @@ static void il4965_rs_dbgfs_set_mcs(struct il_lq_sta *lq_sta,
D_RATE("Fixed rate ON\n");
} else {
lq_sta->dbg_fixed_rate = 0;
IL_ERR(il,
IL_ERR(
"Invalid antenna selection 0x%X, Valid is 0x%X\n",
ant_sel_tx, valid_tx_ant);
D_RATE("Fixed rate OFF\n");
......
......@@ -44,7 +44,7 @@ il4965_sta_alloc_lq(struct il_priv *il, u8 sta_id)
link_cmd = kzalloc(sizeof(struct il_link_quality_cmd), GFP_KERNEL);
if (!link_cmd) {
IL_ERR(il, "Unable to allocate memory for LQ cmd.\n");
IL_ERR("Unable to allocate memory for LQ cmd.\n");
return NULL;
}
/* Set up the rate scaling to start at selected rate, fall back
......@@ -105,7 +105,7 @@ il4965_add_bssid_station(struct il_priv *il, struct il_rxon_context *ctx,
ret = il_add_station_common(il, ctx, addr, 0, NULL, &sta_id);
if (ret) {
IL_ERR(il, "Unable to add station %pM\n", addr);
IL_ERR("Unable to add station %pM\n", addr);
return ret;
}
......@@ -119,7 +119,7 @@ il4965_add_bssid_station(struct il_priv *il, struct il_rxon_context *ctx,
/* Set up default rate scaling table in device's station table */
link_cmd = il4965_sta_alloc_lq(il, sta_id);
if (!link_cmd) {
IL_ERR(il,
IL_ERR(
"Unable to initialize rate scaling for station %pM.\n",
addr);
return -ENOMEM;
......@@ -127,7 +127,7 @@ il4965_add_bssid_station(struct il_priv *il, struct il_rxon_context *ctx,
ret = il_send_lq_cmd(il, ctx, link_cmd, CMD_SYNC, true);
if (ret)
IL_ERR(il, "Link quality command failed (%d)\n", ret);
IL_ERR("Link quality command failed (%d)\n", ret);
spin_lock_irqsave(&il->sta_lock, flags);
il->stations[sta_id].lq = link_cmd;
......@@ -467,7 +467,7 @@ int il4965_remove_dynamic_key(struct il_priv *il,
}
if (il->stations[sta_id].sta.key.key_offset == WEP_INVALID_OFFSET) {
IL_WARN(il, "Removing wrong key %d 0x%x\n",
IL_WARN("Removing wrong key %d 0x%x\n",
keyconf->keyidx, key_flags);
spin_unlock_irqrestore(&il->sta_lock, flags);
return 0;
......@@ -475,7 +475,7 @@ int il4965_remove_dynamic_key(struct il_priv *il,
if (!test_and_clear_bit(il->stations[sta_id].sta.key.key_offset,
&il->ucode_key_table))
IL_ERR(il, "index %d not used in uCode key table.\n",
IL_ERR("index %d not used in uCode key table.\n",
il->stations[sta_id].sta.key.key_offset);
memset(&il->stations[sta_id].keyinfo, 0,
sizeof(struct il_hw_key));
......@@ -525,7 +525,7 @@ int il4965_set_dynamic_key(struct il_priv *il, struct il_rxon_context *ctx,
keyconf, sta_id);
break;
default:
IL_ERR(il,
IL_ERR(
"Unknown alg: %s cipher = %x\n", __func__,
keyconf->cipher);
ret = -EINVAL;
......@@ -557,7 +557,7 @@ int il4965_alloc_bcast_station(struct il_priv *il,
sta_id = il_prep_station(il, ctx, il_bcast_addr,
false, NULL);
if (sta_id == IL_INVALID_STATION) {
IL_ERR(il, "Unable to prepare broadcast station\n");
IL_ERR("Unable to prepare broadcast station\n");
spin_unlock_irqrestore(&il->sta_lock, flags);
return -EINVAL;
......@@ -569,7 +569,7 @@ int il4965_alloc_bcast_station(struct il_priv *il,
link_cmd = il4965_sta_alloc_lq(il, sta_id);
if (!link_cmd) {
IL_ERR(il,
IL_ERR(
"Unable to initialize rate scaling for bcast station.\n");
return -ENOMEM;
}
......@@ -596,7 +596,7 @@ static int il4965_update_bcast_station(struct il_priv *il,
link_cmd = il4965_sta_alloc_lq(il, sta_id);
if (!link_cmd) {
IL_ERR(il,
IL_ERR(
"Unable to initialize rate scaling for bcast station.\n");
return -ENOMEM;
}
......@@ -686,7 +686,7 @@ int il4965_sta_rx_agg_stop(struct il_priv *il, struct ieee80211_sta *sta,
sta_id = il_sta_id(sta);
if (sta_id == IL_INVALID_STATION) {
IL_ERR(il, "Invalid station for AGG tid %d\n", tid);
IL_ERR("Invalid station for AGG tid %d\n", tid);
return -ENXIO;
}
......
......@@ -258,7 +258,7 @@ static void il4965_tx_cmd_build_hwcrypto(struct il_priv *il,
break;
default:
IL_ERR(il, "Unknown encode cipher %x\n", keyconf->cipher);
IL_ERR("Unknown encode cipher %x\n", keyconf->cipher);
break;
}
}
......@@ -619,13 +619,13 @@ int il4965_txq_ctx_alloc(struct il_priv *il)
ret = il4965_alloc_dma_ptr(il, &il->scd_bc_tbls,
il->hw_params.scd_bc_tbls_size);
if (ret) {
IL_ERR(il, "Scheduler BC Table allocation failed\n");
IL_ERR("Scheduler BC Table allocation failed\n");
goto error_bc_tbls;
}
/* Alloc keep-warm buffer */
ret = il4965_alloc_dma_ptr(il, &il->kw, IL_KW_SIZE);
if (ret) {
IL_ERR(il, "Keep Warm allocation failed\n");
IL_ERR("Keep Warm allocation failed\n");
goto error_kw;
}
......@@ -652,7 +652,7 @@ int il4965_txq_ctx_alloc(struct il_priv *il)
&il->txq[txq_id], slots_num,
txq_id);
if (ret) {
IL_ERR(il, "Tx %d queue init failed\n", txq_id);
IL_ERR("Tx %d queue init failed\n", txq_id);
goto error;
}
}
......@@ -712,7 +712,7 @@ void il4965_txq_ctx_stop(struct il_priv *il)
if (il_poll_direct_bit(il, FH_TSSR_TX_STATUS_REG,
FH_TSSR_TX_STATUS_REG_MSK_CHNL_IDLE(ch),
1000))
IL_ERR(il, "Failing on timeout while stopping"
IL_ERR("Failing on timeout while stopping"
" DMA channel %d [0x%08x]", ch,
il_read_direct32(il,
FH_TSSR_TX_STATUS_REG));
......@@ -803,7 +803,7 @@ static int il4965_txq_agg_enable(struct il_priv *il, int txq_id,
if ((IWL49_FIRST_AMPDU_QUEUE > txq_id) ||
(IWL49_FIRST_AMPDU_QUEUE +
il->cfg->base_params->num_of_ampdu_queues <= txq_id)) {
IL_WARN(il,
IL_WARN(
"queue number out of range: %d, must be %d to %d\n",
txq_id, IWL49_FIRST_AMPDU_QUEUE,
IWL49_FIRST_AMPDU_QUEUE +
......@@ -871,25 +871,25 @@ int il4965_tx_agg_start(struct il_priv *il, struct ieee80211_vif *vif,
if (unlikely(tx_fifo < 0))
return tx_fifo;
IL_WARN(il, "%s on ra = %pM tid = %d\n",
IL_WARN("%s on ra = %pM tid = %d\n",
__func__, sta->addr, tid);
sta_id = il_sta_id(sta);
if (sta_id == IL_INVALID_STATION) {
IL_ERR(il, "Start AGG on invalid station\n");
IL_ERR("Start AGG on invalid station\n");
return -ENXIO;
}
if (unlikely(tid >= MAX_TID_COUNT))
return -EINVAL;
if (il->stations[sta_id].tid[tid].agg.state != IL_AGG_OFF) {
IL_ERR(il, "Start AGG when state is not IL_AGG_OFF !\n");
IL_ERR("Start AGG when state is not IL_AGG_OFF !\n");
return -ENXIO;
}
txq_id = il4965_txq_ctx_activate_free(il);
if (txq_id == -1) {
IL_ERR(il, "No free aggregation queue available\n");
IL_ERR("No free aggregation queue available\n");
return -ENXIO;
}
......@@ -932,7 +932,7 @@ static int il4965_txq_agg_disable(struct il_priv *il, u16 txq_id,
if ((IWL49_FIRST_AMPDU_QUEUE > txq_id) ||
(IWL49_FIRST_AMPDU_QUEUE +
il->cfg->base_params->num_of_ampdu_queues <= txq_id)) {
IL_WARN(il,
IL_WARN(
"queue number out of range: %d, must be %d to %d\n",
txq_id, IWL49_FIRST_AMPDU_QUEUE,
IWL49_FIRST_AMPDU_QUEUE +
......@@ -973,7 +973,7 @@ int il4965_tx_agg_stop(struct il_priv *il, struct ieee80211_vif *vif,
sta_id = il_sta_id(sta);
if (sta_id == IL_INVALID_STATION) {
IL_ERR(il, "Invalid station for AGG tid %d\n", tid);
IL_ERR("Invalid station for AGG tid %d\n", tid);
return -ENXIO;
}
......@@ -996,7 +996,7 @@ int il4965_tx_agg_stop(struct il_priv *il, struct ieee80211_vif *vif,
case IL_AGG_ON:
break;
default:
IL_WARN(il, "Stopping AGG while state not ON or starting\n");
IL_WARN("Stopping AGG while state not ON or starting\n");
}
write_ptr = il->txq[txq_id].q.write_ptr;
......@@ -1115,7 +1115,7 @@ int il4965_tx_queue_reclaim(struct il_priv *il, int txq_id, int index)
struct ieee80211_hdr *hdr;
if ((index >= q->n_bd) || (il_queue_used(q, index) == 0)) {
IL_ERR(il, "Read index for DMA queue txq id (%d), index %d, "
IL_ERR("Read index for DMA queue txq id (%d), index %d, "
"is out of range [0-%d] %d %d.\n", txq_id,
index, q->n_bd, q->write_ptr, q->read_ptr);
return 0;
......@@ -1163,7 +1163,7 @@ static int il4965_tx_status_reply_compressed_ba(struct il_priv *il,
if (unlikely(!agg->wait_for_ba)) {
if (unlikely(ba_resp->bitmap))
IL_ERR(il, "Received BA when not expected\n");
IL_ERR("Received BA when not expected\n");
return -EINVAL;
}
......@@ -1266,7 +1266,7 @@ void il4965_rx_reply_compressed_ba(struct il_priv *il,
u16 ba_resp_scd_ssn = le16_to_cpu(ba_resp->scd_ssn);
if (scd_flow >= il->hw_params.max_txq_num) {
IL_ERR(il,
IL_ERR(
"BUG_ON scd_flow is bigger than number of queues\n");
return;
}
......
......@@ -99,7 +99,7 @@ static int il4965_verify_inst_full(struct il_priv *il, __le32 *image,
* if IL_DL_IO is set */
val = _il_read_direct32(il, HBUS_TARG_MEM_RDAT);
if (val != le32_to_cpu(*image)) {
IL_ERR(il, "uCode INST section is invalid at "
IL_ERR("uCode INST section is invalid at "
"offset 0x%x, is 0x%x, s/b 0x%x\n",
save_len - len, val, le32_to_cpu(*image));
ret = -EIO;
......@@ -153,7 +153,7 @@ int il4965_verify_ucode(struct il_priv *il)
return 0;
}
IL_ERR(il, "NO VALID UCODE IMAGE IN INSTRUCTION SRAM!!\n");
IL_ERR("NO VALID UCODE IMAGE IN INSTRUCTION SRAM!!\n");
/* Since nothing seems to match, show first several data entries in
* instruction SRAM, so maybe visual inspection will give a clue.
......
......@@ -78,7 +78,7 @@ static int il4965_verify_bsm(struct il_priv *il)
reg += sizeof(u32), image++) {
val = il_read_prph(il, reg);
if (val != le32_to_cpu(*image)) {
IL_ERR(il, "BSM uCode verification failed at "
IL_ERR("BSM uCode verification failed at "
"addr 0x%08X+%u (of %u), is 0x%x, s/b 0x%x\n",
BSM_SRAM_LOWER_BOUND,
reg - BSM_SRAM_LOWER_BOUND, len,
......@@ -191,7 +191,7 @@ static int il4965_load_bsm(struct il_priv *il)
if (i < 100)
D_INFO("BSM write complete, poll %d iterations\n", i);
else {
IL_ERR(il, "BSM write did not complete!\n");
IL_ERR("BSM write did not complete!\n");
return -EIO;
}
......@@ -343,7 +343,7 @@ static void il4965_chain_noise_reset(struct il_priv *il)
cmd.diff_gain_c = 0;
if (il_send_cmd_pdu(il, REPLY_PHY_CALIBRATION_CMD,
sizeof(cmd), &cmd))
IL_ERR(il,
IL_ERR(
"Could not send REPLY_PHY_CALIBRATION_CMD\n");
data->state = IL_CHAIN_NOISE_ACCUMULATE;
D_CALIB("Run chain_noise_calibrate\n");
......@@ -548,7 +548,7 @@ static int il4965_interpolate_chan(struct il_priv *il, u32 channel,
s = il4965_get_sub_band(il, channel);
if (s >= EEPROM_TX_POWER_BANDS) {
IL_ERR(il, "Tx Power can not find channel %d\n", channel);
IL_ERR("Tx Power can not find channel %d\n", channel);
return -1;
}
......@@ -912,7 +912,7 @@ static int il4965_fill_txpower_tbl(struct il_priv *il, u8 band, u16 channel,
* and 2) mimo txpower balance between Tx chains. */
txatten_grp = il4965_get_tx_atten_grp(channel);
if (txatten_grp < 0) {
IL_ERR(il, "Can't find txatten group for channel %d.\n",
IL_ERR("Can't find txatten group for channel %d.\n",
channel);
return txatten_grp;
}
......@@ -1078,12 +1078,12 @@ static int il4965_fill_txpower_tbl(struct il_priv *il, u8 band, u16 channel,
/* stay within the table! */
if (power_index > 107) {
IL_WARN(il, "txpower index %d > 107\n",
IL_WARN("txpower index %d > 107\n",
power_index);
power_index = 107;
}
if (power_index < 0) {
IL_WARN(il, "txpower index %d < 0\n",
IL_WARN("txpower index %d < 0\n",
power_index);
power_index = 0;
}
......@@ -1207,7 +1207,7 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
ret = il_check_rxon_cmd(il, ctx);
if (ret) {
IL_ERR(il, "Invalid RXON configuration. Not committing.\n");
IL_ERR("Invalid RXON configuration. Not committing.\n");
return -EINVAL;
}
......@@ -1228,7 +1228,7 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
if (!il_full_rxon_required(il, ctx)) {
ret = il_send_rxon_assoc(il, ctx);
if (ret) {
IL_ERR(il, "Error setting RXON_ASSOC (%d)\n", ret);
IL_ERR("Error setting RXON_ASSOC (%d)\n", ret);
return ret;
}
......@@ -1258,14 +1258,14 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
* active_rxon back to what it was previously */
if (ret) {
active_rxon->filter_flags |= RXON_FILTER_ASSOC_MSK;
IL_ERR(il, "Error clearing ASSOC_MSK (%d)\n", ret);
IL_ERR("Error clearing ASSOC_MSK (%d)\n", ret);
return ret;
}
il_clear_ucode_stations(il, ctx);
il_restore_stations(il, ctx);
ret = il4965_restore_default_wep_keys(il, ctx);
if (ret) {
IL_ERR(il, "Failed to restore WEP keys (%d)\n", ret);
IL_ERR("Failed to restore WEP keys (%d)\n", ret);
return ret;
}
}
......@@ -1289,7 +1289,7 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
ret = il_send_cmd_pdu(il, ctx->rxon_cmd,
sizeof(struct il_rxon_cmd), &ctx->staging);
if (ret) {
IL_ERR(il, "Error setting new RXON (%d)\n", ret);
IL_ERR("Error setting new RXON (%d)\n", ret);
return ret;
}
D_INFO("Return from !new_assoc RXON.\n");
......@@ -1298,7 +1298,7 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
il_restore_stations(il, ctx);
ret = il4965_restore_default_wep_keys(il, ctx);
if (ret) {
IL_ERR(il, "Failed to restore WEP keys (%d)\n", ret);
IL_ERR("Failed to restore WEP keys (%d)\n", ret);
return ret;
}
}
......@@ -1310,7 +1310,7 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
ret = il_send_cmd_pdu(il, ctx->rxon_cmd,
sizeof(struct il_rxon_cmd), &ctx->staging);
if (ret) {
IL_ERR(il, "Error setting new RXON (%d)\n", ret);
IL_ERR("Error setting new RXON (%d)\n", ret);
return ret;
}
memcpy(active_rxon, &ctx->staging, sizeof(*active_rxon));
......@@ -1323,7 +1323,7 @@ static int il4965_commit_rxon(struct il_priv *il, struct il_rxon_context *ctx)
* send a new TXPOWER command or we won't be able to Tx any frames */
ret = il_set_tx_power(il, il->tx_power_next, true);
if (ret) {
IL_ERR(il, "Error sending TX power (%d)\n", ret);
IL_ERR("Error sending TX power (%d)\n", ret);
return ret;
}
......@@ -1393,7 +1393,7 @@ static int il4965_hw_channel_switch(struct il_priv *il,
if (ch_info)
cmd.expect_beacon = il_is_channel_radar(ch_info);
else {
IL_ERR(il, "invalid channel switch from %u to %u\n",
IL_ERR("invalid channel switch from %u to %u\n",
ctx->active.channel, ch);
return -EFAULT;
}
......@@ -1479,7 +1479,7 @@ static int il4965_hw_get_temperature(struct il_priv *il)
D_TEMP("Calib values R[1-3]: %d %d %d R4: %d\n", R1, R2, R3, vt);
if (R3 == R1) {
IL_ERR(il, "Calibration conflict R1 == R3\n");
IL_ERR("Calibration conflict R1 == R3\n");
return -1;
}
......@@ -1666,7 +1666,7 @@ static int il4965_tx_status_reply_tx(struct il_priv *il,
hdr = il_tx_queue_get_hdr(il, txq_id, idx);
if (!hdr) {
IL_ERR(il,
IL_ERR(
"BUG_ON idx doesn't point to valid skb"
" idx=%d, txq_id=%d\n", idx, txq_id);
return -1;
......@@ -1674,7 +1674,7 @@ static int il4965_tx_status_reply_tx(struct il_priv *il,
sc = le16_to_cpu(hdr->seq_ctrl);
if (idx != (SEQ_TO_SN(sc) & 0xff)) {
IL_ERR(il,
IL_ERR(
"BUG_ON idx doesn't match seq control"
" idx=%d, seq_idx=%d, seq=%d\n",
idx, SEQ_TO_SN(sc), hdr->seq_ctrl);
......@@ -1750,7 +1750,7 @@ static u8 il4965_find_station(struct il_priv *il, const u8 *addr)
(!(il->stations[ret].used & IL_STA_UCODE_ACTIVE) ||
((il->stations[ret].used & IL_STA_UCODE_ACTIVE) &&
(il->stations[ret].used & IL_STA_UCODE_INPROGRESS)))) {
IL_ERR(il, "Requested station info for sta %d before ready.\n",
IL_ERR("Requested station info for sta %d before ready.\n",
ret);
ret = IL_INVALID_STATION;
}
......@@ -1790,7 +1790,7 @@ static void il4965_rx_reply_tx(struct il_priv *il,
unsigned long flags;
if ((index >= txq->q.n_bd) || (il_queue_used(&txq->q, index) == 0)) {
IL_ERR(il, "Read index for DMA queue txq_id (%d) index %d "
IL_ERR("Read index for DMA queue txq_id (%d) index %d "
"is out of range [0-%d] %d %d\n", txq_id,
index, txq->q.n_bd, txq->q.write_ptr,
txq->q.read_ptr);
......@@ -1809,7 +1809,7 @@ static void il4965_rx_reply_tx(struct il_priv *il,
sta_id = il4965_get_ra_sta_id(il, hdr);
if (txq->sched_retry && unlikely(sta_id == IL_INVALID_STATION)) {
IL_ERR(il, "Station not known\n");
IL_ERR("Station not known\n");
return;
}
......@@ -1943,7 +1943,7 @@ static void il4965_post_associate(struct il_priv *il)
ret = il_send_rxon_timing(il, ctx);
if (ret)
IL_WARN(il, "RXON timing - "
IL_WARN("RXON timing - "
"Attempting to continue.\n");
ctx->staging.filter_flags |= RXON_FILTER_ASSOC_MSK;
......@@ -1982,7 +1982,7 @@ static void il4965_post_associate(struct il_priv *il)
il4965_send_beacon_cmd(il);
break;
default:
IL_ERR(il, "%s Should not be called in %d mode\n",
IL_ERR("%s Should not be called in %d mode\n",
__func__, vif->type);
break;
}
......@@ -2019,7 +2019,7 @@ static void il4965_config_ap(struct il_priv *il)
/* RXON Timing */
ret = il_send_rxon_timing(il, ctx);
if (ret)
IL_WARN(il, "RXON timing failed - "
IL_WARN("RXON timing failed - "
"Attempting to continue.\n");
/* AP has all antennas */
......
......@@ -253,14 +253,14 @@ int il_init_geos(struct il_priv *il)
if ((il->bands[IEEE80211_BAND_5GHZ].n_channels == 0) &&
il->cfg->sku & IL_SKU_A) {
IL_INFO(il, "Incorrectly detected BG card as ABG. "
IL_INFO("Incorrectly detected BG card as ABG. "
"Please send your PCI ID 0x%04X:0x%04X to maintainer.\n",
il->pci_dev->device,
il->pci_dev->subsystem_device);
il->cfg->sku &= ~IL_SKU_A;
}
IL_INFO(il, "Tunable channels: %d 802.11bg, %d 802.11a channels\n",
IL_INFO("Tunable channels: %d 802.11bg, %d 802.11a channels\n",
il->bands[IEEE80211_BAND_2GHZ].n_channels,
il->bands[IEEE80211_BAND_5GHZ].n_channels);
......@@ -431,65 +431,65 @@ il_check_rxon_cmd(struct il_priv *il, struct il_rxon_context *ctx)
if (rxon->flags & RXON_FLG_BAND_24G_MSK) {
if (rxon->flags & RXON_FLG_TGJ_NARROW_BAND_MSK) {
IL_WARN(il, "check 2.4G: wrong narrow\n");
IL_WARN("check 2.4G: wrong narrow\n");
error = true;
}
if (rxon->flags & RXON_FLG_RADAR_DETECT_MSK) {
IL_WARN(il, "check 2.4G: wrong radar\n");
IL_WARN("check 2.4G: wrong radar\n");
error = true;
}
} else {
if (!(rxon->flags & RXON_FLG_SHORT_SLOT_MSK)) {
IL_WARN(il, "check 5.2G: not short slot!\n");
IL_WARN("check 5.2G: not short slot!\n");
error = true;
}
if (rxon->flags & RXON_FLG_CCK_MSK) {
IL_WARN(il, "check 5.2G: CCK!\n");
IL_WARN("check 5.2G: CCK!\n");
error = true;
}
}
if ((rxon->node_addr[0] | rxon->bssid_addr[0]) & 0x1) {
IL_WARN(il, "mac/bssid mcast!\n");
IL_WARN("mac/bssid mcast!\n");
error = true;
}
/* make sure basic rates 6Mbps and 1Mbps are supported */
if ((rxon->ofdm_basic_rates & IL_RATE_6M_MASK) == 0 &&
(rxon->cck_basic_rates & IL_RATE_1M_MASK) == 0) {
IL_WARN(il, "neither 1 nor 6 are basic\n");
IL_WARN("neither 1 nor 6 are basic\n");
error = true;
}
if (le16_to_cpu(rxon->assoc_id) > 2007) {
IL_WARN(il, "aid > 2007\n");
IL_WARN("aid > 2007\n");
error = true;
}
if ((rxon->flags & (RXON_FLG_CCK_MSK | RXON_FLG_SHORT_SLOT_MSK))
== (RXON_FLG_CCK_MSK | RXON_FLG_SHORT_SLOT_MSK)) {
IL_WARN(il, "CCK and short slot\n");
IL_WARN("CCK and short slot\n");
error = true;
}
if ((rxon->flags & (RXON_FLG_CCK_MSK | RXON_FLG_AUTO_DETECT_MSK))
== (RXON_FLG_CCK_MSK | RXON_FLG_AUTO_DETECT_MSK)) {
IL_WARN(il, "CCK and auto detect");
IL_WARN("CCK and auto detect");
error = true;
}
if ((rxon->flags & (RXON_FLG_AUTO_DETECT_MSK |
RXON_FLG_TGG_PROTECT_MSK)) ==
RXON_FLG_TGG_PROTECT_MSK) {
IL_WARN(il, "TGg but no auto-detect\n");
IL_WARN("TGg but no auto-detect\n");
error = true;
}
if (error)
IL_WARN(il, "Tuning to channel %d\n",
IL_WARN("Tuning to channel %d\n",
le16_to_cpu(rxon->channel));
if (error) {
IL_ERR(il, "Invalid RXON\n");
IL_ERR("Invalid RXON\n");
return -EINVAL;
}
return 0;
......@@ -626,7 +626,7 @@ static void _il_set_rxon_ht(struct il_priv *il,
case IEEE80211_HT_PARAM_CHA_SEC_NONE:
default:
/* channel location only valid if in Mixed mode */
IL_ERR(il,
IL_ERR(
"invalid extension channel offset\n");
break;
}
......@@ -778,7 +778,7 @@ void il_connection_init_rx_config(struct il_priv *il,
break;
default:
IL_ERR(il, "Unsupported interface type %d\n",
IL_ERR("Unsupported interface type %d\n",
ctx->vif->type);
break;
}
......@@ -828,7 +828,7 @@ void il_set_rate(struct il_priv *il)
hw = il_get_hw_mode(il, il->band);
if (!hw) {
IL_ERR(il, "Failed to set rate: unable to get hw mode\n");
IL_ERR("Failed to set rate: unable to get hw mode\n");
return;
}
......@@ -882,7 +882,7 @@ void il_rx_csa(struct il_priv *il, struct il_rx_mem_buffer *rxb)
le16_to_cpu(csa->channel));
il_chswitch_done(il, true);
} else {
IL_ERR(il, "CSA notif (fail) : channel %d\n",
IL_ERR("CSA notif (fail) : channel %d\n",
le16_to_cpu(csa->channel));
il_chswitch_done(il, false);
}
......@@ -925,7 +925,7 @@ void il_irq_handle_error(struct il_priv *il)
/* Cancel currently queued command. */
clear_bit(STATUS_HCMD_ACTIVE, &il->status);
IL_ERR(il, "Loaded firmware version: %s\n",
IL_ERR("Loaded firmware version: %s\n",
il->hw->wiphy->fw_version);
il->cfg->ops->lib->dump_nic_error_log(il);
......@@ -963,7 +963,7 @@ static int il_apm_stop_master(struct il_priv *il)
ret = il_poll_bit(il, CSR_RESET, CSR_RESET_REG_FLAG_MASTER_DISABLED,
CSR_RESET_REG_FLAG_MASTER_DISABLED, 100);
if (ret)
IL_WARN(il, "Master Disable Timed Out, 100 usec\n");
IL_WARN("Master Disable Timed Out, 100 usec\n");
D_INFO("stop master\n");
......@@ -1123,14 +1123,14 @@ int il_set_tx_power(struct il_priv *il, s8 tx_power, bool force)
/* 0 dBm mean 1 milliwatt */
if (tx_power < 0) {
IL_WARN(il,
IL_WARN(
"Requested user TXPOWER %d below 1 mW.\n",
tx_power);
return -EINVAL;
}
if (tx_power > il->tx_power_device_lmt) {
IL_WARN(il,
IL_WARN(
"Requested user TXPOWER %d above upper limit %d.\n",
tx_power, il->tx_power_device_lmt);
return -EINVAL;
......@@ -1184,7 +1184,7 @@ void il_send_bt_config(struct il_priv *il)
if (il_send_cmd_pdu(il, REPLY_BT_CONFIG,
sizeof(struct il_bt_cmd), &bt_cmd))
IL_ERR(il, "failed to send BT Coex Config\n");
IL_ERR("failed to send BT Coex Config\n");
}
EXPORT_SYMBOL(il_send_bt_config);
......@@ -1235,7 +1235,7 @@ void il_rx_reply_error(struct il_priv *il,
{
struct il_rx_packet *pkt = rxb_addr(rxb);
IL_ERR(il, "Error Reply type 0x%08X cmd %s (0x%02X) "
IL_ERR("Error Reply type 0x%08X cmd %s (0x%02X) "
"seq 0x%04X ser 0x%08X\n",
le32_to_cpu(pkt->u.err_resp.error_type),
il_get_cmd_string(pkt->u.err_resp.cmd_id),
......@@ -1354,7 +1354,7 @@ il_mac_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
mutex_lock(&il->mutex);
if (!il_is_ready_rf(il)) {
IL_WARN(il, "Try to add interface when device not ready\n");
IL_WARN("Try to add interface when device not ready\n");
err = -EINVAL;
goto out;
}
......@@ -1454,7 +1454,7 @@ int il_alloc_txq_mem(struct il_priv *il)
il->cfg->base_params->num_of_queues,
GFP_KERNEL);
if (!il->txq) {
IL_ERR(il, "Not enough memory for txq\n");
IL_ERR("Not enough memory for txq\n");
return -ENOMEM;
}
return 0;
......@@ -1743,7 +1743,7 @@ int il_force_reset(struct il_priv *il, bool external)
return 0;
}
IL_ERR(il, "On demand firmware reload\n");
IL_ERR("On demand firmware reload\n");
/* Set the FW error flag -- cleared on il_down */
set_bit(STATUS_FW_ERROR, &il->status);
......@@ -1847,7 +1847,7 @@ static int il_check_stuck_queue(struct il_priv *il, int cnt)
msecs_to_jiffies(il->cfg->base_params->wd_timeout);
if (time_after(jiffies, timeout)) {
IL_ERR(il, "Queue %d stuck for %u ms.\n",
IL_ERR("Queue %d stuck for %u ms.\n",
q->id, il->cfg->base_params->wd_timeout);
ret = il_force_reset(il, false);
return (ret == -EAGAIN) ? 0 : 1;
......@@ -2363,7 +2363,7 @@ static void il_beacon_update(struct ieee80211_hw *hw,
lockdep_assert_held(&il->mutex);
if (!il->beacon_ctx) {
IL_ERR(il, "update beacon but no beacon context!\n");
IL_ERR("update beacon but no beacon context!\n");
dev_kfree_skb(skb);
return;
}
......@@ -2440,7 +2440,7 @@ void il_mac_bss_info_changed(struct ieee80211_hw *hw,
* below/in post_associate will fail.
*/
if (il_scan_cancel_timeout(il, 100)) {
IL_WARN(il,
IL_WARN(
"Aborted scan still in progress after 100ms\n");
D_MAC80211(
"leaving - scan abort failed.\n");
......@@ -2554,7 +2554,7 @@ void il_mac_bss_info_changed(struct ieee80211_hw *hw,
ret = il->cfg->ops->legacy->manage_ibss_station(il, vif,
bss_conf->ibss_joined);
if (ret)
IL_ERR(il, "failed to %s IBSS station %pM\n",
IL_ERR("failed to %s IBSS station %pM\n",
bss_conf->ibss_joined ? "add" : "remove",
bss_conf->bssid);
}
......@@ -2599,7 +2599,7 @@ irqreturn_t il_isr(int irq, void *data)
if ((inta == 0xFFFFFFFF) || ((inta & 0xFFFFFFF0) == 0xa5a5a5a0)) {
/* Hardware disappeared. It might have already raised
* an interrupt */
IL_WARN(il, "HARDWARE GONE?? INTA == 0x%08x\n", inta);
IL_WARN("HARDWARE GONE?? INTA == 0x%08x\n", inta);
goto unplugged;
}
......
......@@ -32,10 +32,10 @@
struct il_priv;
extern u32 il_debug_level;
#define IL_ERR(p, f, a...) dev_err(&((p)->pci_dev->dev), f, ## a)
#define IL_WARN(p, f, a...) dev_warn(&((p)->pci_dev->dev), f, ## a)
#define IL_INFO(p, f, a...) dev_info(&((p)->pci_dev->dev), f, ## a)
#define IL_CRIT(p, f, a...) dev_crit(&((p)->pci_dev->dev), f, ## a)
#define IL_ERR(f, a...) dev_err(&il->pci_dev->dev, f, ## a)
#define IL_WARN(f, a...) dev_warn(&il->pci_dev->dev, f, ## a)
#define IL_INFO(f, a...) dev_info(&il->pci_dev->dev, f, ## a)
#define IL_CRIT(f, a...) dev_crit(&il->pci_dev->dev, f, ## a)
#define il_print_hex_error(il, p, len) \
do { \
......
......@@ -358,20 +358,20 @@ static ssize_t il_dbgfs_nvm_read(struct file *file,
buf_size = 4 * eeprom_len + 256;
if (eeprom_len % 16) {
IL_ERR(il, "NVM size is not multiple of 16.\n");
IL_ERR("NVM size is not multiple of 16.\n");
return -ENODATA;
}
ptr = il->eeprom;
if (!ptr) {
IL_ERR(il, "Invalid EEPROM memory\n");
IL_ERR("Invalid EEPROM memory\n");
return -ENOMEM;
}
/* 4 characters for byte 0xYY */
buf = kzalloc(buf_size, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
eeprom_ver = il_eeprom_query16(il, EEPROM_VERSION);
......@@ -407,7 +407,7 @@ il_dbgfs_channels_read(struct file *file, char __user *user_buf,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -519,7 +519,7 @@ static ssize_t il_dbgfs_interrupt_read(struct file *file,
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -640,7 +640,7 @@ static ssize_t il_dbgfs_disable_ht40_write(struct file *file,
if (!il_is_any_associated(il))
il->disable_ht40 = ht40 ? true : false;
else {
IL_ERR(il, "Sta associated with AP - "
IL_ERR("Sta associated with AP - "
"Change to 40MHz channel support is not allowed\n");
return -EINVAL;
}
......@@ -689,12 +689,12 @@ static ssize_t il_dbgfs_traffic_log_read(struct file *file,
ssize_t ret;
if (!il->txq) {
IL_ERR(il, "txq not ready\n");
IL_ERR("txq not ready\n");
return -EAGAIN;
}
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate buffer\n");
IL_ERR("Can not allocate buffer\n");
return -ENOMEM;
}
pos += scnprintf(buf + pos, bufsz - pos, "Tx Queue\n");
......@@ -787,7 +787,7 @@ static ssize_t il_dbgfs_tx_queue_read(struct file *file,
il->cfg->base_params->num_of_queues;
if (!il->txq) {
IL_ERR(il, "txq not ready\n");
IL_ERR("txq not ready\n");
return -EAGAIN;
}
buf = kzalloc(bufsz, GFP_KERNEL);
......@@ -884,7 +884,7 @@ static ssize_t il_dbgfs_sensitivity_read(struct file *file,
data = &il->sensitivity_data;
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -965,7 +965,7 @@ static ssize_t il_dbgfs_chain_noise_read(struct file *file,
data = &il->chain_noise_data;
buf = kzalloc(bufsz, GFP_KERNEL);
if (!buf) {
IL_ERR(il, "Can not allocate Buffer\n");
IL_ERR("Can not allocate Buffer\n");
return -ENOMEM;
}
......@@ -1292,7 +1292,7 @@ int il_dbgfs_register(struct il_priv *il, const char *name)
return 0;
err:
IL_ERR(il, "Can't create the debugfs directory\n");
IL_ERR("Can't create the debugfs directory\n");
il_dbgfs_unregister(il);
return -ENOMEM;
}
......
......@@ -153,7 +153,7 @@ static int il_eeprom_verify_signature(struct il_priv *il)
case CSR_EEPROM_GP_GOOD_SIG_EEP_MORE_THAN_4K:
break;
default:
IL_ERR(il, "bad EEPROM signature,"
IL_ERR("bad EEPROM signature,"
"EEPROM_GP=0x%08x\n", gp);
ret = -ENOENT;
break;
......@@ -206,7 +206,7 @@ int il_eeprom_init(struct il_priv *il)
ret = il_eeprom_verify_signature(il);
if (ret < 0) {
IL_ERR(il, "EEPROM not found, EEPROM_GP=0x%08x\n", gp);
IL_ERR("EEPROM not found, EEPROM_GP=0x%08x\n", gp);
ret = -ENOENT;
goto err;
}
......@@ -214,7 +214,7 @@ int il_eeprom_init(struct il_priv *il)
/* Make sure driver (instead of uCode) is allowed to read EEPROM */
ret = il->cfg->ops->lib->eeprom_ops.acquire_semaphore(il);
if (ret < 0) {
IL_ERR(il, "Failed to acquire EEPROM semaphore.\n");
IL_ERR("Failed to acquire EEPROM semaphore.\n");
ret = -ENOENT;
goto err;
}
......@@ -231,7 +231,7 @@ int il_eeprom_init(struct il_priv *il)
CSR_EEPROM_REG_READ_VALID_MSK,
IL_EEPROM_ACCESS_TIMEOUT);
if (ret < 0) {
IL_ERR(il, "Time out reading EEPROM[%d]\n",
IL_ERR("Time out reading EEPROM[%d]\n",
addr);
goto done;
}
......@@ -399,7 +399,7 @@ int il_init_channel_map(struct il_priv *il)
il->channel_info = kzalloc(sizeof(struct il_channel_info) *
il->channel_count, GFP_KERNEL);
if (!il->channel_info) {
IL_ERR(il, "Could not allocate channel_info\n");
IL_ERR("Could not allocate channel_info\n");
il->channel_count = 0;
return -ENOMEM;
}
......
......@@ -95,7 +95,7 @@ static void il_generic_cmd_callback(struct il_priv *il,
struct il_rx_packet *pkt)
{
if (pkt->hdr.flags & IL_CMD_FAILED_MSK) {
IL_ERR(il, "Bad return from %s (0x%08X)\n",
IL_ERR("Bad return from %s (0x%08X)\n",
il_get_cmd_string(cmd->hdr.cmd), pkt->hdr.flags);
return;
}
......@@ -133,7 +133,7 @@ il_send_cmd_async(struct il_priv *il, struct il_host_cmd *cmd)
ret = il_enqueue_hcmd(il, cmd);
if (ret < 0) {
IL_ERR(il, "Error sending %s: enqueue_hcmd failed: %d\n",
IL_ERR("Error sending %s: enqueue_hcmd failed: %d\n",
il_get_cmd_string(cmd->id), ret);
return ret;
}
......@@ -162,7 +162,7 @@ int il_send_cmd_sync(struct il_priv *il, struct il_host_cmd *cmd)
cmd_idx = il_enqueue_hcmd(il, cmd);
if (cmd_idx < 0) {
ret = cmd_idx;
IL_ERR(il, "Error sending %s: enqueue_hcmd failed: %d\n",
IL_ERR("Error sending %s: enqueue_hcmd failed: %d\n",
il_get_cmd_string(cmd->id), ret);
goto out;
}
......@@ -172,7 +172,7 @@ int il_send_cmd_sync(struct il_priv *il, struct il_host_cmd *cmd)
HOST_COMPLETE_TIMEOUT);
if (!ret) {
if (test_bit(STATUS_HCMD_ACTIVE, &il->status)) {
IL_ERR(il,
IL_ERR(
"Error sending %s: time out after %dms.\n",
il_get_cmd_string(cmd->id),
jiffies_to_msecs(HOST_COMPLETE_TIMEOUT));
......@@ -187,19 +187,19 @@ int il_send_cmd_sync(struct il_priv *il, struct il_host_cmd *cmd)
}
if (test_bit(STATUS_RF_KILL_HW, &il->status)) {
IL_ERR(il, "Command %s aborted: RF KILL Switch\n",
IL_ERR("Command %s aborted: RF KILL Switch\n",
il_get_cmd_string(cmd->id));
ret = -ECANCELED;
goto fail;
}
if (test_bit(STATUS_FW_ERROR, &il->status)) {
IL_ERR(il, "Command %s failed: FW Error\n",
IL_ERR("Command %s failed: FW Error\n",
il_get_cmd_string(cmd->id));
ret = -EIO;
goto fail;
}
if ((cmd->flags & CMD_WANT_SKB) && !cmd->reply_page) {
IL_ERR(il, "Error: Response NULL in '%s'\n",
IL_ERR("Error: Response NULL in '%s'\n",
il_get_cmd_string(cmd->id));
ret = -EIO;
goto cancel;
......
......@@ -132,7 +132,7 @@ static inline int _il_grab_nic_access(struct il_priv *il)
CSR_GP_CNTRL_REG_FLAG_GOING_TO_SLEEP), 15000);
if (ret < 0) {
val = _il_read32(il, CSR_GP_CNTRL);
IL_ERR(il,
IL_ERR(
"MAC is in deep sleep!. CSR_GP_CNTRL = 0x%08X\n", val);
_il_write32(il, CSR_RESET,
CSR_RESET_REG_FLAG_FORCE_NMI);
......
......@@ -88,7 +88,7 @@ static inline u8 il_blink_compensation(struct il_priv *il,
u8 time, u16 compensation)
{
if (!compensation) {
IL_ERR(il, "undefined blink compensation: "
IL_ERR("undefined blink compensation: "
"use pre-defined blinking time\n");
return time;
}
......
......@@ -136,7 +136,7 @@ il_power_set_mode(struct il_priv *il, struct il_powertable_cmd *cmd,
memcpy(&il->power_data.sleep_cmd, cmd, sizeof(*cmd));
} else
IL_ERR(il, "set power fail, ret = %d", ret);
IL_ERR("set power fail, ret = %d", ret);
return ret;
}
......
......@@ -341,7 +341,7 @@ static int il_scan_initiate(struct il_priv *il,
cancel_delayed_work(&il->scan_check);
if (!il_is_ready_rf(il)) {
IL_WARN(il, "Request scan called when driver not ready.\n");
IL_WARN("Request scan called when driver not ready.\n");
return -EIO;
}
......
......@@ -41,7 +41,7 @@ static void il_sta_ucode_activate(struct il_priv *il, u8 sta_id)
{
if (!(il->stations[sta_id].used & IL_STA_DRIVER_ACTIVE))
IL_ERR(il,
IL_ERR(
"ACTIVATE a non DRIVER active station id %u addr %pM\n",
sta_id, il->stations[sta_id].sta.sta.addr);
......@@ -67,7 +67,7 @@ static int il_process_add_sta_resp(struct il_priv *il,
int ret = -EIO;
if (pkt->hdr.flags & IL_CMD_FAILED_MSK) {
IL_ERR(il, "Bad return from REPLY_ADD_STA (0x%08X)\n",
IL_ERR("Bad return from REPLY_ADD_STA (0x%08X)\n",
pkt->hdr.flags);
return ret;
}
......@@ -84,16 +84,16 @@ static int il_process_add_sta_resp(struct il_priv *il,
ret = 0;
break;
case ADD_STA_NO_ROOM_IN_TABLE:
IL_ERR(il, "Adding station %d failed, no room in table.\n",
IL_ERR("Adding station %d failed, no room in table.\n",
sta_id);
break;
case ADD_STA_NO_BLOCK_ACK_RESOURCE:
IL_ERR(il,
IL_ERR(
"Adding station %d failed, no block ack resource.\n",
sta_id);
break;
case ADD_STA_MODIFY_NON_EXIST_STA:
IL_ERR(il, "Attempting to modify non-existing station %d\n",
IL_ERR("Attempting to modify non-existing station %d\n",
sta_id);
break;
default:
......@@ -206,7 +206,7 @@ static void il_set_ht_add_station(struct il_priv *il, u8 index,
case WLAN_HT_CAP_SM_PS_DISABLED:
break;
default:
IL_WARN(il, "Invalid MIMO PS mode %d\n", mimo_ps_mode);
IL_WARN("Invalid MIMO PS mode %d\n", mimo_ps_mode);
break;
}
......@@ -343,7 +343,7 @@ il_add_station_common(struct il_priv *il,
spin_lock_irqsave(&il->sta_lock, flags_spin);
sta_id = il_prep_station(il, ctx, addr, is_ap, sta);
if (sta_id == IL_INVALID_STATION) {
IL_ERR(il, "Unable to prepare station %pM for addition\n",
IL_ERR("Unable to prepare station %pM for addition\n",
addr);
spin_unlock_irqrestore(&il->sta_lock, flags_spin);
return -EINVAL;
......@@ -380,7 +380,7 @@ il_add_station_common(struct il_priv *il,
ret = il_send_add_sta(il, &sta_cmd, CMD_SYNC);
if (ret) {
spin_lock_irqsave(&il->sta_lock, flags_spin);
IL_ERR(il, "Adding station %pM failed.\n",
IL_ERR("Adding station %pM failed.\n",
il->stations[sta_id].sta.sta.addr);
il->stations[sta_id].used &= ~IL_STA_DRIVER_ACTIVE;
il->stations[sta_id].used &= ~IL_STA_UCODE_INPROGRESS;
......@@ -402,7 +402,7 @@ static void il_sta_ucode_deactivate(struct il_priv *il, u8 sta_id)
if ((il->stations[sta_id].used &
(IL_STA_UCODE_ACTIVE | IL_STA_DRIVER_ACTIVE)) !=
IL_STA_UCODE_ACTIVE)
IL_ERR(il, "removed non active STA %u\n", sta_id);
IL_ERR("removed non active STA %u\n", sta_id);
il->stations[sta_id].used &= ~IL_STA_UCODE_ACTIVE;
......@@ -440,7 +440,7 @@ static int il_send_remove_station(struct il_priv *il,
pkt = (struct il_rx_packet *)cmd.reply_page;
if (pkt->hdr.flags & IL_CMD_FAILED_MSK) {
IL_ERR(il, "Bad return from REPLY_REMOVE_STA (0x%08X)\n",
IL_ERR("Bad return from REPLY_REMOVE_STA (0x%08X)\n",
pkt->hdr.flags);
ret = -EIO;
}
......@@ -458,7 +458,7 @@ static int il_send_remove_station(struct il_priv *il,
break;
default:
ret = -EIO;
IL_ERR(il, "REPLY_REMOVE_STA failed\n");
IL_ERR("REPLY_REMOVE_STA failed\n");
break;
}
}
......@@ -618,7 +618,7 @@ il_restore_stations(struct il_priv *il, struct il_rxon_context *ctx)
ret = il_send_add_sta(il, &sta_cmd, CMD_SYNC);
if (ret) {
spin_lock_irqsave(&il->sta_lock, flags_spin);
IL_ERR(il, "Adding station %pM failed.\n",
IL_ERR("Adding station %pM failed.\n",
il->stations[i].sta.sta.addr);
il->stations[i].used &=
~IL_STA_DRIVER_ACTIVE;
......@@ -808,7 +808,7 @@ int il_mac_sta_remove(struct ieee80211_hw *hw,
sta->addr);
ret = il_remove_station(il, sta_common->sta_id, sta->addr);
if (ret)
IL_ERR(il, "Error removing station %pM\n",
IL_ERR("Error removing station %pM\n",
sta->addr);
mutex_unlock(&il->mutex);
return ret;
......
......@@ -299,7 +299,7 @@ static int il_tx_queue_alloc(struct il_priv *il,
txq->txb = kzalloc(sizeof(txq->txb[0]) *
TFD_QUEUE_SIZE_MAX, GFP_KERNEL);
if (!txq->txb) {
IL_ERR(il, "kmalloc for auxiliary BD "
IL_ERR("kmalloc for auxiliary BD "
"structures failed\n");
goto error;
}
......@@ -312,7 +312,7 @@ static int il_tx_queue_alloc(struct il_priv *il,
txq->tfds = dma_alloc_coherent(dev, tfd_sz, &txq->q.dma_addr,
GFP_KERNEL);
if (!txq->tfds) {
IL_ERR(il, "pci_alloc_consistent(%zd) failed\n", tfd_sz);
IL_ERR("pci_alloc_consistent(%zd) failed\n", tfd_sz);
goto error;
}
txq->q.id = id;
......@@ -461,7 +461,7 @@ int il_enqueue_hcmd(struct il_priv *il, struct il_host_cmd *cmd)
BUG_ON(fix_size > IL_MAX_CMD_SIZE);
if (il_is_rfkill(il) || il_is_ctkill(il)) {
IL_WARN(il, "Not sending command - %s KILL\n",
IL_WARN("Not sending command - %s KILL\n",
il_is_rfkill(il) ? "RF" : "CT");
return -EIO;
}
......@@ -471,7 +471,7 @@ int il_enqueue_hcmd(struct il_priv *il, struct il_host_cmd *cmd)
if (il_queue_space(q) < ((cmd->flags & CMD_ASYNC) ? 2 : 1)) {
spin_unlock_irqrestore(&il->hcmd_lock, flags);
IL_ERR(il, "Restarting adapter due to command queue full\n");
IL_ERR("Restarting adapter due to command queue full\n");
queue_work(il->workqueue, &il->restart);
return -ENOSPC;
}
......@@ -566,7 +566,7 @@ static void il_hcmd_queue_reclaim(struct il_priv *il, int txq_id,
int nfreed = 0;
if ((idx >= q->n_bd) || (il_queue_used(q, idx) == 0)) {
IL_ERR(il, "Read index for DMA queue txq id (%d), index %d, "
IL_ERR("Read index for DMA queue txq id (%d), index %d, "
"is out of range [0-%d] %d %d.\n", txq_id,
idx, q->n_bd, q->write_ptr, q->read_ptr);
return;
......@@ -576,7 +576,7 @@ static void il_hcmd_queue_reclaim(struct il_priv *il, int txq_id,
q->read_ptr = il_queue_inc_wrap(q->read_ptr, q->n_bd)) {
if (nfreed++ > 0) {
IL_ERR(il, "HCMD skipped: index (%d) %d %d\n", idx,
IL_ERR("HCMD skipped: index (%d) %d %d\n", idx,
q->write_ptr, q->read_ptr);
queue_work(il->workqueue, &il->restart);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment