OSDN Git Service

ASoC: uniphier: add digital output volume for UniPhier sound system
authorKatsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
Tue, 8 May 2018 03:16:39 +0000 (12:16 +0900)
committerMark Brown <broonie@kernel.org>
Wed, 9 May 2018 09:40:39 +0000 (18:40 +0900)
commit5a748de0644d16ceb4192ebf785742619b88109b
treedf7f3c3cbe31af36092def4d5016c252f3b265fd
parent0e7b25c673ec916dee8d927fc8de5806d900cba8
ASoC: uniphier: add digital output volume for UniPhier sound system

This patch adds controllers for digital volume of PCM output. Volume
effects simply linear, not dB scale as follows:
  Gained PCM = Original * 0x4000 / Volume

The value range of volume is from 0x0001 to 0xffff. 0x0000 works as
mute. Initial value is 0x4000 (+0dB).

Signed-off-by: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/uniphier/aio-core.c
sound/soc/uniphier/aio-cpu.c
sound/soc/uniphier/aio-reg.h
sound/soc/uniphier/aio.h