Commit Graph

16 Commits

Author SHA1 Message Date
Pierre-Louis Bossart 7c3727ba7d
ASoC: max98383: fix boolean assignments to true/false
Reported by Coccinelle:

sound/soc/codecs/max98373.c:411:2-20: WARNING: Assignment of bool to 0/1
sound/soc/codecs/max98373.c:922:2-27: WARNING: Assignment of bool to 0/1
sound/soc/codecs/max98373.c:924:2-27: WARNING: Assignment of bool to 0/1

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2019-01-07 16:51:17 +00:00
Ryan Lee 20f2ab247d
ASoC: max98373: Added max98373_reset for stable amp reset
This patch added max98373_reset function to avoid amp software reset failure and code duplication.
Reset verification step has been added for stable amp reset and it repeats verification maximum 3 times when it is failed.
Chip revision ID is available when the amp is in the idle state which means software reset is completed well.
Additional 10ms delay was added for every retrial and maximum 30ms delay can be applied.

Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-12-04 16:29:49 +00:00
Ryan Lee a23f5dc844
ASoC: max98373: Sort DHT Rot Pnt Volume in reverse order
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-10-11 15:37:39 +01:00
Ryan Lee d34c8f37c7
ASoC: max98373: Sort max98373_bde_gain_tlv in reverse order
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-10-11 15:37:38 +01:00
Ryan Lee 6c3beeca42
ASoC: max98373: Sort BDE Limiter Thresh Volume in reverse order
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-10-11 15:37:38 +01:00
Ryan Lee 4cbbc91609
ASoC: max98373: Sort Digital Volume in reverse order
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-10-11 15:37:36 +01:00
Grant Grundler 3004136b90
ASoC: max98373: usleep_range() needs include/delay.h
Commit ca917f9fe1 added use of usleep_range() but not
the corresponding "include <linux/delay.h>". The result is
with Chrome OS won't build because warnings are forced
to be errors:
mnt/host/source/src/third_party/kernel/v4.4/sound/soc/codecs/max98373.c:734:2: error: implicit declaration of function 'usleep_range' [-Werror,-Wimplicit-function-declaration]
        usleep_range(10000, 11000);
        ^

Including delay.h "fixes" this.

Signed-off-by: Grant Grundler <grundler@chromium.org>
Reviewed-by: Benson Leung <bleung@chromium.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-09-07 17:04:10 +01:00
Ryan Lee ca917f9fe1
ASoC: max98373: Added 10ms sleep after amp software reset
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-08-28 20:02:01 +01:00
Ryan Lee 0d22825255
ASoC: max98373: Added speaker FS gain cotnrol register to volatile.
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-08-16 12:09:58 +01:00
Ryan Lee 0717edbdfe
ASoC: max98373: Added software reset register to readable registers
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-08-08 10:54:03 +01:00
Kuninori Morimoto 41572b5455
ASoC: max98373: replace codec to component
Now we can replace Codec to Component. Let's do it.

Note:
	xxx_codec_xxx()		->	xxx_component_xxx()
	.idle_bias_off = 0	->	.idle_bias_on = 1
	.ignore_pmdown_time = 0	->	.use_pmdown_time = 1
	-			->	.endianness = 1
	-			->	.non_legacy_dai_naming = 1

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-02-12 09:50:09 +00:00
Ryan Lee 180cad3c58
ASoC: max98373 Changed SPDX header in C++ comments style
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-01-22 12:23:45 +00:00
Ryan Lee b6158323bb
ASoC: max98373: Modified control names for TLV controls
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-01-10 10:26:37 +00:00
Ryan Lee 3831a5b87f
ASoC: max98373: Added TDM off if parameters are all zeroes
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-01-10 10:26:23 +00:00
Ryan Lee e1053262cf
ASoC: max98373: Added missing blank lines
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-01-10 10:25:53 +00:00
Ryan Lee 2f3d24a135
ASoC: max98373: Added Amplifier Driver
Signed-off-by: Ryan Lee <ryans.lee@maximintegrated.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-01-04 17:17:06 +00:00