Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Jelly Jia" <Jelly.Jia@cixtech.com>
Cc: conor+dt@kernel.org, vkoul@kernel.org, dmaengine@vger.kernel.org,
	robh@kernel.org, Frank.Li@kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v3 5/6] dmaengine: arm-dma350: Support integration clocks, resets and reserved memory
Date: Mon, 12 Oct 2026 08:51:18 +0000	[thread overview]
Message-ID: <sashiko-outbox-167868@kernel.org> (raw)
In-Reply-To: <20261012084155.2547480-6-Jelly.Jia@cixtech.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] dmaengine: probe fails on level-based reset controllers due to -ENOTSUPP
--

commit 9e76b19e390586bfc4ec916b67c4dd6c3a4800c5
Author: Jelly Jia <Jelly.Jia@cixtech.com>

dmaengine: arm-dma350: Support integration clocks, resets and reserved memory

This commit adds support for integrating the arm-dma350 controller with
clocks, resets, and reserved memory regions using the device tree. It enables
the clock, triggers the reset control, and attaches the reserved memory
before registering the DMA device.

> diff --git a/drivers/dma/arm-dma350.c b/drivers/dma/arm-dma350.c
> index 79bd6a04ea0c5..d811a0dc9fe9e 100644
> --- a/drivers/dma/arm-dma350.c
> +++ b/drivers/dma/arm-dma350.c

[ ... ]

> @@ -1139,12 +1142,28 @@ static void d350_free_chan_resources(struct dma_chan *chan)
>  static int d350_probe(struct platform_device *pdev)
>  {
>  	struct device *dev = &pdev->dev;
> +	struct reset_control *reset;
> +	struct clk *clk;
>  	struct d350 *dmac;
>  	void __iomem *base;
>  	u32 reg;
>  	int ret, nchan, dw, aw, r, p;
>  	bool coherent, memset;
>  
> +	clk = devm_clk_get_optional_enabled(dev, NULL);
> +	if (IS_ERR(clk))
> +		return dev_err_probe(dev, PTR_ERR(clk),
> +				     "failed to enable clock\n");
> +
> +	reset = devm_reset_control_get_optional_exclusive(dev, NULL);
> +	if (IS_ERR(reset))
> +		return dev_err_probe(dev, PTR_ERR(reset),
> +				     "failed to get reset\n");
> +
> +	ret = reset_control_reset(reset);
> +	if (ret)
> +		return ret;

[Severity: High]
Is it intentional to fail the probe if the reset controller does not support
pulse-based resets?

If the underlying reset controller (such as reset-simple without a pulse
configuration) only supports level-based assert and deassert semantics,
reset_control_reset() will return -ENOTSUPP. Because the probe function
aborts on any error here, it will fatally fail to bind on those platforms.

The commit message states the intent is to release the reset, which usually
corresponds to reset_control_deassert(). Could this use
reset_control_deassert() instead, or is there a way to handle the -ENOTSUPP
error gracefully so the probe can succeed?

[ ... ]

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261012084155.2547480-1-Jelly.Jia@cixtech.com?part=5

  reply	other threads:[~2026-10-12  8:51 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-12  8:41 [PATCH v3 0/6] dmaengine: arm-dma350: Add slave support and CIX Sky1 integration Jelly Jia
2026-10-12  8:41 ` [PATCH v3 1/6] dmaengine: arm-dma350: Fix source trigger bit Jelly Jia
2026-10-12 15:09   ` Frank Li
2026-10-12  8:41 ` [PATCH v3 2/6] dmaengine: arm-dma350: Add slave and cyclic transfer support Jelly Jia
2026-10-12  8:52   ` sashiko-bot
2026-10-12 15:10     ` Frank Li
2026-10-12  8:41 ` [PATCH v3 3/6] dmaengine: arm-dma350: Sync the slave command list before starting Jelly Jia
2026-10-12  8:41 ` [PATCH v3 4/6] dt-bindings: dma: arm,dma-350: Document the CIX Sky1 integration Jelly Jia
2026-10-12 19:06   ` Conor Dooley
2026-10-12  8:41 ` [PATCH v3 5/6] dmaengine: arm-dma350: Support integration clocks, resets and reserved memory Jelly Jia
2026-10-12  8:51   ` sashiko-bot [this message]
2026-10-12  8:41 ` [PATCH v3 6/6] arm64: dts: cix: Describe the Sky1 DMA-350 bus integration Jelly Jia
2026-10-12  8:52   ` sashiko-bot
2026-10-12 19:07   ` Conor Dooley

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=sashiko-outbox-167868@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=Frank.Li@kernel.org \
    --cc=Jelly.Jia@cixtech.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dmaengine@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    --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