mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 10:04:04 +02:00
wifi: iwlwifi: remove dump file name extension support
The options to configure a dump file name extension was added for 2 cases: 1. if we dump because of a missed beacon, we added the mac id and type to the filename. 2. to add the error id of the LMAC/UMAC/TCM/RCM error id to the file name. For 1, there is a bug: in cases in which missed beacon will not trigger a dump (for example in the default preset), and a missed beacon occurred, and eventually there is a dump for a different reason, the dump file name will contain the mac type and id even thought the dump has nothing to do with a missed beacon. Anyway, both cases are no longer required. Remove the code. Reviewed-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://patch.msgid.link/20250826184046.d97f93fd1147.I7d0b056b6f9c38cafc53a0f29e0cf1236e2d2e8c@changeid
This commit is contained in:
parent
a055bbb7bc
commit
6504e3f4c0
|
|
@ -2478,36 +2478,6 @@ static u32 iwl_dump_ini_info(struct iwl_fw_runtime *fwrt,
|
|||
return entry->size;
|
||||
}
|
||||
|
||||
static u32 iwl_dump_ini_file_name_info(struct iwl_fw_runtime *fwrt,
|
||||
struct list_head *list)
|
||||
{
|
||||
struct iwl_fw_ini_dump_entry *entry;
|
||||
struct iwl_dump_file_name_info *tlv;
|
||||
u32 len = strnlen(fwrt->trans->dbg.dump_file_name_ext,
|
||||
IWL_FW_INI_MAX_NAME);
|
||||
|
||||
if (!fwrt->trans->dbg.dump_file_name_ext_valid)
|
||||
return 0;
|
||||
|
||||
entry = vzalloc(sizeof(*entry) + sizeof(*tlv) + len);
|
||||
if (!entry)
|
||||
return 0;
|
||||
|
||||
entry->size = sizeof(*tlv) + len;
|
||||
|
||||
tlv = (void *)entry->data;
|
||||
tlv->type = cpu_to_le32(IWL_INI_DUMP_NAME_TYPE);
|
||||
tlv->len = cpu_to_le32(len);
|
||||
memcpy(tlv->data, fwrt->trans->dbg.dump_file_name_ext, len);
|
||||
|
||||
/* add the dump file name extension tlv to the list */
|
||||
list_add_tail(&entry->list, list);
|
||||
|
||||
fwrt->trans->dbg.dump_file_name_ext_valid = false;
|
||||
|
||||
return entry->size;
|
||||
}
|
||||
|
||||
static const struct iwl_dump_ini_mem_ops iwl_dump_ini_region_ops[] = {
|
||||
[IWL_FW_INI_REGION_INVALID] = {},
|
||||
[IWL_FW_INI_REGION_INTERNAL_BUFFER] = {
|
||||
|
|
@ -2764,7 +2734,6 @@ static u32 iwl_dump_ini_trigger(struct iwl_fw_runtime *fwrt,
|
|||
&iwl_dump_ini_region_ops[IWL_FW_INI_REGION_DRAM_IMR]);
|
||||
|
||||
if (size) {
|
||||
size += iwl_dump_ini_file_name_info(fwrt, list);
|
||||
size += iwl_dump_ini_info(fwrt, trigger, list);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -14,13 +14,6 @@
|
|||
#include "iwl-csr.h"
|
||||
#include "pnvm.h"
|
||||
|
||||
#define FW_ASSERT_LMAC_FATAL 0x70
|
||||
#define FW_ASSERT_LMAC2_FATAL 0x72
|
||||
#define FW_ASSERT_UMAC_FATAL 0x71
|
||||
#define UMAC_RT_NMI_LMAC2_FATAL 0x72
|
||||
#define RT_NMI_INTERRUPT_OTHER_LMAC_FATAL 0x73
|
||||
#define FW_ASSERT_NMI_UNKNOWN 0x84
|
||||
|
||||
/*
|
||||
* Note: This structure is read from the device with IO accesses,
|
||||
* and the reading already does the endian conversion. As it is
|
||||
|
|
@ -103,17 +96,6 @@ struct iwl_umac_error_event_table {
|
|||
#define ERROR_START_OFFSET (1 * sizeof(u32))
|
||||
#define ERROR_ELEM_SIZE (7 * sizeof(u32))
|
||||
|
||||
static bool iwl_fwrt_if_errorid_other_cpu(u32 err_id)
|
||||
{
|
||||
err_id &= 0xFF;
|
||||
|
||||
if ((err_id >= FW_ASSERT_LMAC_FATAL &&
|
||||
err_id <= RT_NMI_INTERRUPT_OTHER_LMAC_FATAL) ||
|
||||
err_id == FW_ASSERT_NMI_UNKNOWN)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
static void iwl_fwrt_dump_umac_error_log(struct iwl_fw_runtime *fwrt)
|
||||
{
|
||||
struct iwl_trans *trans = fwrt->trans;
|
||||
|
|
@ -131,13 +113,6 @@ static void iwl_fwrt_dump_umac_error_log(struct iwl_fw_runtime *fwrt)
|
|||
if (table.valid)
|
||||
fwrt->dump.umac_err_id = table.error_id;
|
||||
|
||||
if (!iwl_fwrt_if_errorid_other_cpu(fwrt->dump.umac_err_id) &&
|
||||
!fwrt->trans->dbg.dump_file_name_ext_valid) {
|
||||
fwrt->trans->dbg.dump_file_name_ext_valid = true;
|
||||
snprintf(fwrt->trans->dbg.dump_file_name_ext, IWL_FW_INI_MAX_NAME,
|
||||
"0x%x", fwrt->dump.umac_err_id);
|
||||
}
|
||||
|
||||
if (ERROR_START_OFFSET <= table.valid * ERROR_ELEM_SIZE) {
|
||||
IWL_ERR(trans, "Start IWL Error Log Dump:\n");
|
||||
IWL_ERR(trans, "Transport status: 0x%08lX, valid: %d\n",
|
||||
|
|
@ -213,13 +188,6 @@ static void iwl_fwrt_dump_lmac_error_log(struct iwl_fw_runtime *fwrt, u8 lmac_nu
|
|||
if (table.valid)
|
||||
fwrt->dump.lmac_err_id[lmac_num] = table.error_id;
|
||||
|
||||
if (!iwl_fwrt_if_errorid_other_cpu(fwrt->dump.lmac_err_id[lmac_num]) &&
|
||||
!fwrt->trans->dbg.dump_file_name_ext_valid) {
|
||||
fwrt->trans->dbg.dump_file_name_ext_valid = true;
|
||||
snprintf(fwrt->trans->dbg.dump_file_name_ext, IWL_FW_INI_MAX_NAME,
|
||||
"0x%x", fwrt->dump.lmac_err_id[lmac_num]);
|
||||
}
|
||||
|
||||
if (ERROR_START_OFFSET <= table.valid * ERROR_ELEM_SIZE) {
|
||||
IWL_ERR(trans, "Start IWL Error Log Dump:\n");
|
||||
IWL_ERR(trans, "Transport status: 0x%08lX, valid: %d\n",
|
||||
|
|
@ -305,16 +273,6 @@ static void iwl_fwrt_dump_tcm_error_log(struct iwl_fw_runtime *fwrt, int idx)
|
|||
|
||||
iwl_trans_read_mem_bytes(trans, base, &table, sizeof(table));
|
||||
|
||||
if (table.valid)
|
||||
fwrt->dump.tcm_err_id[idx] = table.error_id;
|
||||
|
||||
if (!iwl_fwrt_if_errorid_other_cpu(fwrt->dump.tcm_err_id[idx]) &&
|
||||
!fwrt->trans->dbg.dump_file_name_ext_valid) {
|
||||
fwrt->trans->dbg.dump_file_name_ext_valid = true;
|
||||
snprintf(fwrt->trans->dbg.dump_file_name_ext, IWL_FW_INI_MAX_NAME,
|
||||
"0x%x", fwrt->dump.tcm_err_id[idx]);
|
||||
}
|
||||
|
||||
IWL_ERR(fwrt, "TCM%d status:\n", idx + 1);
|
||||
IWL_ERR(fwrt, "0x%08X | error ID\n", table.error_id);
|
||||
IWL_ERR(fwrt, "0x%08X | tcm branchlink2\n", table.blink2);
|
||||
|
|
@ -378,16 +336,6 @@ static void iwl_fwrt_dump_rcm_error_log(struct iwl_fw_runtime *fwrt, int idx)
|
|||
|
||||
iwl_trans_read_mem_bytes(trans, base, &table, sizeof(table));
|
||||
|
||||
if (table.valid)
|
||||
fwrt->dump.rcm_err_id[idx] = table.error_id;
|
||||
|
||||
if (!iwl_fwrt_if_errorid_other_cpu(fwrt->dump.rcm_err_id[idx]) &&
|
||||
!fwrt->trans->dbg.dump_file_name_ext_valid) {
|
||||
fwrt->trans->dbg.dump_file_name_ext_valid = true;
|
||||
snprintf(fwrt->trans->dbg.dump_file_name_ext, IWL_FW_INI_MAX_NAME,
|
||||
"0x%x", fwrt->dump.rcm_err_id[idx]);
|
||||
}
|
||||
|
||||
IWL_ERR(fwrt, "RCM%d status:\n", idx + 1);
|
||||
IWL_ERR(fwrt, "0x%08X | error ID\n", table.error_id);
|
||||
IWL_ERR(fwrt, "0x%08X | rcm branchlink2\n", table.blink2);
|
||||
|
|
|
|||
|
|
@ -146,8 +146,6 @@ struct iwl_fw_runtime {
|
|||
unsigned long non_collect_ts_start[IWL_FW_INI_TIME_POINT_NUM];
|
||||
u32 *d3_debug_data;
|
||||
u32 lmac_err_id[MAX_NUM_LMAC];
|
||||
u32 tcm_err_id[MAX_NUM_TCM];
|
||||
u32 rcm_err_id[MAX_NUM_RCM];
|
||||
u32 umac_err_id;
|
||||
|
||||
struct iwl_txf_iter_data txf_iter_data;
|
||||
|
|
|
|||
|
|
@ -658,8 +658,6 @@ struct iwl_pc_data {
|
|||
* @restart_required: indicates debug restart is required
|
||||
* @last_tp_resetfw: last handling of reset during debug timepoint
|
||||
* @imr_data: IMR debug data allocation
|
||||
* @dump_file_name_ext: dump file name extension
|
||||
* @dump_file_name_ext_valid: dump file name extension if valid or not
|
||||
* @num_pc: number of program counter for cpu
|
||||
* @pc_data: details of the program counter
|
||||
* @yoyo_bin_loaded: tells if a yoyo debug file has been loaded
|
||||
|
|
@ -698,8 +696,6 @@ struct iwl_trans_debug {
|
|||
bool restart_required;
|
||||
u32 last_tp_resetfw;
|
||||
struct iwl_imr_data imr_data;
|
||||
u8 dump_file_name_ext[IWL_FW_INI_MAX_NAME];
|
||||
bool dump_file_name_ext_valid;
|
||||
u32 num_pc;
|
||||
struct iwl_pc_data *pc_data;
|
||||
bool yoyo_bin_loaded;
|
||||
|
|
|
|||
|
|
@ -551,11 +551,6 @@ void iwl_mld_handle_missed_beacon_notif(struct iwl_mld *mld,
|
|||
if (WARN_ON(!vif))
|
||||
return;
|
||||
|
||||
mld->trans->dbg.dump_file_name_ext_valid = true;
|
||||
snprintf(mld->trans->dbg.dump_file_name_ext, IWL_FW_INI_MAX_NAME,
|
||||
"LinkId_%d_MacType_%d", fw_link_id,
|
||||
iwl_mld_mac80211_iftype_to_fw(vif));
|
||||
|
||||
iwl_dbg_tlv_time_point(&mld->fwrt,
|
||||
IWL_FW_INI_TIME_POINT_MISSED_BEACONS, &tp_data);
|
||||
|
||||
|
|
|
|||
|
|
@ -1619,10 +1619,6 @@ iwl_mvm_handle_missed_beacons_notif(struct iwl_mvm *mvm,
|
|||
|
||||
IWL_DEBUG_INFO(mvm, "missed beacon mac_type=%u,\n", mac_type);
|
||||
|
||||
mvm->trans->dbg.dump_file_name_ext_valid = true;
|
||||
snprintf(mvm->trans->dbg.dump_file_name_ext, IWL_FW_INI_MAX_NAME,
|
||||
"MacId_%d_MacType_%d", id, mac_type);
|
||||
|
||||
rx_missed_bcon = le32_to_cpu(mb->consec_missed_beacons);
|
||||
rx_missed_bcon_since_rx =
|
||||
le32_to_cpu(mb->consec_missed_beacons_since_last_rx);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user