Lines Matching +full:no +full:- +full:dump +full:- +full:oops

1 // SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
11 /* ACP-specific Common code */
13 #include "../sof-priv.h"
14 #include "../sof-audio.h"
17 #include "acp-dsp-offset.h"
21 * amd_sof_ipc_dump() - This function is called when IPC tx times out.
26 const struct sof_amd_acp_desc *desc = get_chip_info(sdev->pdata); in amd_sof_ipc_dump()
27 u32 base = desc->dsp_intr_base; in amd_sof_ipc_dump()
28 u32 dsp_msg_write = sdev->debug_box.offset + in amd_sof_ipc_dump()
30 u32 dsp_ack_write = sdev->debug_box.offset + in amd_sof_ipc_dump()
32 u32 host_msg_write = sdev->debug_box.offset + in amd_sof_ipc_dump()
34 u32 host_ack_write = sdev->debug_box.offset + in amd_sof_ipc_dump()
44 dev_err(sdev->dev, in amd_sof_ipc_dump()
50 * amd_get_registers() - This function is called in case of DSP oops
56 * @stack: Stores the stack dump.
57 * @stack_words: Size of the stack dump.
64 u32 offset = sdev->dsp_oops_offset; in amd_get_registers()
70 if (xoops->arch_hdr.totalsize > EXCEPT_MAX_HDR_SIZE) { in amd_get_registers()
71 dev_err(sdev->dev, "invalid header size 0x%x. FW oops is bogus\n", in amd_get_registers()
72 xoops->arch_hdr.totalsize); in amd_get_registers()
76 offset += xoops->arch_hdr.totalsize; in amd_get_registers()
85 * amd_sof_dump() - This function is called when a panic message is
100 if (sdev->dsp_oops_offset > sdev->debug_box.offset) { in amd_sof_dump()
101 acp_mailbox_read(sdev, sdev->debug_box.offset, &status, sizeof(u32)); in amd_sof_dump()
107 acp_mailbox_read(sdev, sdev->dsp_box.offset, &status, sizeof(u32)); in amd_sof_dump()
108 sdev->dsp_oops_offset = sdev->dsp_box.offset + sizeof(status); in amd_sof_dump()
124 struct acp_dev_data *acp_data = sdev->pdata->hw_pdata; in amd_sof_sdw_get_slave_info()
126 return sdw_amd_get_slave_info(acp_data->sdw); in amd_sof_sdw_get_slave_info()
133 struct acp_dev_data *acp_data = sdev->pdata->hw_pdata; in amd_sof_sdw_machine_select()
136 if (acp_data->info.count) { in amd_sof_sdw_machine_select()
139 dev_info(sdev->dev, "failed to read slave information\n"); in amd_sof_sdw_machine_select()
142 for (mach = sdev->pdata->desc->alt_machines; mach; mach++) { in amd_sof_sdw_machine_select()
143 if (!mach->links) in amd_sof_sdw_machine_select()
145 link = mach->links; in amd_sof_sdw_machine_select()
146 for (i = 0; i < acp_data->info.count && link->num_adr; link++, i++) { in amd_sof_sdw_machine_select()
147 if (!snd_soc_acpi_sdw_link_slaves_found(sdev->dev, link, in amd_sof_sdw_machine_select()
148 acp_data->sdw->peripherals)) in amd_sof_sdw_machine_select()
151 if (i == acp_data->info.count || !link->num_adr) in amd_sof_sdw_machine_select()
154 if (mach && mach->link_mask) { in amd_sof_sdw_machine_select()
155 mach->mach_params.subsystem_rev = acp_data->pci_rev; in amd_sof_sdw_machine_select()
156 mach->mach_params.links = mach->links; in amd_sof_sdw_machine_select()
157 mach->mach_params.link_mask = mach->link_mask; in amd_sof_sdw_machine_select()
158 mach->mach_params.platform = dev_name(sdev->dev); in amd_sof_sdw_machine_select()
162 dev_info(sdev->dev, "No SoundWire machine driver found\n"); in amd_sof_sdw_machine_select()
175 struct snd_sof_pdata *sof_pdata = sdev->pdata; in amd_sof_machine_select()
176 struct acp_dev_data *acp_data = sdev->pdata->hw_pdata; in amd_sof_machine_select()
177 const struct sof_dev_desc *desc = sof_pdata->desc; in amd_sof_machine_select()
180 if (desc->machines) in amd_sof_machine_select()
181 mach = snd_soc_acpi_find_machine(desc->machines); in amd_sof_machine_select()
185 dev_warn(sdev->dev, "No matching ASoC machine driver found\n"); in amd_sof_machine_select()
190 mach->mach_params.subsystem_rev = acp_data->pci_rev; in amd_sof_machine_select()
191 sof_pdata->tplg_filename = mach->sof_tplg_filename; in amd_sof_machine_select()
192 sof_pdata->fw_filename = mach->fw_filename; in amd_sof_machine_select()