diff options
author | Nicolin Chen <nicoleotsuka@gmail.com> | 2018-04-07 21:40:21 -0700 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-04-12 15:30:23 +0100 |
commit | fac8a5a5ea40b03dcbb0f46977094099ba2220b8 (patch) | |
tree | f202c6fc9989a3aa5b431a77f57a99d3302705f7 /scripts/gcc-goto.sh | |
parent | c656941df9bc80f7ec65b92ca73c42f8b0b62628 (diff) |
ASoC: fsl_ssi: Fix mode setting when changing channel number
This is a partial revert (in a cleaner way) of commit ebf08ae3bc90
("ASoC: fsl_ssi: Keep ssi->i2s_net updated") to fix a regression
at test cases when switching between mono and stereo audio.
The problem is that ssi->i2s_net is initialized in set_dai_fmt()
only, while this set_dai_fmt() is only called during the dai-link
probe(). The original patch assumed set_dai_fmt() would be called
during every playback instance, so it failed at the overriding use
cases.
This patch adds the local variable i2s_net back to let regular use
cases still follow the mode settings from the set_dai_fmt().
Meanwhile, the original commit of keeping ssi->i2s_net updated was
to make set_tdm_slot() clean by checking the ssi->i2s_net directly
instead of reading SCR register. However, the change itself is not
necessary (or even harmful) because the set_tdm_slot() might fail
to check the slot number for Normal-Mode-None-Net settings while
mono audio cases still need 2 slots. So this patch can also fix it.
And it adds an extra line of comments to declare ssi->i2s_net does
not reflect the register value but merely the initial setting from
the set_dai_fmt().
Reported-by: Mika Penttilä <mika.penttila@nextfour.com>
Signed-off-by: Nicolin Chen <nicoleotsuka@gmail.com>
Tested-by: Mika Penttilä <mika.penttila@nextfour.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'scripts/gcc-goto.sh')
0 files changed, 0 insertions, 0 deletions