[PATCH 3/4] ASoC: xlnx: formatter: set a 64-bit DMA mask

Dhanunjanrao, Katta katta.dhanunjanrao at amd.com
Thu Nov 26 22:26:36 PST 2026


AMD General

Hi Mark,

Thank you for the review.
I will address the review comments and send an updated version.

Thanks,
Dhanunjay

-----Original Message-----
From: Mark Brown <broonie at kernel.org>
Sent: Thursday, November 26, 2026 11:22 PM
To: Dhanunjanrao, Katta <katta.dhanunjanrao at amd.com>
Cc: Mark Brown <broonie at kernel.org>; Liam Girdwood <lgirdwood at gmail.com>; Vincenzo Frascino <vincenzo.frascino at arm.com>; Rob Herring <robh at kernel.org>; Krzysztof Kozlowski <krzk+dt at kernel.org>; Conor Dooley <conor+dt at kernel.org>; Jaroslav Kysela <perex at perex.cz>; Takashi Iwai <tiwai at suse.com>; Simek, Michal <michal.simek at amd.com>; linux-sound at vger.kernel.org; devicetree at vger.kernel.org; linux-arm-kernel at lists.infradead.org; linux-kernel at vger.kernel.org; Gaddipati, Naveen <naveen.gaddipati at amd.com>
Subject: Re: [PATCH 3/4] ASoC: xlnx: formatter: set a 64-bit DMA mask

> hw_params splits the ring buffer address over the LSB and MSB buffer
> address registers, but the device is left on the default 32-bit mask.
> The coherent buffer therefore always comes from below 4G and the MSB
> register is only ever written as zero.
>
> Set a 64-bit mask so the buffer can sit in high memory as well.
>
> Signed-off-by: Dhanunjanrao Katta <katta.dhanunjanrao at amd.com>
> ---
>  sound/soc/xilinx/xlnx_formatter_pcm.c | 6 ++++++
>  1 file changed, 6 insertions(+)
>
> diff --git a/sound/soc/xilinx/xlnx_formatter_pcm.c
> b/sound/soc/xilinx/xlnx_formatter_pcm.c
> index fa7419439ec7..57901c9466a0 100644
> --- a/sound/soc/xilinx/xlnx_formatter_pcm.c
> +++ b/sound/soc/xilinx/xlnx_formatter_pcm.c
> @@ -8,6 +8,7 @@
>
>  #include <linux/bitfield.h>
>  #include <linux/clk.h>
> +#include <linux/dma-mapping.h>
>  #include <linux/io.h>
>  #include <linux/module.h>
>  #include <linux/sizes.h>
> @@ -598,6 +599,11 @@ static int xlnx_formatter_pcm_probe(struct platform_device *pdev)
>       struct device *dev = &pdev->dev;
>       struct clk *axi_clk, *aud_mclk, *axis_clk;
>
> +     ret = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64));

Is this always safe, can we have instances restricted to 32 bits?
Yes, some instances/platforms can be limited to 32-bit DMA addressing. I’ll check the addressing capability of the Audio Formatter and make sure we don’t unconditionally assume 64-bit DMA support.

--
Mark Brown <broonie at kernel.org>


More information about the linux-arm-kernel mailing list