devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
To: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: olof@lixom.net, arnd@arndb.de, robh+dt@kernel.org,
	tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
	amit.kucheria@linaro.org, linus.walleij@linaro.org,
	zhao_steven@263.net, service@rdamicro.com,
	"Andreas Färber" <afaerber@suse.de>
Subject: Re: [PATCH 12/16] clocksource: Add clock driver for RDA8810PL SoC
Date: Tue, 20 Nov 2018 17:41:39 +0530	[thread overview]
Message-ID: <20181120121139.GB13485@mani> (raw)
In-Reply-To: <0df98ec5-1189-7297-b58d-8c0f5cbfa2ac@linaro.org>

Hi Daniel,

On Tue, Nov 20, 2018 at 11:32:52AM +0100, Daniel Lezcano wrote:
> 
> Hi Manivannan,
> 
> 
> On 19/11/2018 18:09, Manivannan Sadhasivam wrote:
> > Add clock driver for RDA Micro RDA8810PL SoC supporting OSTIMER
> > and HWTIMER.
> 
> As it is a new driver, can you elaborate the log and describe the timer.
>

Sure, will add the brief in commit description and also in driver.
 
> > Signed-off-by: Andreas Färber <afaerber@suse.de>
> > Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> > ---
> 
> [ ... ]
> 
> > +static int __init rda_timer_init(struct device_node *node)
> > +{
> > +	unsigned long rate = 2000000;
> > +	int ostimer_irq, ret;
> > +
> > +	rda_timer_base = of_io_request_and_map(node, 0, "rda-timer");
> > +	if (IS_ERR(rda_timer_base)) {
> > +		pr_err("Can't map timer registers");
> > +		return PTR_ERR(rda_timer_base);
> > +	}
> > +
> > +	ostimer_irq = of_irq_get_byname(node, "ostimer");
> > +	if (ostimer_irq <= 0) {
> > +		pr_err("Can't parse ostimer IRQ");
> > +		return -EINVAL;
> > +	}
> > +
> > +	clocksource_register_hz(&rda_clocksource, rate);
> > +
> > +	ret = request_irq(ostimer_irq, rda_ostimer_interrupt, IRQF_TIMER,
> > +			  "rda-ostimer", &rda_clockevent);
> > +	if (ret) {
> > +		pr_err("failed to request irq %d\n", ostimer_irq);
> > +		return ret;
> > +	}
> > +
> 
> Use the timer-of API.
> 

Okay, will use it for both IO and IRQ requests.

Thanks,
Mani

> > +
> > +TIMER_OF_DECLARE(rda8810pl, "rda,8810pl-timer", rda_timer_init);
> 
> 
> Thanks
> 
>   -- Daniel
> 
> 
> -- 
>  <http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs
> 
> Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
> <http://twitter.com/#!/linaroorg> Twitter |
> <http://www.linaro.org/linaro-blog/> Blog
> 

  reply	other threads:[~2018-11-20 12:11 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-19 17:09 [PATCH 00/16] Add initial RDA8810PL SoC and Orange Pi boards support Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 01/16] dt-bindings: Add RDA Micro vendor prefix Manivannan Sadhasivam
2018-11-19 17:22   ` Andreas Färber
2018-11-19 17:29     ` Manivannan Sadhasivam
2018-11-20  2:51       ` Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 02/16] dt-bindings: arm: Document RDA8810PL and reference boards Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 03/16] ARM: Prepare RDA8810PL SoC Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 04/16] arm: dts: Add devicetree for " Manivannan Sadhasivam
2018-11-19 18:25   ` Rob Herring
2018-11-20 19:31     ` Manivannan Sadhasivam
2018-11-19 19:37   ` Arnd Bergmann
2018-11-20 19:32     ` Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 05/16] arm: dts: Add devicetree for OrangePi 2G IoT board Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 06/16] arm: dts: Add devicetree for OrangePi i96 board Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 07/16] dt-bindings: interrupt-controller: Document RDA8810PL intc Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 08/16] arm: dts: rda8810pl: Add interrupt controller support Manivannan Sadhasivam
2018-11-19 18:29   ` Rob Herring
2018-11-20 19:28     ` Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 09/16] irqchip: Add RDA8810PL interrupt driver Manivannan Sadhasivam
2018-11-19 17:36   ` Marc Zyngier
2018-11-20  3:19     ` Manivannan Sadhasivam
2018-11-20  8:10       ` Marc Zyngier
2018-11-19 17:09 ` [PATCH 10/16] dt-bindings: timer: Document RDA8810PL SoC timer Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 11/16] arm: dts: rda8810pl: Add timer support Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 12/16] clocksource: Add clock driver for RDA8810PL SoC Manivannan Sadhasivam
2018-11-19 17:57   ` Marc Zyngier
2018-11-20  5:06     ` Manivannan Sadhasivam
2018-11-20  8:16       ` Marc Zyngier
2018-11-20  8:56         ` Linus Walleij
2018-11-20 11:05           ` Marc Zyngier
2018-11-20 12:09             ` Manivannan Sadhasivam
2018-11-20 10:32   ` Daniel Lezcano
2018-11-20 12:11     ` Manivannan Sadhasivam [this message]
2018-11-19 17:09 ` [PATCH 13/16] dt-bindings: serial: Document RDA Micro UART Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 14/16] arm: dts: rda8810pl: Add interrupt support for UART Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 15/16] tty: serial: Add RDA8810PL UART driver Manivannan Sadhasivam
2018-11-19 17:09 ` [PATCH 16/16] MAINTAINERS: Add entry for RDA Micro SoC architecture Manivannan Sadhasivam

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=20181120121139.GB13485@mani \
    --to=manivannan.sadhasivam@linaro.org \
    --cc=afaerber@suse.de \
    --cc=amit.kucheria@linaro.org \
    --cc=arnd@arndb.de \
    --cc=daniel.lezcano@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jason@lakedaemon.net \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marc.zyngier@arm.com \
    --cc=olof@lixom.net \
    --cc=robh+dt@kernel.org \
    --cc=service@rdamicro.com \
    --cc=tglx@linutronix.de \
    --cc=zhao_steven@263.net \
    /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).