ASoC: rsnd: tidyup return value of rsnd_get_adinr_bit()

Renesas sound driver has rsnd_get_adinr_bit/chan() functions.
It is assuming _bit() returns ADINR :: OTBL,
and _chan() returns ADINR :: CHNUM.
Current _bit() returns both OTBL and CHNUM. This patch fixup it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Kuninori Morimoto 2015-12-17 02:55:51 +00:00 коммит произвёл Mark Brown
Родитель cdf310ce11
Коммит 5e7b9edd92
1 изменённых файлов: 5 добавлений и 9 удалений

Просмотреть файл

@ -227,21 +227,17 @@ u32 rsnd_get_adinr_bit(struct rsnd_mod *mod, struct rsnd_dai_stream *io)
struct rsnd_priv *priv = rsnd_mod_to_priv(mod);
struct snd_pcm_runtime *runtime = rsnd_io_to_runtime(io);
struct device *dev = rsnd_priv_to_dev(priv);
u32 adinr = runtime->channels;
switch (runtime->sample_bits) {
case 16:
adinr |= (8 << 16);
break;
return 8 << 16;
case 32:
adinr |= (0 << 16);
break;
default:
dev_warn(dev, "not supported sample bits\n");
return 0;
return 0 << 16;
}
return adinr;
dev_warn(dev, "not supported sample bits\n");
return 0;
}
u32 rsnd_get_adinr_chan(struct rsnd_mod *mod, struct rsnd_dai_stream *io)