lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20221028082750.991822-4-chancel.liu@nxp.com>
Date:   Fri, 28 Oct 2022 16:27:50 +0800
From:   Chancel Liu <chancel.liu@....com>
To:     lgirdwood@...il.com, broonie@...nel.org, perex@...ex.cz,
        tiwai@...e.com, alsa-devel@...a-project.org,
        linux-kernel@...r.kernel.org, robh+dt@...nel.org,
        devicetree@...r.kernel.org, krzysztof.kozlowski+dt@...aro.org,
        shengjiu.wang@...il.com, Xiubo.Lee@...il.com, festevam@...il.com,
        nicoleotsuka@...il.com, linuxppc-dev@...ts.ozlabs.org
Cc:     Chancel Liu <chancel.liu@....com>
Subject: [PATCH 3/3] ASoC: fsl_micfil: Add support when using eDMA

On i.MX93 platform MICFIL uses eDMA. The maxburst should be set to the
number of channels in eDMA multiple FIFO mode.

Signed-off-by: Chancel Liu <chancel.liu@....com>
---
 sound/soc/fsl/fsl_micfil.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/sound/soc/fsl/fsl_micfil.c b/sound/soc/fsl/fsl_micfil.c
index b8a9504441df..22e75c14cac4 100644
--- a/sound/soc/fsl/fsl_micfil.c
+++ b/sound/soc/fsl/fsl_micfil.c
@@ -63,6 +63,7 @@ struct fsl_micfil_soc_data {
 	unsigned int fifo_depth;
 	unsigned int dataline;
 	bool imx;
+	bool use_edma;
 	u64  formats;
 };
 
@@ -88,6 +89,7 @@ static struct fsl_micfil_soc_data fsl_micfil_imx93 = {
 	.fifo_depth = 32,
 	.dataline =  0xf,
 	.formats = SNDRV_PCM_FMTBIT_S32_LE,
+	.use_edma = true,
 };
 
 static const struct of_device_id fsl_micfil_dt_ids[] = {
@@ -690,6 +692,8 @@ static int fsl_micfil_hw_params(struct snd_pcm_substream *substream,
 	micfil->sdmacfg.n_fifos_src = channels;
 	micfil->sdmacfg.sw_done = true;
 	micfil->dma_params_rx.maxburst = channels * MICFIL_DMA_MAXBURST_RX;
+	if (micfil->soc->use_edma)
+		micfil->dma_params_rx.maxburst = channels;
 
 	return 0;
 }
-- 
2.25.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ