qcacld-3.0: Dump wmi/event record after FW down
On third party platforms. there is no crashdump. Such logs are helpful for analysis of crash issue. For debuging purpose, dump wmi cmd/event/credit record history when PLD_FW_DOWN event is received. CONFIG_DUMP_LOG_BUF_CNT is used to limit the number of logs. it's 0 by default on the platforms like LA where crashdump is available. Change-Id: I136e39322b32ff43b88765f390a7393432ca7daa CRs-Fixed: 2857691
This commit is contained in:
4
Kbuild
4
Kbuild
@@ -3517,6 +3517,10 @@ ifdef CONFIG_MAX_LOGS_PER_SEC
|
||||
ccflags-y += -DWLAN_MAX_LOGS_PER_SEC=$(CONFIG_MAX_LOGS_PER_SEC)
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_NON_QC_PLATFORM), y)
|
||||
ccflags-y += -DWLAN_DUMP_LOG_BUF_CNT=$(CONFIG_DUMP_LOG_BUF_CNT)
|
||||
endif
|
||||
|
||||
ifdef CONFIG_SCHED_HISTORY_SIZE
|
||||
ccflags-y += -DWLAN_SCHED_HISTORY_SIZE=$(CONFIG_SCHED_HISTORY_SIZE)
|
||||
endif
|
||||
|
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2012-2020 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2012-2021 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for
|
||||
* any purpose with or without fee is hereby granted, provided that the
|
||||
@@ -343,6 +343,20 @@ void hdd_wext_send_event(struct net_device *dev, unsigned int cmd,
|
||||
}
|
||||
#endif /* WLAN_WEXT_SUPPORT_ENABLE */
|
||||
|
||||
#ifdef WLAN_DUMP_LOG_BUF_CNT
|
||||
/**
|
||||
* hdd_dump_log_buffer() - dump log buffer history
|
||||
*
|
||||
* Reture: None
|
||||
*/
|
||||
void hdd_dump_log_buffer(void);
|
||||
#else
|
||||
static inline
|
||||
void hdd_dump_log_buffer(void)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(WLAN_WEXT_SUPPORT_ENABLE) && defined(HASTINGS_BT_WAR)
|
||||
int hdd_hastings_bt_war_enable_fw(struct hdd_context *hdd_ctx);
|
||||
int hdd_hastings_bt_war_disable_fw(struct hdd_context *hdd_ctx);
|
||||
|
@@ -1947,7 +1947,7 @@ wlan_hdd_pld_uevent(struct device *dev, struct pld_uevent_data *event_data)
|
||||
switch (event_data->uevent) {
|
||||
case PLD_FW_DOWN:
|
||||
hdd_debug("Received firmware down indication");
|
||||
|
||||
hdd_dump_log_buffer();
|
||||
cds_set_target_ready(false);
|
||||
cds_set_recovery_in_progress(true);
|
||||
|
||||
|
@@ -8833,6 +8833,16 @@ static void hdd_ioctl_log_buffer(int log_id, uint32_t count)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef WLAN_DUMP_LOG_BUF_CNT
|
||||
void hdd_dump_log_buffer(void)
|
||||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i <= MGMT_EVENT_LOG; i++)
|
||||
hdd_ioctl_log_buffer(i, WLAN_DUMP_LOG_BUF_CNT);
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_DP_TRACE
|
||||
void hdd_set_dump_dp_trace(uint16_t cmd_type, uint16_t count)
|
||||
{
|
||||
|
Reference in New Issue
Block a user