ASoC: meson: axg-tdm: i2s format fixups
Jerome Brunet
maintainercover ASoC: meson: axg-tdm: i2s format fixups
The patchset fixes a few mistakes regarding the format on the i2s bus on the Amlogic axg tdm drivers.
Jerome Brunet (4):
ASoC: meson: axg-tdmin: right_j is not supported
ASoC: meson: axg-tdmout: right_j is not supported
ASoC: meson: axg-tdm: fix sample clock inversion
ASoC: meson: axg-tdm: consistently use SND_SOC_DAIFMT defines
sound/soc/meson/axg-tdm-interface.c | 4 ++-- sound/soc/meson/axg-tdm.h | 2 +- sound/soc/meson/axg-tdmin.c | 1 - sound/soc/meson/axg-tdmout.c | 1 - 4 files changed, 3 insertions(+), 5 deletions(-)
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 1/4 ASoC: meson: axg-tdmin: right_j is not supported
Right justified format is actually not supported by the amlogic tdm input decoder.
--- sound/soc/meson/axg-tdmin.c | 1 - 1 file changed, 1 deletion(-)
sound/soc/meson/axg-tdmin.c +0 -1
@@ -121,7 +121,6 @@ static int axg_tdmin_prepare(struct regmap *map,break ;case SND_SOC_DAIFMT_LEFT_J : -case SND_SOC_DAIFMT_RIGHT_J :case SND_SOC_DAIFMT_DSP_B :break ;
Signature · 1 line
2.20.1
Mark Brown
maintainerApplied "ASoC: meson: axg-tdmin: right_j is not supported" to the asoc tree
The patch
ASoC: meson: axg-tdmin: right_j is not supported
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.2
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
47c317b786b6c1efc2cb3cdb894fd323422fe5eaMon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 13 Jun 2019 13:42:30 +0200
Subject: [PATCH] ASoC: meson: axg-tdmin: right_j is not supported
Right justified format is actually not supported by the amlogic tdm input decoder.
--- sound/soc/meson/axg-tdmin.c | 1 - 1 file changed, 1 deletion(-)
sound/soc/meson/axg-tdmin.c +0 -1
@@ -121,7 +121,6 @@ static int axg_tdmin_prepare(struct regmap *map,break ;case SND_SOC_DAIFMT_LEFT_J : -case SND_SOC_DAIFMT_RIGHT_J :case SND_SOC_DAIFMT_DSP_B :break ;
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 2/4 ASoC: meson: axg-tdmout: right_j is not supported
In reply to Jerome BrunetRight justified format is actually not supported by the amlogic tdm output encoder.
--- sound/soc/meson/axg-tdmout.c | 1 - 1 file changed, 1 deletion(-)
sound/soc/meson/axg-tdmout.c +0 -1
@@ -137,7 +137,6 @@ static int axg_tdmout_prepare(struct regmap *map,break ;case SND_SOC_DAIFMT_LEFT_J : -case SND_SOC_DAIFMT_RIGHT_J :case SND_SOC_DAIFMT_DSP_B : skew +=1 ;break ;
Signature · 1 line
2.20.1
Mark Brown
maintainerApplied "ASoC: meson: axg-tdmout: right_j is not supported" to the asoc tree
The patch
ASoC: meson: axg-tdmout: right_j is not supported
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.2
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
7e0d7d0fbd06af0507611f85dba8daf24832abd9Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 13 Jun 2019 13:42:31 +0200
Subject: [PATCH] ASoC: meson: axg-tdmout: right_j is not supported
Right justified format is actually not supported by the amlogic tdm output encoder.
--- sound/soc/meson/axg-tdmout.c | 1 - 1 file changed, 1 deletion(-)
sound/soc/meson/axg-tdmout.c +0 -1
@@ -137,7 +137,6 @@ static int axg_tdmout_prepare(struct regmap *map,break ;case SND_SOC_DAIFMT_LEFT_J : -case SND_SOC_DAIFMT_RIGHT_J :case SND_SOC_DAIFMT_DSP_B : skew +=1 ;break ;
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 3/4 ASoC: meson: axg-tdm: fix sample clock inversion
In reply to Jerome BrunetThe content of SND_SOC_DAIFMT_FORMAT_MASK is a number, not a bitfield, so the test to check if the format is i2s is wrong. Because of this the clock setting may be wrong. For example, the sample clock gets inverted in DSP B mode, when it should not.
Fix the lrclk invert helper function
--- sound/soc/meson/axg-tdm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/meson/axg-tdm.h +1 -1
@@ -40,7 +40,7 @@ struct axg_tdm_iface {static inline bool axg_tdm_lrclk_invert (unsigned int fmt) { -return (fmt &SND_SOC_DAIFMT_I2S ) ^ +return ((fmt &SND_SOC_DAIFMT_FORMAT_MASK ) ==SND_SOC_DAIFMT_I2S ) ^ !!(fmt & (SND_SOC_DAIFMT_IB_IF |SND_SOC_DAIFMT_NB_IF )); }
Signature · 1 line
2.20.1
Mark Brown
maintainerApplied "ASoC: meson: axg-tdm: fix sample clock inversion" to the asoc tree
The patch
ASoC: meson: axg-tdm: fix sample clock inversion
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.2
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
cb36ff785e868992e96e8b9e5a0c2822b680a9e2Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 13 Jun 2019 13:42:32 +0200
Subject: [PATCH] ASoC: meson: axg-tdm: fix sample clock inversion
The content of SND_SOC_DAIFMT_FORMAT_MASK is a number, not a bitfield, so the test to check if the format is i2s is wrong. Because of this the clock setting may be wrong. For example, the sample clock gets inverted in DSP B mode, when it should not.
Fix the lrclk invert helper function
--- sound/soc/meson/axg-tdm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/meson/axg-tdm.h +1 -1
@@ -40,7 +40,7 @@ struct axg_tdm_iface {static inline bool axg_tdm_lrclk_invert (unsigned int fmt) { -return (fmt &SND_SOC_DAIFMT_I2S ) ^ +return ((fmt &SND_SOC_DAIFMT_FORMAT_MASK ) ==SND_SOC_DAIFMT_I2S ) ^ !!(fmt & (SND_SOC_DAIFMT_IB_IF |SND_SOC_DAIFMT_NB_IF )); }
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 4/4 ASoC: meson: axg-tdm: consistently use SND_SOC_DAIFMT defines
In reply to Jerome BrunetThere a mix of SND_SOC_DAIFMT_ and SND_SOC_DAI_FORMAT_ in axg-tdm-interface.c. Even, if this is currently the same thing, lets use the same group consistently.
--- sound/soc/meson/axg-tdm-interface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
sound/soc/meson/axg-tdm-interface.c +2 -2
@@ -306,8 +306,8 @@ static int axg_tdm_iface_hw_params(struct snd_pcm_substream *substream, }break ; -case SND_SOC_DAI_FORMAT_DSP_A : -case SND_SOC_DAI_FORMAT_DSP_B : +case SND_SOC_DAIFMT_DSP_A : +case SND_SOC_DAIFMT_DSP_B :break ;default :
Signature · 1 line
2.20.1
Mark Brown
maintainerApplied "ASoC: meson: axg-tdm: consistently use SND_SOC_DAIFMT defines" to the asoc tree
The patch
ASoC: meson: axg-tdm: consistently use SND_SOC_DAIFMT defines
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.3
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
05113483fd300d7a4605a726770e7255e29f1ac7Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 13 Jun 2019 13:42:33 +0200
Subject: [PATCH] ASoC: meson: axg-tdm: consistently use SND_SOC_DAIFMT defines
There a mix of SND_SOC_DAIFMT_ and SND_SOC_DAI_FORMAT_ in axg-tdm-interface.c. Even, if this is currently the same thing, lets use the same group consistently.
--- sound/soc/meson/axg-tdm-interface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
sound/soc/meson/axg-tdm-interface.c +2 -2
@@ -306,8 +306,8 @@ static int axg_tdm_iface_hw_params(struct snd_pcm_substream *substream, }break ; -case SND_SOC_DAI_FORMAT_DSP_A : -case SND_SOC_DAI_FORMAT_DSP_B : +case SND_SOC_DAIFMT_DSP_A : +case SND_SOC_DAIFMT_DSP_B :break ;default :
Signature · 1 line
2.20.1