aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlegacy/iwl-3945.c
diff options
context:
space:
mode:
authorStanislaw Gruszka <sgruszka@redhat.com>2011-08-26 09:43:47 -0400
committerStanislaw Gruszka <sgruszka@redhat.com>2011-11-15 06:26:28 -0500
commitebf0d90d12cf013019005a8ee7d1bc8599935356 (patch)
treef27891764f31133a39f2a6f3280987e3612a75e7 /drivers/net/wireless/iwlegacy/iwl-3945.c
parentb73bb5f13bb60735a846b73125e297ab6e3eece5 (diff)
iwlegacy: s/statistics/stats/
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Diffstat (limited to 'drivers/net/wireless/iwlegacy/iwl-3945.c')
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-3945.c44
1 files changed, 22 insertions, 22 deletions
diff --git a/drivers/net/wireless/iwlegacy/iwl-3945.c b/drivers/net/wireless/iwlegacy/iwl-3945.c
index ad78d3fb76f0..fa4c33a36f22 100644
--- a/drivers/net/wireless/iwlegacy/iwl-3945.c
+++ b/drivers/net/wireless/iwlegacy/iwl-3945.c
@@ -362,7 +362,7 @@ static void il3945_rx_reply_tx(struct il_priv *il,
362 * 362 *
363 *****************************************************************************/ 363 *****************************************************************************/
364#ifdef CONFIG_IWLEGACY_DEBUGFS 364#ifdef CONFIG_IWLEGACY_DEBUGFS
365static void il3945_accumulative_statistics(struct il_priv *il, 365static void il3945_accumulative_stats(struct il_priv *il,
366 __le32 *stats) 366 __le32 *stats)
367{ 367{
368 int i; 368 int i;
@@ -370,12 +370,12 @@ static void il3945_accumulative_statistics(struct il_priv *il,
370 u32 *accum_stats; 370 u32 *accum_stats;
371 u32 *delta, *max_delta; 371 u32 *delta, *max_delta;
372 372
373 prev_stats = (__le32 *)&il->_3945.statistics; 373 prev_stats = (__le32 *)&il->_3945.stats;
374 accum_stats = (u32 *)&il->_3945.accum_statistics; 374 accum_stats = (u32 *)&il->_3945.accum_stats;
375 delta = (u32 *)&il->_3945.delta_statistics; 375 delta = (u32 *)&il->_3945.delta_stats;
376 max_delta = (u32 *)&il->_3945.max_delta; 376 max_delta = (u32 *)&il->_3945.max_delta;
377 377
378 for (i = sizeof(__le32); i < sizeof(struct il3945_notif_statistics); 378 for (i = sizeof(__le32); i < sizeof(struct il3945_notif_stats);
379 i += sizeof(__le32), stats++, prev_stats++, delta++, 379 i += sizeof(__le32), stats++, prev_stats++, delta++,
380 max_delta++, accum_stats++) { 380 max_delta++, accum_stats++) {
381 if (le32_to_cpu(*stats) > le32_to_cpu(*prev_stats)) { 381 if (le32_to_cpu(*stats) > le32_to_cpu(*prev_stats)) {
@@ -387,30 +387,30 @@ static void il3945_accumulative_statistics(struct il_priv *il,
387 } 387 }
388 } 388 }
389 389
390 /* reset accumulative statistics for "no-counter" type statistics */ 390 /* reset accumulative stats for "no-counter" type stats */
391 il->_3945.accum_statistics.general.temperature = 391 il->_3945.accum_stats.general.temperature =
392 il->_3945.statistics.general.temperature; 392 il->_3945.stats.general.temperature;
393 il->_3945.accum_statistics.general.ttl_timestamp = 393 il->_3945.accum_stats.general.ttl_timestamp =
394 il->_3945.statistics.general.ttl_timestamp; 394 il->_3945.stats.general.ttl_timestamp;
395} 395}
396#endif 396#endif
397 397
398void il3945_hw_rx_statistics(struct il_priv *il, 398void il3945_hw_rx_stats(struct il_priv *il,
399 struct il_rx_buf *rxb) 399 struct il_rx_buf *rxb)
400{ 400{
401 struct il_rx_pkt *pkt = rxb_addr(rxb); 401 struct il_rx_pkt *pkt = rxb_addr(rxb);
402 402
403 D_RX("Statistics notification received (%d vs %d).\n", 403 D_RX("Statistics notification received (%d vs %d).\n",
404 (int)sizeof(struct il3945_notif_statistics), 404 (int)sizeof(struct il3945_notif_stats),
405 le32_to_cpu(pkt->len_n_flags) & FH_RSCSR_FRAME_SIZE_MSK); 405 le32_to_cpu(pkt->len_n_flags) & FH_RSCSR_FRAME_SIZE_MSK);
406#ifdef CONFIG_IWLEGACY_DEBUGFS 406#ifdef CONFIG_IWLEGACY_DEBUGFS
407 il3945_accumulative_statistics(il, (__le32 *)&pkt->u.raw); 407 il3945_accumulative_stats(il, (__le32 *)&pkt->u.raw);
408#endif 408#endif
409 409
410 memcpy(&il->_3945.statistics, pkt->u.raw, sizeof(il->_3945.statistics)); 410 memcpy(&il->_3945.stats, pkt->u.raw, sizeof(il->_3945.stats));
411} 411}
412 412
413void il3945_reply_statistics(struct il_priv *il, 413void il3945_reply_stats(struct il_priv *il,
414 struct il_rx_buf *rxb) 414 struct il_rx_buf *rxb)
415{ 415{
416 struct il_rx_pkt *pkt = rxb_addr(rxb); 416 struct il_rx_pkt *pkt = rxb_addr(rxb);
@@ -418,16 +418,16 @@ void il3945_reply_statistics(struct il_priv *il,
418 418
419 if (le32_to_cpu(*flag) & UCODE_STATISTICS_CLEAR_MSK) { 419 if (le32_to_cpu(*flag) & UCODE_STATISTICS_CLEAR_MSK) {
420#ifdef CONFIG_IWLEGACY_DEBUGFS 420#ifdef CONFIG_IWLEGACY_DEBUGFS
421 memset(&il->_3945.accum_statistics, 0, 421 memset(&il->_3945.accum_stats, 0,
422 sizeof(struct il3945_notif_statistics)); 422 sizeof(struct il3945_notif_stats));
423 memset(&il->_3945.delta_statistics, 0, 423 memset(&il->_3945.delta_stats, 0,
424 sizeof(struct il3945_notif_statistics)); 424 sizeof(struct il3945_notif_stats));
425 memset(&il->_3945.max_delta, 0, 425 memset(&il->_3945.max_delta, 0,
426 sizeof(struct il3945_notif_statistics)); 426 sizeof(struct il3945_notif_stats));
427#endif 427#endif
428 D_RX("Statistics have been cleared\n"); 428 D_RX("Statistics have been cleared\n");
429 } 429 }
430 il3945_hw_rx_statistics(il, rxb); 430 il3945_hw_rx_stats(il, rxb);
431} 431}
432 432
433 433
@@ -437,7 +437,7 @@ void il3945_reply_statistics(struct il_priv *il,
437 * 437 *
438 ******************************************************************************/ 438 ******************************************************************************/
439 439
440/* This is necessary only for a number of statistics, see the caller. */ 440/* This is necessary only for a number of stats, see the caller. */
441static int il3945_is_network_packet(struct il_priv *il, 441static int il3945_is_network_packet(struct il_priv *il,
442 struct ieee80211_hdr *header) 442 struct ieee80211_hdr *header)
443{ 443{