summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/llvm-utils.c
diff options
context:
space:
mode:
authorOleksandr Suvorov <oleksandr.suvorov@toradex.com>2019-10-09 14:38:41 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-10-11 18:18:50 +0200
commita61e5804ef08f20e9bea8ad8c069e6a1f4a40523 (patch)
treeeb2e3aecf2d0450f30b8193074d5ab93f93bf4f8 /tools/perf/util/llvm-utils.c
parent01ec813e457954d8eeaf768d57d625752d245bc9 (diff)
downloadlinux-stable-a61e5804ef08f20e9bea8ad8c069e6a1f4a40523.tar.gz
linux-stable-a61e5804ef08f20e9bea8ad8c069e6a1f4a40523.tar.bz2
linux-stable-a61e5804ef08f20e9bea8ad8c069e6a1f4a40523.zip
ASoC: sgtl5000: Improve VAG power and mute control
[ Upstream commit b1f373a11d25fc9a5f7679c9b85799fe09b0dc4a ] VAG power control is improved to fit the manual [1]. This patch fixes as minimum one bug: if customer muxes Headphone to Line-In right after boot, the VAG power remains off that leads to poor sound quality from line-in. I.e. after boot: - Connect sound source to Line-In jack; - Connect headphone to HP jack; - Run following commands: $ amixer set 'Headphone' 80% $ amixer set 'Headphone Mux' LINE_IN Change VAG power on/off control according to the following algorithm: - turn VAG power ON on the 1st incoming event. - keep it ON if there is any active VAG consumer (ADC/DAC/HP/Line-In). - turn VAG power OFF when there is the latest consumer's pre-down event come. - always delay after VAG power OFF to avoid pop. - delay after VAG power ON if the initiative consumer is Line-In, this prevents pop during line-in muxing. According to the data sheet [1], to avoid any pops/clicks, the outputs should be muted during input/output routing changes. [1] https://www.nxp.com/docs/en/data-sheet/SGTL5000.pdf Cc: stable@vger.kernel.org Fixes: 9b34e6cc3bc2 ("ASoC: Add Freescale SGTL5000 codec support") Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com> Reviewed-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Reviewed-by: Fabio Estevam <festevam@gmail.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20190719100524.23300-3-oleksandr.suvorov@toradex.com Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools/perf/util/llvm-utils.c')
0 files changed, 0 insertions, 0 deletions