diff options
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/mvm/utils.c')
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/utils.c b/drivers/net/wireless/intel/iwlwifi/mvm/utils.c index d116c6ae18ff..e8659bf50890 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/utils.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/utils.c | |||
@@ -463,6 +463,9 @@ static void iwl_mvm_dump_umac_error_log(struct iwl_mvm *mvm) | |||
463 | iwl_trans_read_mem_bytes(trans, mvm->umac_error_event_table, &table, | 463 | iwl_trans_read_mem_bytes(trans, mvm->umac_error_event_table, &table, |
464 | sizeof(table)); | 464 | sizeof(table)); |
465 | 465 | ||
466 | if (table.valid) | ||
467 | mvm->fwrt.dump.umac_err_id = table.error_id; | ||
468 | |||
466 | if (ERROR_START_OFFSET <= table.valid * ERROR_ELEM_SIZE) { | 469 | if (ERROR_START_OFFSET <= table.valid * ERROR_ELEM_SIZE) { |
467 | IWL_ERR(trans, "Start IWL Error Log Dump:\n"); | 470 | IWL_ERR(trans, "Start IWL Error Log Dump:\n"); |
468 | IWL_ERR(trans, "Status: 0x%08lX, count: %d\n", | 471 | IWL_ERR(trans, "Status: 0x%08lX, count: %d\n", |
@@ -486,11 +489,11 @@ static void iwl_mvm_dump_umac_error_log(struct iwl_mvm *mvm) | |||
486 | IWL_ERR(mvm, "0x%08X | isr status reg\n", table.nic_isr_pref); | 489 | IWL_ERR(mvm, "0x%08X | isr status reg\n", table.nic_isr_pref); |
487 | } | 490 | } |
488 | 491 | ||
489 | static void iwl_mvm_dump_lmac_error_log(struct iwl_mvm *mvm, u32 base) | 492 | static void iwl_mvm_dump_lmac_error_log(struct iwl_mvm *mvm, u8 lmac_num) |
490 | { | 493 | { |
491 | struct iwl_trans *trans = mvm->trans; | 494 | struct iwl_trans *trans = mvm->trans; |
492 | struct iwl_error_event_table table; | 495 | struct iwl_error_event_table table; |
493 | u32 val; | 496 | u32 val, base = mvm->error_event_table[lmac_num]; |
494 | 497 | ||
495 | if (mvm->fwrt.cur_fw_img == IWL_UCODE_INIT) { | 498 | if (mvm->fwrt.cur_fw_img == IWL_UCODE_INIT) { |
496 | if (!base) | 499 | if (!base) |
@@ -541,7 +544,7 @@ static void iwl_mvm_dump_lmac_error_log(struct iwl_mvm *mvm, u32 base) | |||
541 | iwl_trans_read_mem_bytes(trans, base, &table, sizeof(table)); | 544 | iwl_trans_read_mem_bytes(trans, base, &table, sizeof(table)); |
542 | 545 | ||
543 | if (table.valid) | 546 | if (table.valid) |
544 | mvm->fwrt.dump.rt_status = table.error_id; | 547 | mvm->fwrt.dump.lmac_err_id[lmac_num] = table.error_id; |
545 | 548 | ||
546 | if (ERROR_START_OFFSET <= table.valid * ERROR_ELEM_SIZE) { | 549 | if (ERROR_START_OFFSET <= table.valid * ERROR_ELEM_SIZE) { |
547 | IWL_ERR(trans, "Start IWL Error Log Dump:\n"); | 550 | IWL_ERR(trans, "Start IWL Error Log Dump:\n"); |
@@ -598,10 +601,10 @@ void iwl_mvm_dump_nic_error_log(struct iwl_mvm *mvm) | |||
598 | return; | 601 | return; |
599 | } | 602 | } |
600 | 603 | ||
601 | iwl_mvm_dump_lmac_error_log(mvm, mvm->error_event_table[0]); | 604 | iwl_mvm_dump_lmac_error_log(mvm, 0); |
602 | 605 | ||
603 | if (mvm->error_event_table[1]) | 606 | if (mvm->error_event_table[1]) |
604 | iwl_mvm_dump_lmac_error_log(mvm, mvm->error_event_table[1]); | 607 | iwl_mvm_dump_lmac_error_log(mvm, 1); |
605 | 608 | ||
606 | iwl_mvm_dump_umac_error_log(mvm); | 609 | iwl_mvm_dump_umac_error_log(mvm); |
607 | } | 610 | } |