summaryrefslogtreecommitdiff
path: root/sound/soc/sh/rcar/gen.c
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2014-08-04 19:31:05 +0400
committerMark Brown <broonie@linaro.org>2014-08-04 19:31:05 +0400
commitf0d766adbcac4eff4a114844b56d64aef1b8f5cd (patch)
treef8099e682afb9ef30d3770700c28b8cc8a042711 /sound/soc/sh/rcar/gen.c
parent4a226ec97d797f4be486aab93458fc56a7d4de8c (diff)
parentd0ab92d63cd6df4c47d93940bd5e4e7737fa4909 (diff)
downloadlinux-f0d766adbcac4eff4a114844b56d64aef1b8f5cd.tar.xz
Merge tag 'asoc-v3.16-rc5' into asoc-linus
ASoC: Fixes for v3.16 A bigger batch of changes than I would like as I didn't send any for a few weeks without noticing how many had built up. They are almost all driver specific though, larger changes are: - Fixes to the newly added Baytrail/MAX98090 which look like some QA was missed on the microphone detection. - Deletion of some erroniously listed audio formats for Haswell. - Fix debugfs creation in the core so that we don't try to generate multiple directories with the same name, relatively large textually but simple to inspect by eye and test. - A couple of bugfixes for the rcar driver one of which which involves a bit of code motion to move initailisation of some hardware out of common paths into device specific ones. - Ensure both channels are powered up for mono outputs on Arizona devices, involving some simple data tables listing the outputs and a loop over them. - A couple of fixes to save and restore information on suspended and idle Samsung I2S controllers. # gpg: Signature made Tue 22 Jul 2014 00:52:53 BST using RSA key ID 7EA229BD # gpg: Good signature from "Mark Brown <broonie@sirena.org.uk>" # gpg: aka "Mark Brown <broonie@debian.org>" # gpg: aka "Mark Brown <broonie@kernel.org>" # gpg: aka "Mark Brown <broonie@tardis.ed.ac.uk>" # gpg: aka "Mark Brown <broonie@linaro.org>" # gpg: aka "Mark Brown <Mark.Brown@linaro.org>"
Diffstat (limited to 'sound/soc/sh/rcar/gen.c')
-rw-r--r--sound/soc/sh/rcar/gen.c33
1 files changed, 21 insertions, 12 deletions
diff --git a/sound/soc/sh/rcar/gen.c b/sound/soc/sh/rcar/gen.c
index 1dd2b7d38c2c..0280a11c0899 100644
--- a/sound/soc/sh/rcar/gen.c
+++ b/sound/soc/sh/rcar/gen.c
@@ -184,7 +184,7 @@ static int rsnd_gen_regmap_init(struct rsnd_priv *priv,
#define RDMA_CMD_O_N(addr, i) (addr ##_reg - 0x004f8000 + (0x400 * i))
#define RDMA_CMD_O_P(addr, i) (addr ##_reg - 0x001f8000 + (0x400 * i))
-void rsnd_gen_dma_addr(struct rsnd_priv *priv,
+static void rsnd_gen2_dma_addr(struct rsnd_priv *priv,
struct rsnd_dma *dma,
struct dma_slave_config *cfg,
int is_play, int slave_id)
@@ -226,17 +226,6 @@ void rsnd_gen_dma_addr(struct rsnd_priv *priv,
}
};
- cfg->slave_id = slave_id;
- cfg->src_addr = 0;
- cfg->dst_addr = 0;
- cfg->direction = is_play ? DMA_MEM_TO_DEV : DMA_DEV_TO_MEM;
-
- /*
- * gen1 uses default DMA addr
- */
- if (rsnd_is_gen1(priv))
- return;
-
/* it shouldn't happen */
if (use_dvc & !use_src) {
dev_err(dev, "DVC is selected without SRC\n");
@@ -250,6 +239,26 @@ void rsnd_gen_dma_addr(struct rsnd_priv *priv,
id, cfg->src_addr, cfg->dst_addr);
}
+void rsnd_gen_dma_addr(struct rsnd_priv *priv,
+ struct rsnd_dma *dma,
+ struct dma_slave_config *cfg,
+ int is_play, int slave_id)
+{
+ cfg->slave_id = slave_id;
+ cfg->src_addr = 0;
+ cfg->dst_addr = 0;
+ cfg->direction = is_play ? DMA_MEM_TO_DEV : DMA_DEV_TO_MEM;
+
+ /*
+ * gen1 uses default DMA addr
+ */
+ if (rsnd_is_gen1(priv))
+ return;
+
+ rsnd_gen2_dma_addr(priv, dma, cfg, is_play, slave_id);
+}
+
+
/*
* Gen2
*/