[PATCH 1/3] mtd: rawnand: fsmc: declare NAND_USES_DMA

Ping Li leeonion.muyu at gmail.com
Sun Nov 22 23:04:15 PST 2026


From: leeonion.muyu at gmail.com

Hi,

Thanks for the review.  I verified the three findings and they
all check out:

- fsmc: indeed, nothing has set host->mode since the platform
  data removal (a1b1e1d5bdfe), so the DMA paths are dead code
  and fsmc_exec_op() always takes the PIO branch.  I am dropping
  this patch; declaring NAND_USES_DMA there would only add an
  unnecessary full-page bounce for every vmalloc'd buffer.

- intel: the unmap problems in ebu_dma_start() are real, thanks
  for catching them.  I will include a fix in v2: unmap on the
  success path as well, return directly when the mapping itself
  fails, and unmap with the device the buffer was mapped with.

- The Fixes: tags were indeed wrong: mtdblock's vmalloc'ed write
  cache and UBIFS LPT buffers reach mtd_write() long before the
  mtdchar ioctls did, so the exposure goes back to each driver's
  introduction.  v2 will point the tags at 0b1039f016e8a (intel)
  and 67e054e919248 (r852).

I will send a v2 with the fsmc patch dropped, the Fixes: tags
corrected and the ebu_dma_start() fix added.

Thanks,
Ping



More information about the linux-mtd mailing list