From: "Uwe Kleine-König" <ukleinek@kernel.org>
To: Yixun Lan <dlan@kernel.org>
Cc: "Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"Duje Mihanović" <duje@dujemihanovic.xyz>,
linux-pwm@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org,
spacemit@lists.linux.dev
Subject: Re: [PATCH 2/2] pwm: pxa: Add optional bus clock
Date: Tue, 14 Apr 2026 10:51:50 +0200 [thread overview]
Message-ID: <ad3_t19jQ4P5NqSK@monoceros> (raw)
In-Reply-To: <20260414060453-GKA203300@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 793 bytes --]
Hello,
On Tue, Apr 14, 2026 at 06:04:53AM +0000, Yixun Lan wrote:
> On 10:38 Mon 13 Apr , Uwe Kleine-König wrote:
> > On Thu, Apr 09, 2026 at 12:45:12AM +0000, Yixun Lan wrote:
> > > + /* Get named func clk if bus clock is valid */
> > > + pc->clk = devm_clk_get(dev, pc->bus_clk ? "func" : NULL);
> >
> > I'm not sure, but I think passing "func" unconditionally to
> > devm_clk_get() would also work fine.
> Passing "func" unconditionally, will break old compatibles(not k3-pwm), as only
> one clocks property is provided, but no clock-names property
I thought that if there is a single clock without a name,
clk_get(dev, "somename") will return that one. But looking at the code,
that assumption is wrong. So keeping the conditional here is fine.
Best regards
Uwe
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
prev parent reply other threads:[~2026-04-14 8:51 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-09 0:45 [PATCH 0/2] pwm: spacemit: Add Support for K3 SoC Yixun Lan
2026-04-09 0:45 ` [PATCH 1/2] dt-bindings: pwm: marvell,pxa-pwm: Add SpacemiT K3 PWM support Yixun Lan
2026-04-09 15:41 ` Conor Dooley
2026-04-09 23:43 ` Yixun Lan
2026-04-09 0:45 ` [PATCH 2/2] pwm: pxa: Add optional bus clock Yixun Lan
2026-04-13 8:38 ` Uwe Kleine-König
2026-04-14 6:04 ` Yixun Lan
2026-04-14 8:51 ` Uwe Kleine-König [this message]
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=ad3_t19jQ4P5NqSK@monoceros \
--to=ukleinek@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlan@kernel.org \
--cc=duje@dujemihanovic.xyz \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pwm@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=robh@kernel.org \
--cc=spacemit@lists.linux.dev \
/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