aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/sh/rcar/ssi.c
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2014-11-09 23:00:58 -0500
committerMark Brown <broonie@kernel.org>2014-11-10 09:52:38 -0500
commitd3a768233243b5892a9c74b85896b9e8c017b259 (patch)
tree680670669a916065d34a9f7fd3f2b496370beeb1 /sound/soc/sh/rcar/ssi.c
parent30cc4faf703955cd5cd07da489bd817ae43e3fec (diff)
ASoC: rsnd: fallback to PIO mode if DMA mode was failed
Current Renesas R-Car sound driver probe will be failed if it try to use DMA mode and it couldn't use for some reasons. But PIO mode works even though in such case. This patch try to fallback to PIO mode if DMA mode probing was failed. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sh/rcar/ssi.c')
-rw-r--r--sound/soc/sh/rcar/ssi.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/sound/soc/sh/rcar/ssi.c b/sound/soc/sh/rcar/ssi.c
index cae08b7ffa53..346d3dc66d73 100644
--- a/sound/soc/sh/rcar/ssi.c
+++ b/sound/soc/sh/rcar/ssi.c
@@ -465,8 +465,23 @@ static int rsnd_ssi_dma_probe(struct rsnd_mod *mod,
465static int rsnd_ssi_dma_remove(struct rsnd_mod *mod, 465static int rsnd_ssi_dma_remove(struct rsnd_mod *mod,
466 struct rsnd_dai *rdai) 466 struct rsnd_dai *rdai)
467{ 467{
468 struct rsnd_priv *priv = rsnd_mod_to_priv(mod);
469 struct device *dev = rsnd_priv_to_dev(priv);
470
468 rsnd_dma_quit(rsnd_mod_to_priv(mod), rsnd_mod_to_dma(mod)); 471 rsnd_dma_quit(rsnd_mod_to_priv(mod), rsnd_mod_to_dma(mod));
469 472
473 /*
474 * fallback to PIO
475 *
476 * SSI .probe might be called again.
477 * see
478 * rsnd_rdai_continuance_probe()
479 */
480 mod->ops = &rsnd_ssi_pio_ops;
481
482 dev_info(dev, "%s[%d] fallback to PIO mode\n",
483 rsnd_mod_name(mod), rsnd_mod_id(mod));
484
470 return 0; 485 return 0;
471} 486}
472 487