From: Krzysztof Kozlowski <krzk@kernel.org>
To: zain_zhou@realsil.com.cn,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
Frank Li <Frank.Li@nxp.com>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>, Lee Jones <lee@kernel.org>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>,
Vikash Bansal <vikash.bansal@nxp.com>,
Aman Kumar Pandey <aman.kumarpandey@nxp.com>,
Lakshay Piplani <lakshay.piplani@nxp.com>
Cc: devicetree@vger.kernel.org, linux-i3c@lists.infradead.org,
linux-kernel@vger.kernel.org, mfd@lists.linux.dev,
Wei Wang <wei_wang@realsil.com.cn>
Subject: Re: [RFC PATCH 3/4] regulator: rts490x: Add driver for on-die regulators
Date: Sun, 20 Sep 2026 15:05:28 +0200 [thread overview]
Message-ID: <58c3ea87-b7df-4c68-b22b-5102c158d5f7@kernel.org> (raw)
In-Reply-To: <20260920100501.4091351-4-zain_zhou@realsil.com.cn>
On 20/09/2026 12:05, zain_zhou@realsil.com.cn wrote:
> +
> + regulators = of_get_available_child_by_name(pdev->dev.of_node, "regulators");
> + if (!regulators)
> + return 0;
> +
> + config.dev = &pdev->dev;
> + config.regmap = rts490x->regmap;
> + config.driver_data = priv;
> +
> + for (i = 0; i < ARRAY_SIZE(rts490x_regulators); i++) {
> + struct device_node *node __free(device_node) = NULL;
> + const char *name = rts490x_regulators[i].of_match;
> +
> + node = of_get_available_child_by_name(regulators, name);
> + if (!node)
> + continue;
> +
> + config.of_node = node;
> + rdev = devm_regulator_register(&pdev->dev, &rts490x_regulators[i],
> + &config);
> + if (IS_ERR(rdev))
You leak OF nodes.
Best regards,
Krzysztof
next prev parent reply other threads:[~2026-09-20 13:05 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-20 10:04 [RFC PATCH 0/4] Add support for Realtek RTS490x I3C hub zain_zhou
2026-09-20 10:04 ` [RFC PATCH 1/4] dt-bindings: i3c: Add Realtek RTS490x I3C hub support zain_zhou
2026-09-20 10:04 ` [RFC PATCH 2/4] mfd: Add driver for Realtek RTS490x I3C hub zain_zhou
2026-09-20 10:05 ` [RFC PATCH 3/4] regulator: rts490x: Add driver for on-die regulators zain_zhou
2026-09-20 13:05 ` Krzysztof Kozlowski [this message]
2026-09-21 3:46 ` 回复: " 周寅
2026-09-21 14:07 ` Krzysztof Kozlowski
2026-09-21 10:23 ` Mark Brown
2026-09-20 10:05 ` [RFC PATCH 4/4] i3c: hub: Add Realtek RTS490x I3C hub support zain_zhou
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=58c3ea87-b7df-4c68-b22b-5102c158d5f7@kernel.org \
--to=krzk@kernel.org \
--cc=Frank.Li@nxp.com \
--cc=alexandre.belloni@bootlin.com \
--cc=aman.kumarpandey@nxp.com \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=lakshay.piplani@nxp.com \
--cc=lee@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-i3c@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mfd@lists.linux.dev \
--cc=robh@kernel.org \
--cc=vikash.bansal@nxp.com \
--cc=wei_wang@realsil.com.cn \
--cc=zain_zhou@realsil.com.cn \
/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
all inboxes | Powered by JetHome®