From: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
To: Mubin Sayyed <mubin.sayyed@amd.com>
Cc: robh+dt@kernel.org, treding@nvidia.com,
linux-pwm@vger.kernel.org, devicetree@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, git@amd.com, michal.simek@amd.com,
siva.durga.prasad.paladugu@amd.com, mubin10@gmail.com
Subject: Re: [LINUX PATCH 1/3] clocksource: timer-cadence-ttc: Do not probe TTC device configured as PWM
Date: Thu, 12 Jan 2023 22:30:15 +0100 [thread overview]
Message-ID: <20230112213015.sw5uxirsrltx3pih@pengutronix.de> (raw)
In-Reply-To: <20230112071526.3035949-2-mubin.sayyed@amd.com>
[-- Attachment #1: Type: text/plain, Size: 1375 bytes --]
On Thu, Jan 12, 2023 at 12:45:24PM +0530, Mubin Sayyed wrote:
> TTC device can act either as clocksource/clockevent or
> PWM generator, it would be decided by pwm-cells property.
> TTC PWM feature would be supported through separate driver
> based on PWM framework.
>
> If pwm-cells property is present in TTC node, it would be
> treated as PWM device, and clocksource driver should just
> skip it.
>
> Signed-off-by: Mubin Sayyed <mubin.sayyed@amd.com>
> ---
> drivers/clocksource/timer-cadence-ttc.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/drivers/clocksource/timer-cadence-ttc.c b/drivers/clocksource/timer-cadence-ttc.c
> index 4efd0cf3b602..ba46649148b1 100644
> --- a/drivers/clocksource/timer-cadence-ttc.c
> +++ b/drivers/clocksource/timer-cadence-ttc.c
> @@ -476,6 +476,9 @@ static int __init ttc_timer_probe(struct platform_device *pdev)
> u32 timer_width = 16;
> struct device_node *timer = pdev->dev.of_node;
>
While it's more obvious here than in the PWM driver, a comment here
would be good, too.
> + if (of_property_read_bool(timer, "#pwm-cells"))
> + return -ENODEV;
> +
> if (initialized)
> return 0;
>
> --
> 2.25.1
>
>
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2023-01-12 21:38 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-12 7:15 [LINUX PATCH 0/3] Add initial support for TTC PWM driver Mubin Sayyed
2023-01-12 7:15 ` [LINUX PATCH 1/3] clocksource: timer-cadence-ttc: Do not probe TTC device configured as PWM Mubin Sayyed
2023-01-12 21:30 ` Uwe Kleine-König [this message]
2023-01-12 7:15 ` [LINUX PATCH 2/3] dt-bindings: timer: Update device tree bindings for cadence TTC PWM Mubin Sayyed
2023-01-12 10:10 ` Krzysztof Kozlowski
2023-01-12 7:15 ` [LINUX PATCH 3/3] pwm: pwm-cadence: Add support for " Mubin Sayyed
2023-01-12 17:57 ` kernel test robot
2023-01-12 21:25 ` Uwe Kleine-König
2023-01-17 9:58 ` Sayyed, Mubin
2023-01-17 11:27 ` Uwe Kleine-König
2023-01-17 12:55 ` Sayyed, Mubin
2023-01-17 14:05 ` Uwe Kleine-König
2023-01-13 8:13 ` Krzysztof Kozlowski
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=20230112213015.sw5uxirsrltx3pih@pengutronix.de \
--to=u.kleine-koenig@pengutronix.de \
--cc=devicetree@vger.kernel.org \
--cc=git@amd.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pwm@vger.kernel.org \
--cc=michal.simek@amd.com \
--cc=mubin.sayyed@amd.com \
--cc=mubin10@gmail.com \
--cc=robh+dt@kernel.org \
--cc=siva.durga.prasad.paladugu@amd.com \
--cc=treding@nvidia.com \
/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;
as well as URLs for NNTP newsgroup(s).