diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2021-05-27 11:41:36 +0900 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-05-27 11:15:31 +0100 |
commit | 1f9c82b5ab83ff24f5c2b62bf9a912e4aef8905e (patch) | |
tree | dd457236376b58e3caf43186657d8cc8916f9818 /sound/soc/sh/rcar/dvc.c | |
parent | 1788a1520185e69f62e56dd23b33a0992e8187aa (diff) | |
download | linux-stable-1f9c82b5ab83ff24f5c2b62bf9a912e4aef8905e.tar.gz linux-stable-1f9c82b5ab83ff24f5c2b62bf9a912e4aef8905e.tar.bz2 linux-stable-1f9c82b5ab83ff24f5c2b62bf9a912e4aef8905e.zip |
ASoC: rsnd: add debugfs support
Current rsnd supports #define DEBUG, but it is not helpful
if issue happen after 4-5 hours.
This patch adds debugfs support for it.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Message-Id: <87y2c0lwyn.wl-kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sh/rcar/dvc.c')
-rw-r--r-- | sound/soc/sh/rcar/dvc.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/sound/soc/sh/rcar/dvc.c b/sound/soc/sh/rcar/dvc.c index 8d91c0eb0880..1943ac1ff803 100644 --- a/sound/soc/sh/rcar/dvc.c +++ b/sound/soc/sh/rcar/dvc.c @@ -285,6 +285,19 @@ static struct dma_chan *rsnd_dvc_dma_req(struct rsnd_dai_stream *io, mod, "tx"); } +#ifdef CONFIG_DEBUG_FS +static void rsnd_dvc_debug_info(struct seq_file *m, + struct rsnd_dai_stream *io, + struct rsnd_mod *mod) +{ + rsnd_debugfs_mod_reg_show(m, mod, RSND_GEN2_SCU, + 0xe00 + rsnd_mod_id(mod) * 0x100, 0x60); +} +#define DEBUG_INFO .debug_info = rsnd_dvc_debug_info +#else +#define DEBUG_INFO +#endif + static struct rsnd_mod_ops rsnd_dvc_ops = { .name = DVC_NAME, .dma_req = rsnd_dvc_dma_req, @@ -293,6 +306,7 @@ static struct rsnd_mod_ops rsnd_dvc_ops = { .quit = rsnd_dvc_quit, .pcm_new = rsnd_dvc_pcm_new, .get_status = rsnd_mod_get_status, + DEBUG_INFO }; struct rsnd_mod *rsnd_dvc_mod_get(struct rsnd_priv *priv, int id) |