Re: [PATCH] spi: dw: Fix missing smp_mb() in dw_spi_exec_mem_op
From: Mark Brown
Date: Tue Oct 13 2026 - 18:10:18 EST
On Sat, Oct 10, 2026 at 11:15:29PM +0800, Jisheng Zhang wrote:
> Similar as commit bfda044533b2 ("spi: dw: use "smp_mb()" to avoid
> sending spi data error"), we also need the smp_mb() in
> dw_spi_exec_mem_op() after setting up the members in "dws" to ensure
> the data change is visible for all CPUs.
Which other CPUs are we worried about here? Unlike the regular SPI path
which can use DMA and interrupts for the exec_op() stuff we only do PIO
and have interrupts masked during the actual transfer. If the task
migrates I'd expect that to have all the required barriers, but
otherwise it all looks single threaded.
Attachment:
signature.asc
Description: PGP signature