[PATCH 2/2] ASoC: bindings: fsl-asoc-card: Add compatible string for wm8524

2020-06-23 Thread Shengjiu Wang
In order to support wm8524 codec with fsl-asoc-card machine driver, add compatible string "fsl,imx-audio-wm8524". Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl-asoc-card.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetre

[PATCH v2 2/2] ASoC: fsl_mqs: Fix unchecked return value for clk_prepare_enable

2020-06-23 Thread Shengjiu Wang
Fix unchecked return value for clk_prepare_enable, add error handler in fsl_mqs_runtime_resume. Fixes: 9e28f6532c61 ("ASoC: fsl_mqs: Add MQS component driver") Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_mqs.c | 14 -- 1 file changed, 12 insertions(+), 2 deletion

[PATCH v2 1/2] ASoC: fsl_mqs: Don't check clock is NULL before calling clk API

2020-06-23 Thread Shengjiu Wang
Because clk_prepare_enable and clk_disable_unprepare should check input clock parameter is NULL or not internally, then we don't need to check them before calling the function. Fixes: 9e28f6532c61 ("ASoC: fsl_mqs: Add MQS component driver") Signed-off-by: Shengjiu Wang --- sou

[PATCH v2 0/2] Fix unchecked return value for clk_prepare_enable

2020-06-23 Thread Shengjiu Wang
First patch is to remove the check of clock pointer before calling clk API. Second patch is to fix the issue that the return value of clk_prepare_enable is not checked. changes in v2: - split the patch to separate patches Shengjiu Wang (2): ASoC: fsl_mqs: Don't check clock is NULL before

Re: [PATCH] ASoC: fsl_mqs: Fix unchecked return value for clk_prepare_enable

2020-06-22 Thread Shengjiu Wang
On Tue, Jun 23, 2020 at 12:08 AM Markus Elfring wrote: > > > Fix unchecked return value for clk_prepare_enable. > > > > And because clk_prepare_enable and clk_disable_unprepare should > > check input clock parameter is NULL or not, then we don't need > > to check it before calling the function. >

[PATCH] ASoC: fsl_easrc: Fix uninitialized scalar variable in fsl_easrc_set_ctx_format

2020-06-22 Thread Shengjiu Wang
The "ret" in fsl_easrc_set_ctx_format is not initialized, then the unknown value maybe returned by this function. Fixes: 955ac624058f ("ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers") Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_easrc.c | 2 +- 1 file changed, 1 inse

[PATCH] ASoC: fsl_mqs: Fix unchecked return value for clk_prepare_enable

2020-06-22 Thread Shengjiu Wang
Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_mqs.c | 23 ++- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/sound/soc/fsl/fsl_mqs.c b/sound/soc/fsl/fsl_mqs.c index 0c813a45bba7..69aeb0e71844 100644 --- a/sound/soc/fsl/fsl_mqs.c +++ b/sound/soc/fsl/fsl_mqs.c

[PATCH v2] ASoC: fsl_spdif: Add pm runtime function

2020-06-19 Thread Shengjiu Wang
Add pm runtime support and move clock handling there. Close the clocks at suspend to reduce the power consumption. fsl_spdif_suspend is replaced by pm_runtime_force_suspend. fsl_spdif_resume is replaced by pm_runtime_force_resume. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- changes

Re: [PATCH] ASoC: fsl_spdif: Add pm runtime function

2020-06-19 Thread Shengjiu Wang
On Fri, Jun 19, 2020 at 1:51 PM Nicolin Chen wrote: > > On Thu, Jun 18, 2020 at 07:55:34PM +0800, Shengjiu Wang wrote: > > Add pm runtime support and move clock handling there. > > Close the clocks at suspend to reduce the power consumption. > > > >

[PATCH] ASoC: fsl_spdif: Add pm runtime function

2020-06-18 Thread Shengjiu Wang
Add pm runtime support and move clock handling there. Close the clocks at suspend to reduce the power consumption. fsl_spdif_suspend is replaced by pm_runtime_force_suspend. fsl_spdif_resume is replaced by pm_runtime_force_resume. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_spdif.c

[PATCH v3 2/2] ASoC: fsl_spdif: Add support for imx6sx platform

2020-06-17 Thread Shengjiu Wang
flags, we include the soc specific data struct. Signed-off-by: Shengjiu Wang Reviewed-by: Nicolin Chen --- changes in v3 - refine some comments - add Reviewed-by: Nicolin Chen changes in v2 - use shared_root_clk instead ind_root_clk. - add fsl_spdif_can_set_clk_rate function. sound/soc/fsl/fsl_sp

[PATCH v3 1/2] ASoC: bindings: fsl_spdif: Add new compatible string for imx6sx

2020-06-17 Thread Shengjiu Wang
Add new compatible string "fsl,imx6sx-spdif" in the binding document. And add compatible string "fsl,vf610-spdif" which was missed before. Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl,spdif.txt | 6 +- 1 file changed, 5 insertions(+),

Re: [PATCH v2 2/2] ASoC: fsl_spdif: Add support for imx6sx platform

2020-06-17 Thread Shengjiu Wang
On Wed, Jun 17, 2020 at 2:27 PM Nicolin Chen wrote: > > On Wed, Jun 17, 2020 at 12:30:17PM +0800, Shengjiu Wang wrote: > > The one difference on imx6sx platform is that the root clock > > is shared with ASRC module, so we add a new flags > > "shared_root_cloc

[PATCH v2 2/2] ASoC: fsl-asoc-card: Add MQS support

2020-06-16 Thread Shengjiu Wang
roperty. Signed-off-by: Shengjiu Wang --- changes in v2 - update according Nicolin's comments. sound/soc/fsl/fsl-asoc-card.c | 78 +-- 1 file changed, 57 insertions(+), 21 deletions(-) diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.

[PATCH v2 1/2] ASoC: bindings: fsl-asoc-card: Add compatible string for MQS

2020-06-16 Thread Shengjiu Wang
Add compatible string "fsl,imx-audio-mqs" for MQS, and move "audio-routing" property to be optional for MQS doesn't need such property. Signed-off-by: Shengjiu Wang --- changes in v2 - Move "audio-routing" to optional. .../devicetree/bindings/sound/fsl-asoc-card

[PATCH v2 2/2] ASoC: fsl_spdif: Add support for imx6sx platform

2020-06-16 Thread Shengjiu Wang
we include the soc specific data struct. Signed-off-by: Shengjiu Wang --- changes in v2 - use shared_root_clk instead ind_root_clk. - add fsl_spdif_can_set_clk_rate function. sound/soc/fsl/fsl_spdif.c | 50 +++ 1 file changed, 46 insertions(+), 4 deletions(-)

[PATCH v2 1/2] ASoC: bindings: fsl_spdif: Add new compatible string for imx6sx

2020-06-16 Thread Shengjiu Wang
Add new compatible string "fsl,imx6sx-spdif" in the binding document. And add compatible string "fsl,vf610-spdif" which was missed before. Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl,spdif.txt | 6 +- 1 file changed, 5 insertions(+),

Re: [PATCH 2/2] ASoC: fsl_spdif: Add support for imx6sx platform

2020-06-16 Thread Shengjiu Wang
On Wed, Jun 17, 2020 at 7:30 AM Nicolin Chen wrote: > > On Tue, Jun 16, 2020 at 02:42:41PM +0800, Shengjiu Wang wrote: > > The one difference on imx6sx platform is that the root clock > > is shared with ASRC module, so we add a new flags "ind_root_clk" &g

Re: [PATCH 2/2] ASoC: fsl-asoc-card: Add MQS support

2020-06-16 Thread Shengjiu Wang
On Wed, Jun 17, 2020 at 8:50 AM Nicolin Chen wrote: > > On Tue, Jun 16, 2020 at 03:30:37PM +0800, Shengjiu Wang wrote: > > The MQS codec isn't an i2c device, so add a new platform device for it. > > > > MQS only support playback, so add a new audio map. > > > &

[PATCH 2/2] ASoC: fsl-asoc-card: Add MQS support

2020-06-16 Thread Shengjiu Wang
The MQS codec isn't an i2c device, so add a new platform device for it. MQS only support playback, so add a new audio map. Add there maybe "model" property or no "audio-routing" property in devicetree, so add some enhancement for these two property. Signed-off-by: Shengjiu

[PATCH 1/2] ASoC: bindings: fsl-asoc-card: Add compatible string for MQS

2020-06-16 Thread Shengjiu Wang
Add compatible string "fsl,imx-audio-mqs" for MQS Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl-asoc-card.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/sound/fsl-asoc-card.txt b/Documentation/devicetree/bind

[PATCH 2/2] ASoC: fsl_spdif: Add support for imx6sx platform

2020-06-16 Thread Shengjiu Wang
we include the soc specific data struct. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_spdif.c | 43 +++ 1 file changed, 39 insertions(+), 4 deletions(-) diff --git a/sound/soc/fsl/fsl_spdif.c b/sound/soc/fsl/fsl_spdif.c index 1b2e516f9162..00e06803d32f 100644 -

[PATCH 1/2] ASoC: bindings: fsl_spdif: Add new compatible string for imx6sx

2020-06-16 Thread Shengjiu Wang
Add new compatible string "fsl,imx6sx-spdif" in the binding document. And add compatible string "fsl,vf610-spdif" which was missed before. Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl,spdif.txt | 6 +- 1 file changed, 5 insertions(+),

[PATCH v3] ASoC: fsl_ssi: Fix bclk calculation for mono channel

2020-06-15 Thread Shengjiu Wang
ll be sound issue for S24_LE. Fixes: b0a7043d5c2c ("ASoC: fsl_ssi: Caculate bit clock rate using slot number and width") Signed-off-by: Shengjiu Wang --- changes in v3 - update according to Nicolin's comments changes in v2 - refine patch for Network mode and Normal mode. s

Re: [PATCH v2] ASoC: fsl_ssi: Fix bclk calculation for mono channel

2020-06-15 Thread Shengjiu Wang
On Tue, Jun 16, 2020 at 9:59 AM Nicolin Chen wrote: > > On Tue, Jun 16, 2020 at 09:48:39AM +0800, Shengjiu Wang wrote: > > On Tue, Jun 16, 2020 at 7:11 AM Nicolin Chen wrote: > > > > > > On Mon, Jun 15, 2020 at 01:56:18PM +0800, Shengjiu Wang wrote: > > &

Re: [PATCH v2] ASoC: fsl_ssi: Fix bclk calculation for mono channel

2020-06-15 Thread Shengjiu Wang
On Tue, Jun 16, 2020 at 7:11 AM Nicolin Chen wrote: > > On Mon, Jun 15, 2020 at 01:56:18PM +0800, Shengjiu Wang wrote: > > For mono channel, SSI will switch to Normal mode. > > > > In Normal mode and Network mode, the Word Length Control bits > > control the word len

[PATCH v2] ASoC: fsl_ssi: Fix bclk calculation for mono channel

2020-06-15 Thread Shengjiu Wang
ll be sound issue for S24_LE. Fixes: b0a7043d5c2c ("ASoC: fsl_ssi: Caculate bit clock rate using slot number and width") Signed-off-by: Shengjiu Wang --- changes in v2 - refine patch for Network mode and Normal mode. sound/soc/fsl/fsl_ssi.c | 15 +++ 1 file changed, 11 insertio

[RFC PATCH v3 4/4] ASoC: fsl_asrc_dma: Fix data copying speed issue with EDMA

2020-06-12 Thread Shengjiu Wang
fast in ideal ratio mode. So it is reasonable to use the dma channel of Back-End peripheral. then copying speed of DMA is controlled by data consumption speed in the peripheral FIFO, Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc_common.h | 2 ++ sound/soc/fsl/fsl_asrc_dma.c| 26

[RFC PATCH v3 3/4] ASoC: fsl_asrc_dma: Reuse the dma channel if available in Back-End

2020-06-12 Thread Shengjiu Wang
-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc_dma.c | 25 - 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/sound/soc/fsl/fsl_asrc_dma.c b/sound/soc/fsl/fsl_asrc_dma.c index d6a3fc5f87e5..d88e6343e0a2 100644 --- a/sound/soc/fsl/fsl_asrc_dma.c +++ b/sound/soc/fsl

[RFC PATCH v3 2/4] ASoC: dmaengine_pcm: export soc_component_to_pcm

2020-06-12 Thread Shengjiu Wang
In DPCM case, Front-End needs to get the dma chan which has been requested by Back-End and reuse it. Signed-off-by: Shengjiu Wang --- include/sound/dmaengine_pcm.h | 11 +++ sound/soc/soc-generic-dmaengine-pcm.c | 12 2 files changed, 11 insertions(+), 12 deletions

[RFC PATCH v3 1/4] ASoC: soc-card: export snd_soc_lookup_component_nolocked

2020-06-12 Thread Shengjiu Wang
-by: Shengjiu Wang --- include/sound/soc.h | 2 ++ sound/soc/soc-core.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/include/sound/soc.h b/include/sound/soc.h index 74868436ac79..565612a8d690 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -444,6 +444,8 @@ int

[RFC PATCH v3 0/4] Reuse the dma channel if available in Back-End

2020-06-12 Thread Shengjiu Wang
Reuse the dma channel if available in Back-End Shengjiu Wang (4): ASoC: soc-card: export snd_soc_lookup_component_nolocked ASoC: dmaengine_pcm: export soc_component_to_pcm ASoC: fsl_asrc_dma: Reuse the dma channel if available in Back-End ASoC: fsl_asrc_dma: Fix data copying speed issue

Re: [RFC PATCH v2 3/3] ASoC: fsl_asrc_dma: Reuse the dma channel if available in Back-End

2020-06-11 Thread Shengjiu Wang
On Fri, Jun 12, 2020 at 8:33 AM Nicolin Chen wrote: > > On Wed, Jun 10, 2020 at 06:05:49PM +0800, Shengjiu Wang wrote: > > The dma channel has been requested by Back-End cpu dai driver already. > > If fsl_asrc_dma requests dma chan with same dma:tx symlink, then > > the

[RFC PATCH v2 3/3] ASoC: fsl_asrc_dma: Reuse the dma channel if available in Back-End

2020-06-10 Thread Shengjiu Wang
get the dma channel, then reuse it, if can't, then request a new one. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc_common.h | 2 ++ sound/soc/fsl/fsl_asrc_dma.c| 52 + 2 files changed, 42 insertions(+), 12 deletions(-) diff --git a/sound/soc/fsl

[RFC PATCH v2 2/3] ASoC: dmaengine_pcm: export soc_component_to_pcm

2020-06-10 Thread Shengjiu Wang
In DPCM case, Front-End needs to get the dma chan which has been requested by Back-End and reuse it. Signed-off-by: Shengjiu Wang --- include/sound/dmaengine_pcm.h | 11 +++ sound/soc/soc-generic-dmaengine-pcm.c | 12 2 files changed, 11 insertions(+), 12 deletions

[RFC PATCH v2 0/3] ASoC: fsl_asrc_dma: Reuse the dma channel if available in Back-End

2020-06-10 Thread Shengjiu Wang
Reuse the dma channel if available in Back-End Shengjiu Wang (3): ASoC: soc-card: export snd_soc_lookup_component_nolocked ASoC: dmaengine_pcm: export soc_component_to_pcm ASoC: fsl_asrc_dma: Reuse the dma channel if available in Back-End changes in v2: - update according to Mark's

[RFC PATCH v2 1/3] ASoC: soc-card: export snd_soc_lookup_component_nolocked

2020-06-10 Thread Shengjiu Wang
-by: Shengjiu Wang --- include/sound/soc.h | 2 ++ sound/soc/soc-core.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/include/sound/soc.h b/include/sound/soc.h index 74868436ac79..565612a8d690 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -444,6 +444,8 @@ int

[PATCH] ASoC: fsl_ssi: Fix bclk calculation for mono channel

2020-06-09 Thread Shengjiu Wang
issue for S24_LE. Fixes: b0a7043d5c2c ("ASoC: fsl_ssi: Caculate bit clock rate using slot number and width") Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_ssi.c | 5 + 1 file changed, 5 insertions(+) diff --git a/sound/soc/fsl/fsl_ssi.c b/sound/soc/fsl/fsl_ssi.c index ba

[RFC PATCH] ASoC: fsl_asrc_dma: Fix warning "Cannot create DMA dma:tx symlink"

2020-06-08 Thread Shengjiu Wang
a channel which is already requested in Back-End. we export two functions (snd_soc_lookup_component_nolocked and soc_component_to_pcm), if we can get the dma channel, then reuse it. if can't, then request a new one. Signed-off-by: Shengjiu Wang --- include/sound/dmaengine_pcm.h | 11 +

[PATCH] ASoC: fsl-asoc-card: Defer probe when fail to find codec device

2020-06-04 Thread Shengjiu Wang
Defer probe when fail to find codec device, because the codec device maybe probed later than machine driver. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl-asoc-card.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc

[PATCH 3/3] ASoC: fsl_easrc: Fix "Function parameter not described" warnings

2020-06-02 Thread Shengjiu Wang
U DAI drivers") Signed-off-by: Shengjiu Wang Reported-by: kbuild test robot --- sound/soc/fsl/fsl_easrc.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sound/soc/fsl/fsl_easrc.c b/sound/soc/fsl/fsl_easrc.c index 7d8bf9d47842..2f6b3d8bfcfc 100644 --- a/sound/soc/fsl/f

[PATCH 2/3] ASoC: fsl_easrc: Fix -Wunused-but-set-variable

2020-06-02 Thread Shengjiu Wang
but not used [-Wunused-but-set-variable] struct device *dev; ^ Fixes: 955ac624058f ("ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers") Signed-off-by: Shengjiu Wang Reported-by: kbuild test robot --- sound/soc/fsl/fsl_easrc.c | 11 +++ 1 file changed, 3 insert

[PATCH 0/3] ASoC: fsl_easrc: Fix several warnings

2020-06-02 Thread Shengjiu Wang
Fix several warnings with "make W=1" Shengjiu Wang (3): ASoC: fsl_easrc: Fix -Wmissing-prototypes warning ASoC: fsl_easrc: Fix -Wunused-but-set-variable ASoC: fsl_easrc: Fix "Function parameter not described" warnings sound/soc/

[PATCH 1/3] ASoC: fsl_easrc: Fix -Wmissing-prototypes warning

2020-06-02 Thread Shengjiu Wang
;ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers") Signed-off-by: Shengjiu Wang Reported-by: kbuild test robot --- sound/soc/fsl/fsl_easrc.c | 23 +++ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/sound/soc/fsl/fsl_easrc.c b/sound/soc/fsl/fsl_eas

[PATCH] ASoC: fsl_asrc: Fix -Wmissing-prototypes warning

2020-05-25 Thread Shengjiu Wang
From: shengjiu wang COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 sound/soc/fsl/fsl_asrc.c:557:18: warning: no previous prototype for function 'fsl_asrc_get_dma_channel' [-Wmissing-prototypes] struct dma_chan *fsl_asrc_get_dma_channel(struct fsl_asrc_pair *pair, bool

Re: [PATCH] ASoC: fsl_asrc: Merge suspend/resume function to runtime_suspend/resume

2020-05-25 Thread Shengjiu Wang
On Mon, May 25, 2020 at 1:12 PM Nicolin Chen wrote: > > On Fri, May 22, 2020 at 05:57:24PM +0800, Shengjiu Wang wrote: > > With dedicated power domain for asrc, power can be disabled after > > probe and pm runtime suspend, then the value of all registers need to > > b

[PATCH] ASoC: fsl_asrc: Merge suspend/resume function to runtime_suspend/resume

2020-05-22 Thread Shengjiu Wang
-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 70 1 file changed, 27 insertions(+), 43 deletions(-) diff --git a/sound/soc/fsl/fsl_asrc.c b/sound/soc/fsl/fsl_asrc.c index 432936039de4..3ebbe15ac378 100644 --- a/sound/soc/fsl/fsl_asrc.c +++ b/sound/soc

Re: [PATCH] ASoC: fsl: imx-pcm-dma: Don't request dma channel in probe

2020-05-21 Thread Shengjiu Wang
On Wed, May 20, 2020 at 8:38 PM Mark Brown wrote: > > On Wed, May 20, 2020 at 07:22:19PM +0800, Shengjiu Wang wrote: > > > I see some driver also request dma channel in open() or hw_params(). > > how can they avoid the defer probe issue? > > for example: > > sou

Re: [PATCH] ASoC: fsl: imx-pcm-dma: Don't request dma channel in probe

2020-05-20 Thread Shengjiu Wang
Hi On Wed, May 20, 2020 at 5:42 PM Lucas Stach wrote: > > Am Mittwoch, den 20.05.2020, 16:20 +0800 schrieb Shengjiu Wang: > > Hi > > > > On Tue, May 19, 2020 at 6:04 PM Lucas Stach wrote: > > > Am Dienstag, den 19.05.2020, 17:41 +0800 schrieb Shengjiu Wang: &

Re: [PATCH] ASoC: fsl: imx-pcm-dma: Don't request dma channel in probe

2020-05-20 Thread Shengjiu Wang
Hi On Tue, May 19, 2020 at 6:04 PM Lucas Stach wrote: > > Am Dienstag, den 19.05.2020, 17:41 +0800 schrieb Shengjiu Wang: > > There are two requirements that we need to move the request > > of dma channel from probe to open. > > How do you handle -EPROBE_DEFER retu

[PATCH] ASoC: fsl: imx-pcm-dma: Don't request dma channel in probe

2020-05-19 Thread Shengjiu Wang
0003 [ 639.064964] 9fe0: b6f483fc bee8451c b6ee2655 b6e1dcf8 [ 639.070339] fsl-esai-dai 2024000.esai: Cannot create DMA dma:tx symlink Signed-off-by: Shengjiu Wang --- sound/soc/fsl/imx-pcm-dma.c | 173 +--- 1 file changed, 159 insertions(+), 14 deletions

[PATCH v2 2/2] ASoC: fsl_esai: Add new compatible string for imx8qm

2020-05-15 Thread Shengjiu Wang
Add new compatible string "fsl,imx8qm-esai" in the binding document. Signed-off-by: Shengjiu Wang Acked-by: Rob Herring --- Documentation/devicetree/bindings/sound/fsl,esai.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/sound/fsl,e

[PATCH v2 0/2] ASoC: fsl_esai: Add support for imx8qm

2020-05-15 Thread Shengjiu Wang
Add support for imx8qm. Shengjiu Wang (2): ASoC: fsl_esai: introduce SoC specific data ASoC: fsl_esai: Add new compatible string for imx8qm Changes in v2 - drop the 0002 patch in v1, the dma relate limitation should be done in dma driver, or define a new DMA API for it. .../devicetree

[PATCH v2 1/2] ASoC: fsl_esai: introduce SoC specific data

2020-05-15 Thread Shengjiu Wang
Introduce a SoC specific data structure which contains the differences between the different SoCs. This makes it easier to support more differences without having to introduce a new if/else each time. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_esai.c | 46

Re: [PATCH 2/3] ASoC: fsl_esai: Add support for imx8qm

2020-05-15 Thread Shengjiu Wang
On Tue, May 12, 2020 at 8:38 PM Mark Brown wrote: > > On Tue, May 12, 2020 at 10:48:41AM +0800, Shengjiu Wang wrote: > > On Wed, May 6, 2020 at 10:33 AM Shengjiu Wang > > wrote: > > > On Fri, May 1, 2020 at 6:23 PM Mark Brown wrote: > > > > > >

[PATCH] ASoC: fsl_asrc: Set ASR76K and ASR56K based on processing clock

2020-05-12 Thread Shengjiu Wang
The processing clock is different for platforms, so it is better to set ASR76K and ASR56K based on processing clock, rather than hard coding the value for them. Signed-off-by: Shengjiu Wang Signed-off-by: Mihai Serban --- sound/soc/fsl/fsl_asrc.c | 15 ++- 1 file changed, 10

Re: [PATCH 2/3] ASoC: fsl_esai: Add support for imx8qm

2020-05-11 Thread Shengjiu Wang
Hi Mark, Nicolin On Wed, May 6, 2020 at 10:33 AM Shengjiu Wang wrote: > > Hi > > On Fri, May 1, 2020 at 6:23 PM Mark Brown wrote: > > > > On Fri, May 01, 2020 at 04:12:05PM +0800, Shengjiu Wang wrote: > > > The difference for esai on imx8qm is that DMA device i

Re: [PATCH 2/3] ASoC: fsl_esai: Add support for imx8qm

2020-05-05 Thread Shengjiu Wang
Hi On Fri, May 1, 2020 at 6:23 PM Mark Brown wrote: > > On Fri, May 01, 2020 at 04:12:05PM +0800, Shengjiu Wang wrote: > > The difference for esai on imx8qm is that DMA device is EDMA. > > > > EDMA requires the period size to be multiple of maxburst. Otherwise

[PATCH 1/3] ASoC: fsl_esai: introduce SoC specific data

2020-05-01 Thread Shengjiu Wang
Introduce a SoC specific data structure which contains the differences between the different SoCs. This makes it easier to support more differences without having to introduce a new if/else each time. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_esai.c | 46

[PATCH 2/3] ASoC: fsl_esai: Add support for imx8qm

2020-05-01 Thread Shengjiu Wang
of tx/rx maxburst value. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_esai.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/sound/soc/fsl/fsl_esai.c b/sound/soc/fsl/fsl_esai.c index bac65ba7fbad..61b5c0bde788 100644 --- a/sound/soc/fsl/fsl_esai.c +++ b/sound/soc/fsl

[PATCH 3/3] ASoC: fsl_esai: Add new compatible string for imx8qm

2020-05-01 Thread Shengjiu Wang
Add new compatible string "fsl,imx8qm-esai" in the binding document. Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl,esai.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/sound/fsl,esai.txt b/Documentation/

[PATCH 0/3] ASoC: fsl_esai: Add support for imx8qm

2020-05-01 Thread Shengjiu Wang
Add support for imx8qm. Shengjiu Wang (3): ASoC: fsl_esai: introduce SoC specific data ASoC: fsl_esai: Add support for imx8qm ASoC: fsl_esai: Add new compatible string for imx8qm .../devicetree/bindings/sound/fsl,esai.txt| 1 + sound/soc/fsl/fsl_esai.c | 65

[PATCH v2] ASoC: fsl_esai: Disable exception interrupt before scheduling tasklet

2020-04-27 Thread Shengjiu Wang
Disable exception interrupt before scheduling tasklet, otherwise if the tasklet isn't handled immediately, there will be endless xrun interrupt. Fixes: 7ccafa2b3879 ("ASoC: fsl_esai: recover the channel swap after xrun") Signed-off-by: Shengjiu Wang --- changes in v2 - Disable

Re: [PATCH] ASoC: fsl_esai: Remove the tasklet

2020-04-27 Thread Shengjiu Wang
On Fri, Apr 24, 2020 at 5:17 PM Nicolin Chen wrote: > > On Fri, Apr 24, 2020 at 02:54:06PM +0800, Shengjiu Wang wrote: > > Remove tasklet for it may cause the reset operation > > can't be handled immediately, then there will be > > endless xrun interrupt. > > Th

Re: [PATCH v2] ASoC: fsl_easrc: Check for null pointer before dereferencing "ctx" in fsl_easrc_hw_free()

2020-04-25 Thread Shengjiu Wang
On Sat, Apr 25, 2020 at 3:30 PM Shengjiu Wang wrote: > > The patch 955ac624058f: "ASoC: fsl_easrc: Add EASRC ASoC CPU DAI > drivers" from Apr 16, 2020, leads to the following Smatch complaint: > > sound/soc/fsl/fsl_easrc.c:1529 fsl_easrc_hw_free() > warn: variable de

[PATCH v2] ASoC: fsl_easrc: Check for null pointer before dereferencing "ctx" in fsl_easrc_hw_free()

2020-04-25 Thread Shengjiu Wang
drivers") Reported-by: Dan Carpenter Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_easrc.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_easrc.c b/sound/soc/fsl/fsl_easrc.c index 97658e1f4989..20326bffab64 100644 --- a/sound/soc/fsl/fsl_easrc

[PATCH] ASoC: fsl_easrc: Check NULL pinter before dereference

2020-04-24 Thread Shengjiu Wang
drivers") Reported-by: Dan Carpenter Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_easrc.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_easrc.c b/sound/soc/fsl/fsl_easrc.c index 97658e1f4989..20326bffab64 100644 --- a/sound/soc/fsl/fsl_easrc

[PATCH] ASoC: fsl_esai: Remove the tasklet

2020-04-24 Thread Shengjiu Wang
Remove tasklet for it may cause the reset operation can't be handled immediately, then there will be endless xrun interrupt. Fixes: 7ccafa2b3879 ("ASoC: fsl_esai: recover the channel swap after xrun") Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_esai.c | 15 --- 1 fi

Re: [PATCH] ASoC: fsl_esai: Remove expensive print in irq handler

2020-04-21 Thread Shengjiu Wang
Hi On Tue, Apr 21, 2020 at 5:53 PM Mark Brown wrote: > > On Tue, Apr 21, 2020 at 04:41:23PM +0800, Shengjiu Wang wrote: > > Use dev_dbg instead of dev_err in irq handler, the dev_err > > is expensive, we don't need the message to be printed everytime, > > which

[PATCH] ASoC: fsl_esai: Remove expensive print in irq handler

2020-04-21 Thread Shengjiu Wang
Use dev_dbg instead of dev_err in irq handler, the dev_err is expensive, we don't need the message to be printed everytime, which is almost a debug option. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_esai.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc

[PATCH v9 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-16 Thread Shengjiu Wang
-by: Shengjiu Wang Signed-off-by: Cosmin-Gabriel Samoila Acked-by: Nicolin Chen --- sound/soc/fsl/Kconfig | 11 + sound/soc/fsl/Makefile|2 + sound/soc/fsl/fsl_easrc.c | 2114 + sound/soc/fsl/fsl_easrc.h | 651 4 files changed, 2778

[PATCH v9 6/7] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-04-16 Thread Shengjiu Wang
EASRC (Enhanced Asynchronous Sample Rate Converter) is a new IP module found on i.MX8MN. Signed-off-by: Shengjiu Wang Reviewed-by: Rob Herring --- .../devicetree/bindings/sound/fsl,easrc.yaml | 101 ++ 1 file changed, 101 insertions(+) create mode 100644 Documentation

[PATCH v9 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-16 Thread Shengjiu Wang
. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc.c| 82 +++- sound/soc/fsl/fsl_asrc.h| 74 ++ sound/soc/fsl/fsl_asrc_common.h | 106 sound/soc/fsl/fsl_asrc_dma.c| 25

[PATCH v9 4/7] ASoC: fsl_asrc: Support new property fsl,asrc-format

2020-04-16 Thread Shengjiu Wang
In order to align with new ESARC, we add new property fsl,asrc-format. The fsl,asrc-format can replace the fsl,asrc-width, driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl

[PATCH v9 1/7] ASoC: fsl_asrc: rename asrc_priv to asrc

2020-04-16 Thread Shengjiu Wang
In order to move common structure to fsl_asrc_common.h we change the name of asrc_priv to asrc, the asrc_priv will be used by new struct fsl_asrc_priv. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc.c | 298 +-- sound/soc/fsl

[PATCH v9 0/7] ASoC: Add new module driver for new ASRC

2020-04-16 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX8MN, several commits are added for new property fsl,asrc-format Shengjiu Wang (7): ASoC: fsl_asrc: rename asrc_priv to asrc ASoC: dt-bindings: fsl_asrc: Add new property fsl,asrc-format ASoC: fsl-asoc-card: Support new property fsl,asrc-format

[PATCH v9 3/7] ASoC: fsl-asoc-card: Support new property fsl, asrc-format

2020-04-16 Thread Shengjiu Wang
In order to align with new ESARC, we add new property fsl,asrc-format. The fsl,asrc-format can replace the fsl,asrc-width, driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl-asoc

[PATCH v9 2/7] ASoC: dt-bindings: fsl_asrc: Add new property fsl, asrc-format

2020-04-16 Thread Shengjiu Wang
. The fsl,asrc-format can replace the fsl,asrc-width, then driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen Acked-by: Rob Herring --- Documentation/devicetree/bindings/sound/fsl,asrc.txt | 4 1

Re: [PATCH v6 6/7] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-04-14 Thread Shengjiu Wang
Hi Rob On Tue, Apr 14, 2020 at 11:49 PM Rob Herring wrote: > > On Wed, Apr 01, 2020 at 04:45:39PM +0800, Shengjiu Wang wrote: > > EASRC (Enhanced Asynchronous Sample Rate Converter) is a new > > IP module found on i.MX8MN. > > > > Signed-off-by: Shengjiu Wan

[PATCH v8 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-14 Thread Shengjiu Wang
-by: Shengjiu Wang Signed-off-by: Cosmin-Gabriel Samoila Acked-by: Nicolin Chen --- sound/soc/fsl/Kconfig | 11 + sound/soc/fsl/Makefile|2 + sound/soc/fsl/fsl_easrc.c | 2114 + sound/soc/fsl/fsl_easrc.h | 651 4 files changed, 2778

[PATCH v8 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-14 Thread Shengjiu Wang
. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc.c| 82 +++- sound/soc/fsl/fsl_asrc.h| 74 ++ sound/soc/fsl/fsl_asrc_common.h | 106 sound/soc/fsl/fsl_asrc_dma.c| 25

[PATCH v8 6/7] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-04-14 Thread Shengjiu Wang
EASRC (Enhanced Asynchronous Sample Rate Converter) is a new IP module found on i.MX8MN. Signed-off-by: Shengjiu Wang --- .../devicetree/bindings/sound/fsl,easrc.yaml | 101 ++ 1 file changed, 101 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/fsl

[PATCH v8 4/7] ASoC: fsl_asrc: Support new property fsl,asrc-format

2020-04-14 Thread Shengjiu Wang
In order to align with new ESARC, we add new property fsl,asrc-format. The fsl,asrc-format can replace the fsl,asrc-width, driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl

[PATCH v8 3/7] ASoC: fsl-asoc-card: Support new property fsl, asrc-format

2020-04-14 Thread Shengjiu Wang
In order to align with new ESARC, we add new property fsl,asrc-format. The fsl,asrc-format can replace the fsl,asrc-width, driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl-asoc

[PATCH v8 1/7] ASoC: fsl_asrc: rename asrc_priv to asrc

2020-04-14 Thread Shengjiu Wang
In order to move common structure to fsl_asrc_common.h we change the name of asrc_priv to asrc, the asrc_priv will be used by new struct fsl_asrc_priv. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc.c | 298 +-- sound/soc/fsl

[PATCH v8 2/7] ASoC: dt-bindings: fsl_asrc: Add new property fsl, asrc-format

2020-04-14 Thread Shengjiu Wang
. The fsl,asrc-format can replace the fsl,asrc-width, then driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- Documentation/devicetree/bindings/sound/fsl,asrc.txt | 4 1 file changed, 4

[PATCH v8 0/7] ASoC: Add new module driver for new ASRC

2020-04-14 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX8MN, several commits are added for new property fsl,asrc-format Shengjiu Wang (7): ASoC: fsl_asrc: rename asrc_priv to asrc ASoC: dt-bindings: fsl_asrc: Add new property fsl,asrc-format ASoC: fsl-asoc-card: Support new property fsl,asrc-format

Re: [PATCH v7 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-13 Thread Shengjiu Wang
On Tue, Apr 14, 2020 at 10:09 AM Nicolin Chen wrote: > > On Tue, Apr 14, 2020 at 08:43:07AM +0800, Shengjiu Wang wrote: > > There is a new ASRC included in i.MX serial platform, there > > are some common definition can be shared with each other. > > So move the common

[PATCH v7 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-13 Thread Shengjiu Wang
-by: Shengjiu Wang Signed-off-by: Cosmin-Gabriel Samoila Acked-by: Nicolin Chen --- sound/soc/fsl/Kconfig | 11 + sound/soc/fsl/Makefile|2 + sound/soc/fsl/fsl_easrc.c | 2119 + sound/soc/fsl/fsl_easrc.h | 651 4 files changed, 2783

[PATCH v7 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-13 Thread Shengjiu Wang
. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c| 87 +- sound/soc/fsl/fsl_asrc.h| 74 ++ sound/soc/fsl/fsl_asrc_common.h | 106 sound/soc/fsl/fsl_asrc_dma.c| 25 4 files changed, 183

[PATCH v7 6/7] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-04-13 Thread Shengjiu Wang
EASRC (Enhanced Asynchronous Sample Rate Converter) is a new IP module found on i.MX8MN. Signed-off-by: Shengjiu Wang --- .../devicetree/bindings/sound/fsl,easrc.yaml | 101 ++ 1 file changed, 101 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/fsl

[PATCH v7 4/7] ASoC: fsl_asrc: Support new property fsl,asrc-format

2020-04-13 Thread Shengjiu Wang
In order to align with new ESARC, we add new property fsl,asrc-format. The fsl,asrc-format can replace the fsl,asrc-width, driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 41

[PATCH v7 1/7] ASoC: fsl_asrc: rename asrc_priv to asrc

2020-04-13 Thread Shengjiu Wang
In order to move common structure to fsl_asrc_common.h we change the name of asrc_priv to asrc, the asrc_priv will be used by new struct fsl_asrc_priv. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc.c | 298 +-- sound/soc/fsl

[PATCH v7 3/7] ASoC: fsl-asoc-card: Support new property fsl, asrc-format

2020-04-13 Thread Shengjiu Wang
In order to align with new ESARC, we add new property fsl,asrc-format. The fsl,asrc-format can replace the fsl,asrc-width, driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl-asoc

[PATCH v7 0/7] ASoC: Add new module driver for new ASRC

2020-04-13 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX8MN, several commits are added for new property fsl,asrc-format Shengjiu Wang (7): ASoC: fsl_asrc: rename asrc_priv to asrc ASoC: dt-bindings: fsl_asrc: Add new property fsl,asrc-format ASoC: fsl-asoc-card: Support new property fsl,asrc-format

[PATCH v7 2/7] ASoC: dt-bindings: fsl_asrc: Add new property fsl, asrc-format

2020-04-13 Thread Shengjiu Wang
. The fsl,asrc-format can replace the fsl,asrc-width, then driver can accept format from devicetree, don't need to convert it to format through width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- Documentation/devicetree/bindings/sound/fsl,asrc.txt | 4 1 file changed, 4

Re: [PATCH v6 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-13 Thread Shengjiu Wang
On Mon, Apr 13, 2020 at 12:31 PM Nicolin Chen wrote: > > On Mon, Apr 13, 2020 at 11:16:31AM +0800, Shengjiu Wang wrote: > > On Sun, Apr 12, 2020 at 10:08 AM Nicolin Chen > > wrote: > > > > > > On Sat, Apr 11, 2020 at 01:49:43PM +0800, Shengjiu Wang wrote:

Re: [PATCH v6 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-12 Thread Shengjiu Wang
On Sun, Apr 12, 2020 at 10:08 AM Nicolin Chen wrote: > > On Sat, Apr 11, 2020 at 01:49:43PM +0800, Shengjiu Wang wrote: > > > > > diff --git a/sound/soc/fsl/fsl_asrc_dma.c b/sound/soc/fsl/fsl_asrc_dma.c > > > > index b15946e03380..5cf0468ce6e3 100644 > >

Re: [PATCH v6 5/7] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-04-10 Thread Shengjiu Wang
Hi On Tue, Apr 7, 2020 at 7:50 AM Nicolin Chen wrote: > > On Wed, Apr 01, 2020 at 04:45:38PM +0800, Shengjiu Wang wrote: > > > static int fsl_asrc_probe(struct platform_device *pdev) > > { > > struct device_node *np = pdev->dev.of_node; > > str

[PATCH v6 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-01 Thread Shengjiu Wang
-by: Shengjiu Wang Signed-off-by: Cosmin-Gabriel Samoila --- sound/soc/fsl/Kconfig | 11 + sound/soc/fsl/Makefile|2 + sound/soc/fsl/fsl_easrc.c | 2114 + sound/soc/fsl/fsl_easrc.h | 651 4 files changed, 2778 insertions(+) create mode 100644

<    1   2   3   4   5   6   7   >