ASoC: fsl_ssi: Setup AC97 in fsl_ssi_hw_init()
authorNicolin Chen <nicoleotsuka@gmail.com>
Mon, 12 Feb 2018 22:03:21 +0000 (14:03 -0800)
committerMark Brown <broonie@kernel.org>
Wed, 21 Feb 2018 12:30:56 +0000 (12:30 +0000)
commit37ac30a4bdc397cf1311111264ac35dc8473e1de
treeceac242329cba68aab6b2a9694b1dd30a5efc505
parenta1d154ac2765cf982be0d4d378bc6ba342c467a3
ASoC: fsl_ssi: Setup AC97 in fsl_ssi_hw_init()

AC97 configures most of registers earlier to start a communication
with CODECs in order to successfully initialize CODEC. Currently,
_fsl_ssi_set_dai_fmt() and fsl_ssi_setup_ac97() are called to get
all SSI registers properly set.

Since now the driver has a fsl_ssi_hw_init() to handle all register
initial settings, this patch moves those register settings of AC97
to the fsl_ssi_hw_init() as well.

Meanwhile it applies _fsl_ssi_set_dai_fmt() call to AC97 only since
other formats would be configured via normal set_dai_fmt() directly.

This patch also adds fsl_ssi_hw_clean() to cleanup control bits for
AC97 in the platform remote() function.

Signed-off-by: Nicolin Chen <nicoleotsuka@gmail.com>
Tested-by: Caleb Crome <caleb@crome.org>
Tested-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
Reviewed-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_ssi.c