wifi: ath12k: configure RDDM size to MHI for device recovery

RDDM is Ram Dump Debug Module which is used to debug issues when the
firmware encounters an error. The rddm_size is needed by the firmware
while MHI goes to the RDDM state. Provide the size to MHI subsystem so
that the firmware restart works when the firmware crashes.

Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4

Signed-off-by: Wen Gong <quic_wgong@quicinc.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20230721055305.20420-2-quic_wgong@quicinc.com
This commit is contained in:
Wen Gong 2023-10-10 10:27:20 +03:00 committed by Kalle Valo
parent 29ea0d4091
commit ae3ed72020
3 changed files with 9 additions and 0 deletions

View File

@ -911,6 +911,8 @@ static const struct ath12k_hw_params ath12k_hw_params[] = {
.rfkill_pin = 0,
.rfkill_cfg = 0,
.rfkill_on_level = 0,
.rddm_size = 0,
},
{
.name = "wcn7850 hw2.0",
@ -972,6 +974,8 @@ static const struct ath12k_hw_params ath12k_hw_params[] = {
.rfkill_pin = 48,
.rfkill_cfg = 0,
.rfkill_on_level = 1,
.rddm_size = 0x780000,
},
{
.name = "qcn9274 hw2.0",
@ -1031,6 +1035,8 @@ static const struct ath12k_hw_params ath12k_hw_params[] = {
.rfkill_pin = 0,
.rfkill_cfg = 0,
.rfkill_on_level = 0,
.rddm_size = 0,
},
};

View File

@ -190,6 +190,8 @@ struct ath12k_hw_params {
u32 rfkill_pin;
u32 rfkill_cfg;
u32 rfkill_on_level;
u32 rddm_size;
};
struct ath12k_hw_ops {

View File

@ -366,6 +366,7 @@ int ath12k_mhi_register(struct ath12k_pci *ab_pci)
mhi_ctrl->fw_image = ab_pci->amss_path;
mhi_ctrl->regs = ab->mem;
mhi_ctrl->reg_len = ab->mem_len;
mhi_ctrl->rddm_size = ab->hw_params->rddm_size;
ret = ath12k_mhi_get_msi(ab_pci);
if (ret) {