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] [day] [month] [year] [list]
Message-ID: <20240923091410.GA120879@francesco-nb>
Date: Mon, 23 Sep 2024 11:14:10 +0200
From: Francesco Dolcini <francesco@...cini.it>
To: Jai Luthra <jai.luthra@...ux.dev>
Cc: Peter Ujfalusi <peter.ujfalusi@...il.com>,
	Vinod Koul <vkoul@...nel.org>,
	Vignesh Raghavendra <vigneshr@...com>,
	Francesco Dolcini <francesco.dolcini@...adex.com>,
	Devarsh Thakkar <devarsht@...com>,
	Rishikesh Donadkar <r-donadkar@...com>, dmaengine@...r.kernel.org,
	linux-kernel@...r.kernel.org, Jai Luthra <j-luthra@...com>
Subject: Re: [PATCH] dmaengine: ti: k3-udma: Fix teardown for cyclic PDMA
 transfers

Hello Jai,

On Wed, Sep 18, 2024 at 06:46:55PM +0530, Jai Luthra wrote:
> From: Jai Luthra <j-luthra@...com>
> 
> When receiving data in cyclic mode from PDMA peripherals, where reload
> count is set to infinite, any TR in the set can potentially be the last
> one of the overall transfer. In such cases, the EOP flag needs to be set
> in each TR and PDMA's Static TR "Z" parameter should be set, matching
> the size of the TR.
> 
> This is required for the teardown to function properly and cleanup the
> internal state memory. This only affects platforms using BCDMA and not
> those using UDMA-P, which could set EOP flag in the teardown TR
> automatically.
> 
> Similarly when transmitting data in cyclic mode to PDMA peripherals, the
> EOP flag needs to be set to get the teardown completion signal
> correctly.
> 
> Fixes: 017794739702 ("dmaengine: ti: k3-udma: Initial support for K3 BCDMA")
> Signed-off-by: Jai Luthra <j-luthra@...com>
> Signed-off-by: Jai Luthra <jai.luthra@...ux.dev>

Thanks for this, really appreciated!

I did test this patch on top of v6.11, before I had errors every
time I was doing some recording, (e.g. `arecord -D hw:0,0 -c 2 -f S16_LE
-r 44100 -t wav -d 16 /tmp/a.wav`)

[   63.906602] ti-udma 485c0100.dma-controller: chan2 teardown timeout!
[   64.090472] davinci-mcasp 2b00000.audio-controller: Receive buffer overflow
[   65.409909] ti-udma 485c0100.dma-controller: chan2 teardown timeout!

In addition to that I used to have system crashes afterward, but today
it seems that this is not happening with v6.11.

I think that this should go explicitly to stable, so I would add
Cc:stable in your v2 (that I assume you need to send to address some
review comment from Péter).

With all of that said

Tested-by: Francesco Dolcini <francesco.dolcini@...adex.com # Toradex Verdin AM62

Francesco


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ