mirror of
https://github.com/torvalds/linux.git
synced 2024-11-15 08:31:55 +00:00
18ebffe4d0
This patch adds debug support for imx platforms. This is important in order to gather information about the state of the DSP in case of an oops and the reason for the oops. This is done by checking if a message with a panic code has been placed in the debug box, in the imx8_dsp_handle_request function from sof/imx. If positive, the function imx8_dump, added in common, will be called. The first step is to gather information about the registers, filename, line number and stack by calling the imx8_get_registers, added in common. Then the information will be printed to the console by calling the get_status function. Signed-off-by: Iulian Olaru <iulianolaru249@yahoo.com> Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com> Reviewed-by: Daniel Baluta <daniel.baluta@gmail.com> Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Link: https://lore.kernel.org/r/20200917105633.2579047-2-kai.vehmanen@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
17 lines
413 B
C
17 lines
413 B
C
/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */
|
|
|
|
#ifndef __IMX_COMMON_H__
|
|
#define __IMX_COMMON_H__
|
|
|
|
#define EXCEPT_MAX_HDR_SIZE 0x400
|
|
#define IMX8_STACK_DUMP_SIZE 32
|
|
|
|
void imx8_get_registers(struct snd_sof_dev *sdev,
|
|
struct sof_ipc_dsp_oops_xtensa *xoops,
|
|
struct sof_ipc_panic_info *panic_info,
|
|
u32 *stack, size_t stack_words);
|
|
|
|
void imx8_dump(struct snd_sof_dev *sdev, u32 flags);
|
|
|
|
#endif
|