ASoC: Intel: Fixes in Kabylake machine driver for clear playback and recording
Subsystems (3)
v2 cover ASoC: Intel: Fixes in Kabylake machine driver for clear playback and recording
This patch series includes fixes for clean playback and recording in kabylake machine driver. It fixes the below issues in the corresponding patches and the details of each fix is provided in the patch's commit message.
1. Fix cracking noise in rt5663 headphones
2. Fix pop noise of dmic recording
3. Enable 4 slot IV feedback for maxim amps
Harsha Priya (3):
ASoC: Intel: Fix cracking noise in rt5663 headphones for kabylake
platform
ASoC: Intel: Fix pop noise of dmic recording in kabylake platform
using rt5514
ASoC: Intel: Enabling 4 slot IV feedback for max98927 on Kabylake
platform
.../soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 28 +++++++++++----------- 1 file changed, 14 insertions(+), 14 deletions(-)
Signature · 1 line
1.9.1
PATCH v2 1/3 ASoC: Intel: Fix cracking noise in rt5663 headphones for kabylake platform
This patch fixes the cracking noise in rt5663 headphones for kabylake platform by calling the rt5663_sel_asrc_clk_src() for RT5663_AD_STEREO_FILTER as well.
The ASRC function is for asynchronous MCLK and LRCK. For RT5663 ASRC should be enabled to support special i2s clock format like Intel's 100fs. ASRC function will track i2s clock and generate a corresponding system clock for codec. Calling this function helps select the clock source for both RT5663_AD_STEREO_FILTER and RT5663_DA_STEREO_FILTER filters which fixes the crackling sound.
--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +3 -1
@@ -319,7 +319,9 @@ static int kabylake_rt5663_hw_params(struct snd_pcm_substream *substream,int ret;/* use ASRC for internal clocks, as PLL rate isn't multiple of BCLK */ -rt5663_sel_asrc_clk_src (codec_dai->codec,RT5663_DA_STEREO_FILTER ,1 ); +rt5663_sel_asrc_clk_src (codec_dai->codec, +RT5663_DA_STEREO_FILTER |RT5663_AD_STEREO_FILTER , +RT5663_CLK_SEL_I2S1_ASRC ); ret =snd_soc_dai_set_sysclk (codec_dai,RT5663_SCLK_S_MCLK ,24576000 ,SND_SOC_CLOCK_IN );
Signature · 1 line
1.9.1
Re: [v2 1/3] ASoC: Intel: Fix cracking noise in rt5663 headphones for kabylake platform
Quoted 2 lines · Harsha Priya
This patch fixes the cracking noise in rt5663 headphones for kabylake platform by calling the
rt5663_sel_asrc_clk_src()forRT5663_AD_STEREO_FILTERas well.
and it sets ASRC..?
Quoted 3 lines
The ASRC function is for asynchronous MCLK and LRCK. For RT5663 ASRC should be enabled to support special i2s clock format like Intel's 100fs. ASRC function
^^^^
double space
Quoted 28 lines
will track i2s clock and generate a corresponding system clock for codec. Calling this function helps select the clock source for both
RT5663_AD_STEREO_FILTERandRT5663_DA_STEREO_FILTERfilters which fixes the crackling sound.Signed-off-by Harsha Priya <[email protected]>--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +3
-1@@ -319,7 +319,9 @@ static int kabylake_rt5663_hw_params(struct snd_pcm_substream *substream,int ret;/* use ASRC for internal clocks, as PLL rate isn't multiple of BCLK */ -rt5663_sel_asrc_clk_src (codec_dai->codec,RT5663_DA_STEREO_FILTER ,1 ); +rt5663_sel_asrc_clk_src (codec_dai->codec, +RT5663_DA_STEREO_FILTER |RT5663_AD_STEREO_FILTER , +RT5663_CLK_SEL_I2S1_ASRC ); ret =snd_soc_dai_set_sysclk (codec_dai,RT5663_SCLK_S_MCLK ,24576000 ,SND_SOC_CLOCK_IN );Signature · 1 line
1.9.1
Signature · 1 line
~Vinod
Re: [v2 1/3] ASoC: Intel: Fix cracking noise in rt5663 headphones for kabylake platform
Quoted 10 lines
-----Original Message-----
From: Koul, Vinod
Sent: Wednesday, July 26, 2017 7:41 PM
To: N, Harshapriya <[email protected]>
Cc: [email protected]; [email protected]; [email protected]
Subject: Re: [v2 1/3] ASoC: Intel: Fix cracking noise in rt5663 headphones for kabylake platform
Quoted 6 lines
Quoted 2 lines · Harsha Priya
This patch fixes the cracking noise in rt5663 headphones for kabylake platform by calling the
rt5663_sel_asrc_clk_src()for
RT5663_AD_STEREO_FILTERas well.and it sets ASRC..?
Yes. I changed the commit message in my next patch series.
Quoted 44 lines
Quoted 5 lines
The ASRC function is for asynchronous MCLK and LRCK. For RT5663 ASRC should be enabled to support special i2s clock format like Intel's 100fs. ASRC function
^^^^double space
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c static int kabylake_rt5663_hw_params(struct
Quoted 16 lines
will track i2s clock and generate a corresponding system clock for codec. Calling this function helps select the clock source for both
RT5663_AD_STEREO_FILTERandRT5663_DA_STEREO_FILTERfilters which fixes the crackling sound.Signed-off-by Harsha Priya <[email protected]>--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +0
-0@@ -319,7 +319,9 @@ static int kabylake_rt5663_hw_params(struct
snd_pcm_substream*substream,sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c static int kabylake_rt5663_hw_params(struct snd_pcm_substream *substream,
Quoted 4 lines
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +0
-1int ret;/* use ASRC for internal clocks, as PLL rate isn't multiple of BCLK */ - rt5663_sel_asrc_clk_src(codec_dai->codec,
RT5663_DA_STEREO_FILTER, 1);sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c static int kabylake_rt5663_hw_params(struct · line 323
Quoted 2 lines
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +2
-0+ rt5663_sel_asrc_clk_src(codec_dai->codec, + RT5663_DA_STEREO_FILTER |
RT5663_AD_STEREO_FILTER,sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c static int kabylake_rt5663_hw_params(struct snd_pcm_substream *substream,
Quoted 4 lines
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +1
-0+ RT5663_CLK_SEL_I2S1_ASRC); ret = snd_soc_dai_set_sysclk(codec_dai, RT5663_SCLK_S_MCLK, 24576000,
SND_SOC_CLOCK_IN);Quoted 3 lines
--
1.9.1--
~Vinod
Mark Brown
maintainerApplied "ASoC: Intel: Enabling ASRC for RT5663 codec on kabylake platform" to the asoc tree
In reply to Harsha PriyaThe patch
ASoC: Intel: Enabling ASRC for RT5663 codec on kabylake platform
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
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
349d63c33a34e39b205cf116d2406e096a029f8bMon Sep 17 00:00:00 2001
From: Harsha Priya N <[email protected]>
Date: Thu, 27 Jul 2017 17:41:25 -0700
Subject: [PATCH] ASoC: Intel: Enabling ASRC for RT5663 codec on kabylake
platform
This patch fixes the cracking noise in rt5663 headphones for kabylake platform by calling rt5663_sel_asrc_clk_src() for RT5663_AD_STEREO_FILTER to set ASRC.
The ASRC function is for asynchronous MCLK and LRCK. For RT5663 ASRC should be enabled to support special i2s clock format like Intel's 100fs. ASRC function will track i2s clock and generate a corresponding system clock for codec. Calling this function helps select the clock source for both RT5663_AD_STEREO_FILTER and RT5663_DA_STEREO_FILTER filters which fixes the crackling sound.
--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +3 -1
@@ -319,7 +319,9 @@ static int kabylake_rt5663_hw_params(struct snd_pcm_substream *substream,int ret;/* use ASRC for internal clocks, as PLL rate isn't multiple of BCLK */ -rt5663_sel_asrc_clk_src (codec_dai->codec,RT5663_DA_STEREO_FILTER ,1 ); +rt5663_sel_asrc_clk_src (codec_dai->codec, +RT5663_DA_STEREO_FILTER |RT5663_AD_STEREO_FILTER , +RT5663_CLK_SEL_I2S1_ASRC ); ret =snd_soc_dai_set_sysclk (codec_dai,RT5663_SCLK_S_MCLK ,24576000 ,SND_SOC_CLOCK_IN );
Signature · 1 line
2.13.2
PATCH v2 2/3 ASoC: Intel: Fix pop noise of dmic recording in kabylake platform using rt5514
In reply to Harsha PriyaThis patch fixes the pop noise in dmic recording using rt5514 on kabylake platform. This patch enables the rt5514 to use MCLK instead of BLCK as the sysclock which fixes the pop noise.
--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-)
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +2 -11
@@ -351,19 +351,10 @@ static int kabylake_ssp0_hw_params(struct snd_pcm_substream *substream,return ret; } - ret =snd_soc_dai_set_pll (codec_dai,0 , -RT5514_PLL1_S_BCLK ,RT5514_AIF1_BCLK_FREQ , -RT5514_AIF1_SYSCLK_FREQ ); -if (ret <0 ) { -dev_err (rtd->dev,"set bclk err: %d\n" , ret); -return ret; - } - ret =snd_soc_dai_set_sysclk (codec_dai, -RT5514_SCLK_S_PLL1 ,RT5514_AIF1_SYSCLK_FREQ , -SND_SOC_CLOCK_IN ); +RT5514_SCLK_S_MCLK ,24576000 ,SND_SOC_CLOCK_IN );if (ret <0 ) { -dev_err (rtd->dev,"set sclk err: %d\n" , ret); +dev_err (rtd->dev,"set sysclk err: %d\n" , ret);return ret; } }
Signature · 1 line
1.9.1
Re: [v2 2/3] ASoC: Intel: Fix pop noise of dmic recording in kabylake platform using rt5514
Quoted 3 lines · Harsha Priya
This patch fixes the pop noise in dmic recording using rt5514 on kabylake platform. This patch enables the rt5514 to use MCLK instead of BLCK as the sysclock which fixes the pop noise.
Please consider changing patch title to document the change you did so:
"ASoC: Intel: use MCLK instead of BLCK as the sysclock"
describes this patch rather than current one..
Quoted 35 lines
Signed-off-by Harsha Priya <[email protected]>--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-)sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +2
-11@@ -351,19 +351,10 @@ static int kabylake_ssp0_hw_params(struct snd_pcm_substream *substream,return ret; } - ret =snd_soc_dai_set_pll (codec_dai,0 , -RT5514_PLL1_S_BCLK ,RT5514_AIF1_BCLK_FREQ , -RT5514_AIF1_SYSCLK_FREQ ); -if (ret <0 ) { -dev_err (rtd->dev,"set bclk err: %d\n" , ret); -return ret; - } - ret =snd_soc_dai_set_sysclk (codec_dai, -RT5514_SCLK_S_PLL1 ,RT5514_AIF1_SYSCLK_FREQ , -SND_SOC_CLOCK_IN ); +RT5514_SCLK_S_MCLK ,24576000 ,SND_SOC_CLOCK_IN );if (ret <0 ) { -dev_err (rtd->dev,"set sclk err: %d\n" , ret); +dev_err (rtd->dev,"set sysclk err: %d\n" , ret);return ret; } }Signature · 1 line
1.9.1
Signature · 1 line
~Vinod
Mark Brown
maintainerApplied "ASoC: Intel: Use MCLK instead of BLCK as the sysclock for RT5514 codec on kabylake platform" to the asoc tree
In reply to Harsha PriyaThe patch
ASoC: Intel: Use MCLK instead of BLCK as the sysclock for RT5514 codec on kabylake platform
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
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
6512dd4dcf640412637ece8a412e83c3a0046d2fMon Sep 17 00:00:00 2001
From: Harsha Priya N <[email protected]>
Date: Thu, 27 Jul 2017 17:41:26 -0700
Subject: [PATCH] ASoC: Intel: Use MCLK instead of BLCK as the sysclock for
RT5514 codec on kabylake platform
This patch fixes the pop noise in dmic recording using rt5514 on kabylake platform. This patch enables the rt5514 to use MCLK instead of BLCK as the sysclock which fixes the pop noise.
--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-)
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +2 -11
@@ -351,19 +351,10 @@ static int kabylake_ssp0_hw_params(struct snd_pcm_substream *substream,return ret; } - ret =snd_soc_dai_set_pll (codec_dai,0 , -RT5514_PLL1_S_BCLK ,RT5514_AIF1_BCLK_FREQ , -RT5514_AIF1_SYSCLK_FREQ ); -if (ret <0 ) { -dev_err (rtd->dev,"set bclk err: %d\n" , ret); -return ret; - } - ret =snd_soc_dai_set_sysclk (codec_dai, -RT5514_SCLK_S_PLL1 ,RT5514_AIF1_SYSCLK_FREQ , -SND_SOC_CLOCK_IN ); +RT5514_SCLK_S_MCLK ,24576000 ,SND_SOC_CLOCK_IN );if (ret <0 ) { -dev_err (rtd->dev,"set sclk err: %d\n" , ret); +dev_err (rtd->dev,"set sysclk err: %d\n" , ret);return ret; } }
Signature · 1 line
2.13.2
PATCH v2 3/3 ASoC: Intel: Enabling 4 slot IV feedback for max98927 on Kabylake platform
In reply to Harsha PriyaThis patch enables 4 slot IV feedback for max98927 speaker amp codec.
--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-)
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +11 -4
@@ -358,11 +358,18 @@ static int kabylake_ssp0_hw_params(struct snd_pcm_substream *substream,return ret; } } -if (!strcmp (codec_dai->component->name,MAXIM_DEV0_NAME ) || - !strcmp (codec_dai->component->name,MAXIM_DEV1_NAME )) { - ret =snd_soc_dai_set_tdm_slot (codec_dai,0xF0 ,3 ,8 ,16 ); +if (!strcmp (codec_dai->component->name,MAXIM_DEV0_NAME )) { + ret =snd_soc_dai_set_tdm_slot (codec_dai,0x30 ,3 ,8 ,16 );if (ret <0 ) { -dev_err (rtd->dev,"set TDM slot err:%d\n" , ret); +dev_err (rtd->dev,"DEV0 TDM slot err:%d\n" , ret); +return ret; + } + } + +if (!strcmp (codec_dai->component->name,MAXIM_DEV1_NAME )) { + ret =snd_soc_dai_set_tdm_slot (codec_dai,0xC0 ,3 ,8 ,16 ); +if (ret <0 ) { +dev_err (rtd->dev,"DEV1 TDM slot err:%d\n" , ret);return ret; } }
Signature · 1 line
1.9.1
Mark Brown
maintainerApplied "ASoC: Intel: Enabling 4 slot IV feedback for max98927 on Kabylake platform" to the asoc tree
The patch
ASoC: Intel: Enabling 4 slot IV feedback for max98927 on Kabylake platform
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
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
cc4db0e257d6a5d5ae2e2f042ac8d261caaf08fcMon Sep 17 00:00:00 2001
From: Harsha Priya N <[email protected]>
Date: Thu, 27 Jul 2017 17:41:27 -0700
Subject: [PATCH] ASoC: Intel: Enabling 4 slot IV feedback for max98927 on
Kabylake platform
This patch enables 4 slot IV feedback for max98927 speaker amp codec.
--- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-)
sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +11 -4
@@ -365,11 +365,18 @@ static int kabylake_ssp0_hw_params(struct snd_pcm_substream *substream,return ret; } } -if (!strcmp (codec_dai->component->name,MAXIM_DEV0_NAME ) || - !strcmp (codec_dai->component->name,MAXIM_DEV1_NAME )) { - ret =snd_soc_dai_set_tdm_slot (codec_dai,0xF0 ,3 ,8 ,16 ); +if (!strcmp (codec_dai->component->name,MAXIM_DEV0_NAME )) { + ret =snd_soc_dai_set_tdm_slot (codec_dai,0x30 ,3 ,8 ,16 );if (ret <0 ) { -dev_err (rtd->dev,"set TDM slot err:%d\n" , ret); +dev_err (rtd->dev,"DEV0 TDM slot err:%d\n" , ret); +return ret; + } + } + +if (!strcmp (codec_dai->component->name,MAXIM_DEV1_NAME )) { + ret =snd_soc_dai_set_tdm_slot (codec_dai,0xC0 ,3 ,8 ,16 ); +if (ret <0 ) { +dev_err (rtd->dev,"DEV1 TDM slot err:%d\n" , ret);return ret; } }
Signature · 1 line
2.13.2
On Wed, Jul 26, 2017 at 01:47:42PM -0700, Harsha Priya wrote:
what happened to [PATCH .. in the title. I think you used --subject-prefix=v2 insteadof --subject-prefix="PATCH v2"
Quoted 24 lines
This patch series includes fixes for clean playback and recording in kabylake machine driver. It fixes the below issues in the corresponding patches and the details of each fix is provided in the patch's commit message.
1. Fix cracking noise in rt5663 headphones
2. Fix pop noise of dmic recording
3. Enable 4 slot IV feedback for maxim amps
Harsha Priya (3):
ASoC: Intel: Fix cracking noise in rt5663 headphones for kabylake
platform
ASoC: Intel: Fix pop noise of dmic recording in kabylake platformusing rt5514ASoC: Intel: Enabling 4 slot IV feedback for max98927 on Kabylake
platform.../soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 28 +++++++++++----------- 1 file changed, 14 insertions(+), 14 deletions(-)Signature · 1 line
1.9.1
Signature · 1 line
~Vinod