DMA Engine development
 help / color / mirror / Atom feed
From: Frank Li <Frank.li@oss.nxp.com>
To: Tian Xuechen <202300460064@mail.sdu.edu.cn>
Cc: vkoul@kernel.org, Frank.Li@kernel.org, dmaengine@vger.kernel.org,
	vireshk@kernel.org, andriy.shevchenko@linux.intel.com,
	ilpo.jarvinen@linux.intel.com, miquel.raynal@bootlin.com
Subject: Re: [PATCH v3 4/7] dmaengine: dw: dmamux: Use managed DMA router registration
Date: Fri, 4 Dec 2026 11:55:26 -0600	[thread overview]
Message-ID: <axL-joS_lMuMXrU4@SMW015318> (raw)
In-Reply-To: <20261204121630.1720746-5-202300460064@mail.sdu.edu.cn>

On Fri, Dec 04, 2026 at 08:16:27PM +0800, Tian Xuechen wrote:
> The RZ/N1 DMAMUX leaves its router in the OF DMA registry when the
> device is detached. The router data is then released by devres.
>
> Register the router with devm_of_dma_router_register() so that its
> registry entry is removed before the managed router data is released.
>
> Fixes: 134d9c52fca2 ("dmaengine: dw: dmamux: Introduce RZN1 DMA router support")
> Cc: stable+noautosel@kernel.org # relies on new API
> Signed-off-by: Tian Xuechen <202300460064@mail.sdu.edu.cn>

Reviewed-by: Frank Li <Frank.Li@nxp.com>

> ---
>  drivers/dma/dw/rzn1-dmamux.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/dma/dw/rzn1-dmamux.c b/drivers/dma/dw/rzn1-dmamux.c
> index fb495ee6e..4fed7f40b 100644
> --- a/drivers/dma/dw/rzn1-dmamux.c
> +++ b/drivers/dma/dw/rzn1-dmamux.c
> @@ -145,8 +145,9 @@ static int rzn1_dmamux_probe(struct platform_device *pdev)
>
>  	platform_set_drvdata(pdev, dmamux);
>
> -	return of_dma_router_register(mux_node, rzn1_dmamux_route_allocate,
> -				      &dmamux->dmarouter);
> +	return devm_of_dma_router_register(&pdev->dev, mux_node,
> +					   rzn1_dmamux_route_allocate,
> +					   &dmamux->dmarouter);
>  }
>
>  static const struct of_device_id rzn1_dmamux_match[] = {

  reply	other threads:[~2026-12-04 17:55 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-04 12:16 [PATCH v3 0/7] dmaengine: Manage OF DMA routers and disable STM32 unbind Tian Xuechen
2026-12-04 12:16 ` [PATCH v3 1/7] dmaengine: of: Add managed DMA router registration Tian Xuechen
2026-12-04 17:54   ` Frank Li
2026-12-04 12:16 ` [PATCH v3 2/7] dmaengine: lpc18xx-dmamux: Use " Tian Xuechen
2026-12-04 12:16 ` [PATCH v3 3/7] dmaengine: lpc32xx-dmamux: " Tian Xuechen
2026-12-04 12:16 ` [PATCH v3 4/7] dmaengine: dw: dmamux: " Tian Xuechen
2026-12-04 17:55   ` Frank Li [this message]
2026-12-04 12:16 ` [PATCH v3 5/7] dmaengine: stm32: Disable manual bind and unbind Tian Xuechen
2026-12-04 17:56   ` Frank Li
2026-12-04 12:16 ` [PATCH v3 6/7] dmaengine: stm32-dmamux: Use managed DMA router registration Tian Xuechen
2026-12-04 17:57   ` Frank Li
2026-12-04 12:16 ` [PATCH v3 7/7] dmaengine: ti-dma-crossbar: " Tian Xuechen
2026-12-04 17:57   ` Frank Li

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=axL-joS_lMuMXrU4@SMW015318 \
    --to=frank.li@oss.nxp.com \
    --cc=202300460064@mail.sdu.edu.cn \
    --cc=Frank.Li@kernel.org \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=ilpo.jarvinen@linux.intel.com \
    --cc=miquel.raynal@bootlin.com \
    --cc=vireshk@kernel.org \
    --cc=vkoul@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox