Re: [PATCH 1/1] mmc: use dmaengine_desc_set_callback()

From: Adrian Hunter

Date: Wed Nov 04 2026 - 06:57:37 EST


On 02/11/2026 19:21, Frank.Li@xxxxxxxxxxx wrote:
> From: Frank Li <Frank.Li@xxxxxxx>
>
> Replace open-coded assignments to callback and callback_param fields
> of struct dma_async_tx_descriptor with calls to the
> dmaengine_desc_set_callback() helper across MMC host drivers.
>
> No functional change intended. Prepare make to struct
> dma_async_tx_descriptor private to the DMA engine.
>
> Signed-off-by: Frank Li <Frank.Li@xxxxxxx>
> ---
> drivers/mmc/host/atmel-mci.c | 3 +--
> drivers/mmc/host/bcm2835.c | 3 +--
> drivers/mmc/host/dw_mmc.c | 3 +--
> drivers/mmc/host/moxart-mmc.c | 3 +--
> drivers/mmc/host/mxcmmc.c | 3 +--
> drivers/mmc/host/mxs-mmc.c | 3 +--
> drivers/mmc/host/omap.c | 3 +--
> drivers/mmc/host/omap_hsmmc.c | 3 +--
> drivers/mmc/host/owl-mmc.c | 3 +--
> drivers/mmc/host/pxamci.c | 3 +--
> drivers/mmc/host/renesas_sdhi_sys_dmac.c | 6 ++----
> drivers/mmc/host/sdhci.c | 3 +--
> drivers/mmc/host/sh_mmcif.c | 6 ++----
> drivers/mmc/host/uniphier-sd.c | 3 +--
> drivers/mmc/host/usdhi6rol0.c | 3 +--
> 15 files changed, 17 insertions(+), 34 deletions(-)
>

[ ... ]

> diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
> index efb4c7742fe21..18aca84834fb6 100644
> --- a/drivers/mmc/host/sdhci.c
> +++ b/drivers/mmc/host/sdhci.c
> @@ -1298,8 +1298,7 @@ static int sdhci_external_dma_setup(struct sdhci_host *host,
> if (!desc)
> return -EINVAL;
>
> - desc->callback = NULL;
> - desc->callback_param = NULL;
> + dmaengine_desc_set_callback(desc, NULL, NULL, NULL);
>
> cookie = dmaengine_submit(desc);
> if (dma_submit_error(cookie))

For sdhci:

Acked-by: Adrian Hunter <adrian.hunter@xxxxxxxxx>