[PATCH v4 2/2] ASoC: fsl_asrc: Add support for imx8qm & imx8qxp

2019-12-02 Thread Shengjiu Wang
uest, one dma request corresponding to one dma channel. So we need to request dma channel with dma request of asrc module. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- changes in v2 - use !use_edma to wrap code in fsl_asrc_dma - add Acked-by: Nicolin Chen changes in v3 - remove the a

Re: [alsa-devel] [PATCH v4 1/2] ASoC: dt-bindings: fsl_asrc: add compatible string for imx8qm & imx8qxp

2019-12-04 Thread Shengjiu Wang
Hi On Mon, Dec 2, 2019 at 8:58 PM Fabio Estevam wrote: > > On Mon, Dec 2, 2019 at 8:56 AM Shengjiu Wang wrote: > > > - - compatible : Contains "fsl,imx35-asrc" or "fsl,imx53-asrc". > > + - compatible : C

[PATCH v5 1/2] ASoC: dt-bindings: fsl_asrc: add compatible string for imx8qm & imx8qxp

2019-12-04 Thread Shengjiu Wang
Add compatible string "fsl,imx8qm-asrc" for imx8qm platform, "fsl,imx8qxp-asrc" for imx8qxp platform. There are two asrc modules in imx8qm & imx8qxp, the clock mapping is different for each other, so add new property "fsl,asrc-clk-map" to distinguish t

[PATCH v5 2/2] ASoC: fsl_asrc: Add support for imx8qm & imx8qxp

2019-12-04 Thread Shengjiu Wang
uest, one dma request corresponding to one dma channel. So we need to request dma channel with dma request of asrc module. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- changes in v2 - use !use_edma to wrap code in fsl_asrc_dma - add Acked-by: Nicolin Chen changes in v3 - remove the a

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

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-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:

[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 chang

[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 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

[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 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

[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 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 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-13 Thread Shengjiu Wang
: 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

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 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

[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 chang

[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 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

[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/so

[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 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 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-14 Thread Shengjiu Wang
: 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

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 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 ++

[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

[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 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 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/so

[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 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 7/7] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI drivers

2020-04-16 Thread Shengjiu Wang
: 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] 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/soun

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, > > w

[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 ---

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

2020-04-24 Thread Shengjiu Wang
CPU DAI 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

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

2020-04-25 Thread Shengjiu Wang
CPU DAI 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

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

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

2020-04-26 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. > > T

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

2020-04-26 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 - Di

[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 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 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 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

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 > &g

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

[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

[PATCH V2 0/2] recover the channel swap after xrun

2019-07-02 Thread shengjiu . wang
From: Shengjiu Wang recover the channel swap after xrun Shengjiu Wang (2): ASoC: fsl_esai: Wrap some operations to be functions ASoC: fsl_esai: recover the channel swap after xrun sound/soc/fsl/fsl_esai.c | 267 --- 1 file changed, 194 insertions(+), 73

[PATCH V2 1/2] ASoC: fsl_esai: Wrap some operations to be functions

2019-07-02 Thread shengjiu . wang
From: Shengjiu Wang Extract the operation to be functions, to improve the readability. In this patch, fsl_esai_init, fsl_esai_register_restore, fsl_esai_trigger_start and fsl_esai_trigger_stop are extracted. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_esai.c | 191

[PATCH V2 2/2] ASoC: fsl_esai: recover the channel swap after xrun

2019-07-02 Thread shengjiu . wang
From: Shengjiu Wang There is chip errata ERR008000, the reference doc is (https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf), The issue is "While using ESAI transmit or receive and an underrun/overrun happens, channel swap may occur. The only recovery mechanism is to reset the ESAI."

[PATCH V3 0/2] recover the channel swap after xrun

2019-07-07 Thread shengjiu . wang
From: Shengjiu Wang recover the channel swap after xrun Shengjiu Wang (2): ASoC: fsl_esai: Wrap some operations to be functions ASoC: fsl_esai: recover the channel swap after xrun sound/soc/fsl/fsl_esai.c | 270 --- 1 file changed, 197 insertions(+), 73

[PATCH V3 1/2] ASoC: fsl_esai: Wrap some operations to be functions

2019-07-07 Thread shengjiu . wang
From: Shengjiu Wang Extract the operation to be functions, to improve the readability. In this patch, fsl_esai_hw_init, fsl_esai_register_restore, fsl_esai_trigger_start and fsl_esai_trigger_stop are extracted. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_esai.c

[PATCH V3 2/2] ASoC: fsl_esai: recover the channel swap after xrun

2019-07-07 Thread shengjiu . wang
From: Shengjiu Wang There is chip errata ERR008000, the reference doc is (https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf), The issue is "While using ESAI transmit or receive and an underrun/overrun happens, channel swap may occur. The only recovery mechanism is to reset the ESAI."

[PATCH V4 0/2] recover the channel swap after xrun

2019-07-11 Thread shengjiu . wang
From: Shengjiu Wang recover the channel swap after xrun Shengjiu Wang (2): ASoC: fsl_esai: Wrap some operations to be functions ASoC: fsl_esai: recover the channel swap after xrun sound/soc/fsl/fsl_esai.c | 266 --- 1 file changed, 193 insertions(+), 73

[PATCH V4 2/2] ASoC: fsl_esai: recover the channel swap after xrun

2019-07-11 Thread shengjiu . wang
From: Shengjiu Wang There is chip errata ERR008000, the reference doc is (https://www.nxp.com/docs/en/errata/IMX6DQCE.pdf), The issue is "While using ESAI transmit or receive and an underrun/overrun happens, channel swap may occur. The only recovery mechanism is to reset the ESAI."

[PATCH V4 1/2] ASoC: fsl_esai: Wrap some operations to be functions

2019-07-11 Thread shengjiu . wang
From: Shengjiu Wang Extract the operation to be functions, to improve the readability. In this patch, fsl_esai_hw_init, fsl_esai_register_restore, fsl_esai_trigger_start and fsl_esai_trigger_stop are extracted. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_esai.c

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

2019-08-09 Thread Shengjiu Wang
Add new compatible string "fsl,imx6ull-esai" in the binding document. Signed-off-by: Shengjiu Wang --- Documentation/devicetree/bindings/sound/fsl,esai.txt | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/fsl,e

[PATCH 1/2] ASoC: fsl_esai: Add compatible string for imx6ull

2019-08-09 Thread Shengjiu Wang
Add compatible string for imx6ull, from imx6ull platform, the issue of channel swap after xrun is fixed in hardware. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_esai.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/soc/fsl/fsl_esai.c b/sound/soc/fsl/fsl_esai.c index

[PATCH] ASoC: imx-audmux: Add driver suspend and resume to support MEGA Fast

2019-08-15 Thread Shengjiu Wang
For i.MX6 SoloX, there is a mode of the SoC to shutdown all power source of modules during system suspend and resume procedure. Thus, AUDMUX needs to save all the values of registers before the system suspend and restore them after the system resume. Signed-off-by: Shengjiu Wang --- sound/soc

Re: [alsa-devel] [PATCH V6 3/4] ASoC: pcm_dmaengine: Extract snd_dmaengine_pcm_refine_runtime_hwparams

2020-01-16 Thread Shengjiu Wang
Hi On Thu, Jan 16, 2020 at 1:56 PM John Stultz wrote: > > On Wed, Jan 8, 2020 at 8:58 PM John Stultz wrote: > > On Thu, Sep 26, 2019 at 6:50 PM Shengjiu Wang wrote: > > > > > > When set the runtime hardware parameters, we may need to query > > > the capab

[PATCH 1/3] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-02-11 Thread Shengjiu Wang
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 definition to a separate header file. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.h| 11 +-- sound/soc/fsl/fsl_asrc_common.h | 21

[PATCH 0/3] Add new module driver for new ASRC

2020-02-11 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX815/865 Shengjiu Wang (3): ASoC: fsl_asrc: Move common definition to fsl_asrc_common ASoC: dt-bindings: fsl_easrc: Add document for EASRC ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers .../devicetree/bindings/sound/fsl,easrc.txt

[PATCH 2/3] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

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

[PATCH 3/3] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers

2020-02-11 Thread Shengjiu Wang
: Shengjiu Wang --- sound/soc/fsl/fsl_asrc_common.h |1 + sound/soc/fsl/fsl_easrc.c | 2265 +++ sound/soc/fsl/fsl_easrc.h | 668 + sound/soc/fsl/fsl_easrc_dma.c | 440 ++ 4 files changed, 3374 insertions(+) create mode 100644 sound/soc/fsl

Re: [alsa-devel] [PATCH 0/3] Add new module driver for new ASRC

2020-02-11 Thread Shengjiu Wang
On Wed, Feb 12, 2020 at 1:13 PM Randy Dunlap wrote: > > On 2/11/20 8:30 PM, Shengjiu Wang wrote: > > Add new module driver for new ASRC in i.MX815/865 > > > > Shengjiu Wang (3): > > ASoC: fsl_asrc: Move common definition to fsl_asrc_common > > ASoC: dt-b

Re: [alsa-devel] [PATCH 2/3] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-02-12 Thread Shengjiu Wang
Hi On Thu, Feb 13, 2020 at 1:26 AM Fabio Estevam wrote: > > On Wed, Feb 12, 2020 at 1:35 AM Shengjiu Wang wrote: > > > > EASRC (Enhanced Asynchronous Sample Rate Converter) is a new > > IP module found on i.MX815. > > i.MX815 in an internal terminology. Please av

[PATCH v2 1/3] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-02-17 Thread Shengjiu Wang
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 definition to a separate header file. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.h| 11 +-- sound/soc/fsl/fsl_asrc_common.h | 21

[PATCH v2 0/3] Add new module driver for new ASRC

2020-02-17 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX8MN. Shengjiu Wang (3): ASoC: fsl_asrc: Move common definition to fsl_asrc_common ASoC: dt-bindings: fsl_easrc: Add document for EASRC ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers changes in v2 - change i.MX815 to i.MX8MN - Add

[PATCH v2 2/3] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-02-17 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.txt | 57 +++ 1 file changed, 57 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/fsl

[PATCH v2 3/3] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers

2020-02-17 Thread Shengjiu Wang
: Shengjiu Wang --- sound/soc/fsl/Kconfig | 10 + sound/soc/fsl/Makefile |2 + sound/soc/fsl/fsl_asrc_common.h |1 + sound/soc/fsl/fsl_easrc.c | 2265 +++ sound/soc/fsl/fsl_easrc.h | 668 + sound/soc/fsl/fsl_easrc_dma.c

Re: [PATCH v2 3/3] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers

2020-02-25 Thread Shengjiu Wang
On Tue, Feb 25, 2020 at 4:05 PM Nicolin Chen wrote: > > On Mon, Feb 24, 2020 at 08:53:25AM +, S.j. Wang wrote: > > Hi > > > > > > > > > > Signed-off-by: Shengjiu Wang > > > > --- > > > > sound/soc/fsl/Kconfig

Re: [PATCH v2 2/3] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-02-26 Thread Shengjiu Wang
Hi On Thu, Feb 20, 2020 at 4:38 AM Rob Herring wrote: > > On Tue, Feb 18, 2020 at 02:39:36PM +0800, Shengjiu Wang wrote: > > EASRC (Enhanced Asynchronous Sample Rate Converter) is a new > > IP module found on i.MX8MN. > > > > Signed-off-by: Shengjiu Wang > &

[PATCH v3 0/4] ASoC: Add new module driver for new ASRC

2020-02-26 Thread Shengjiu Wang
Add new module driver for new ASRC in i.MX8MN Shengjiu Wang (4): ASoC: fsl_asrc: Change asrc_width to asrc_format ASoC: fsl_asrc: Move common definition to fsl_asrc_common ASoC: dt-bindings: fsl_easrc: Add document for EASRC ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers

[PATCH v3 3/4] ASoC: dt-bindings: fsl_easrc: Add document for EASRC

2020-02-26 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 | 96 +++ 1 file changed, 96 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/fsl

[PATCH v3 1/4] ASoC: fsl_asrc: Change asrc_width to asrc_format

2020-02-26 Thread Shengjiu Wang
asrc_format is more inteligent variable, which is align with the alsa definition snd_pcm_format_t. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 23 +++ sound/soc/fsl/fsl_asrc.h | 4 ++-- sound/soc/fsl/fsl_asrc_dma.c | 2 +- 3 files changed, 14

[PATCH v3 2/4] ASoC: fsl_asrc: Move common definition to fsl_asrc_common

2020-02-26 Thread Shengjiu Wang
internally. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c| 81 +++- sound/soc/fsl/fsl_asrc.h| 74 ++ sound/soc/fsl/fsl_asrc_common.h | 105 sound/soc/fsl/fsl_asrc_dma.c| 25 4 files changed

[PATCH v3 4/4] ASoC: fsl_easrc: Add EASRC ASoC CPU DAI and platform drivers

2020-02-26 Thread Shengjiu Wang
: Shengjiu Wang Signed-off-by: Cosmin-Gabriel Samoila --- 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 insertions(+) create mode 100644

Re: [PATCH v3 1/4] ASoC: fsl_asrc: Change asrc_width to asrc_format

2020-02-26 Thread Shengjiu Wang
On Thu, Feb 27, 2020 at 11:43 AM Nicolin Chen wrote: > > On Thu, Feb 27, 2020 at 10:41:55AM +0800, Shengjiu Wang wrote: > > asrc_format is more inteligent variable, which is align > > with the alsa definition snd_pcm_format_t. > > > > Signed-off-by: Shengjiu Wa

[PATCH] ASoC: imx-audmix: register the card on a proper dev

2019-08-26 Thread Shengjiu Wang
Mixer machine driver") Signed-off-by: Viorel Suman Signed-off-by: Shengjiu Wang --- sound/soc/fsl/imx-audmix.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/imx-audmix.c b/sound/soc/fsl/imx-audmix.c index 9e1cb18859ce..71590ca6394b 100644 --- a/sound/soc/fs

[PATCH] ASoC: fsl_ssi: Fix clock control issue in master mode

2019-08-27 Thread Shengjiu Wang
ables the clock. This patch is to move the clock enablement to the place before checking of the device enablement in hw_param(). Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_ssi.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/sound/soc/fsl/fsl_ssi.

[PATCH 2/3] ASoC: fsl_asrc: update supported sample format

2019-09-09 Thread Shengjiu Wang
The ASRC support 24bit/16bit/8bit input width, so S20_3LE format should not be supported, it is word width is 20bit. So replace S20_3LE with S24_3LE in supported list and add S8 format in TX supported list Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 5 +++-- 1 file changed, 3

[PATCH 0/3] update supported sample format

2019-09-09 Thread Shengjiu Wang
update supported sample format Shengjiu Wang (3): ASoC: fsl_asrc: Use in(out)put_format instead of in(out)put_word_width ASoC: fsl_asrc: update supported sample format ASoC: fsl_asrc: Fix error with S24_3LE format bitstream in i.MX8 sound/soc/fsl/fsl_asrc.c | 65

[PATCH 3/3] ASoC: fsl_asrc: Fix error with S24_3LE format bitstream in i.MX8

2019-09-09 Thread Shengjiu Wang
of dma, then update the hw parameters according to the caps. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 4 +- sound/soc/fsl/fsl_asrc.h | 3 ++ sound/soc/fsl/fsl_asrc_dma.c | 93 +--- 3 files changed, 92 insertions(+), 8 deletions(-) di

[PATCH 1/3] ASoC: fsl_asrc: Use in(out)put_format instead of in(out)put_word_width

2019-09-09 Thread Shengjiu Wang
snd_pcm_format_t is more formal than enum asrc_word_width, which has two property, width and physical width, which is more accurate than enum asrc_word_width. So it is better to use in(out)put_format instead of in(out)put_word_width. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c

[PATCH 1/2] ASoC: fsl_mqs: add DT binding documentation

2019-09-10 Thread Shengjiu Wang
Add the DT binding documentation for NXP MQS driver Signed-off-by: Shengjiu Wang --- .../devicetree/bindings/sound/fsl,mqs.txt | 20 +++ 1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/fsl,mqs.txt diff --git a/Documentation

[PATCH 2/2] ASoC: fsl_mqs: Add MQS component driver

2019-09-10 Thread Shengjiu Wang
provides only simple audio reproduction. No internal pop, click or distortion artifact reduction methods are provided. The MQS receives the audio data from the SAI1 Tx section. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/Kconfig | 10 ++ sound/soc/fsl/Makefile | 2 + sound/soc/fsl/fsl_mqs.c

[PATCH V2 1/2] ASoC: fsl_mqs: add DT binding documentation

2019-09-13 Thread Shengjiu Wang
Add the DT binding documentation for NXP MQS driver Signed-off-by: Shengjiu Wang --- Changes in v2 -refine the comments for properties .../devicetree/bindings/sound/fsl,mqs.txt | 36 +++ 1 file changed, 36 insertions(+) create mode 100644 Documentation/devicetree/bindings

[PATCH V2 2/2] ASoC: fsl_mqs: Add MQS component driver

2019-09-13 Thread Shengjiu Wang
provides only simple audio reproduction. No internal pop, click or distortion artifact reduction methods are provided. The MQS receives the audio data from the SAI1 Tx section. Signed-off-by: Shengjiu Wang --- Changes in v2 - use devm_platform_ioremap_resource sound/soc/fsl/Kconfig | 10

[PATCH V2 0/4] update supported sample format

2019-09-17 Thread Shengjiu Wang
This patch serial is to update the supported format for fsl_asrc and fix some format issue. Shengjiu Wang (4): ASoC: fsl_asrc: Use in(out)put_format instead of in(out)put_word_width ASoC: fsl_asrc: update supported sample format ASoC: pcm_dmaengine: Extract

[PATCH V2 2/4] ASoC: fsl_asrc: update supported sample format

2019-09-17 Thread Shengjiu Wang
with S24_3LE in supported list and add S8 format in TX supported list Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_asrc.c b/sound/soc/fsl/fsl_asrc.c index 4d3804a1ea55..584badf956d2 100644

[PATCH V2 1/4] ASoC: fsl_asrc: Use in(out)put_format instead of in(out)put_word_width

2019-09-17 Thread Shengjiu Wang
snd_pcm_format_t is more formal than enum asrc_word_width, which has two property, width and physical width, which is more accurate than enum asrc_word_width. So it is better to use in(out)put_format instead of in(out)put_word_width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen

[PATCH V2 3/4] ASoC: pcm_dmaengine: Extract snd_dmaengine_pcm_set_runtime_hwparams

2019-09-17 Thread Shengjiu Wang
this feature can call this function. Signed-off-by: Shengjiu Wang --- include/sound/dmaengine_pcm.h | 5 ++ sound/core/pcm_dmaengine.c| 83 +++ sound/soc/soc-generic-dmaengine-pcm.c | 62 ++-- 3 files changed, 92 insertions(+), 58

[PATCH V2 4/4] ASoC: fsl_asrc: Fix error with S24_3LE format bitstream in i.MX8

2019-09-18 Thread Shengjiu Wang
of dma, then update the hw parameters according to the caps. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 4 +-- sound/soc/fsl/fsl_asrc.h | 3 +++ sound/soc/fsl/fsl_asrc_dma.c | 48 ++-- 3 files changed, 46 insertions(+), 9 deletions(-) di

[PATCH V3 2/4] ASoC: fsl_asrc: update supported sample format

2019-09-19 Thread Shengjiu Wang
with S24_3LE in supported list and add S8 format in TX supported list Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_asrc.c b/sound/soc/fsl/fsl_asrc.c index 4d3804a1ea55..584badf956d2 100644

[PATCH V3 4/4] ASoC: fsl_asrc: Fix error with S24_3LE format bitstream in i.MX8

2019-09-19 Thread Shengjiu Wang
of dma, then update the hw parameters according to the caps. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.c | 4 +-- sound/soc/fsl/fsl_asrc.h | 3 +++ sound/soc/fsl/fsl_asrc_dma.c | 52 +++- 3 files changed, 50 insertions(+), 9 deletions(-) di

[PATCH V3 0/4] update supported sample format

2019-09-19 Thread Shengjiu Wang
This patch serial is to update the supported format for fsl_asrc and fix some format issue. Shengjiu Wang (4): ASoC: fsl_asrc: Use in(out)put_format instead of in(out)put_word_width ASoC: fsl_asrc: update supported sample format ASoC: pcm_dmaengine: Extract

[PATCH V3 1/4] ASoC: fsl_asrc: Use in(out)put_format instead of in(out)put_word_width

2019-09-19 Thread Shengjiu Wang
snd_pcm_format_t is more formal than enum asrc_word_width, which has two property, width and physical width, which is more accurate than enum asrc_word_width. So it is better to use in(out)put_format instead of in(out)put_word_width. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen

[PATCH V3 3/4] ASoC: pcm_dmaengine: Extract snd_dmaengine_pcm_refine_runtime_hwparams

2019-09-19 Thread Shengjiu Wang
need this feature can call this function. Signed-off-by: Shengjiu Wang --- include/sound/dmaengine_pcm.h | 5 ++ sound/core/pcm_dmaengine.c| 83 +++ sound/soc/soc-generic-dmaengine-pcm.c | 62 +++- 3 files changed, 95 insertions(+), 55

[PATCH V4 2/4] ASoC: fsl_asrc: update supported sample format

2019-09-24 Thread Shengjiu Wang
with S24_3LE in supported list and add S8 format in TX supported list Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_asrc.c b/sound/soc/fsl/fsl_asrc.c index 4d3804a1ea55

<    1   2   3   4   5   6   7   8   >