linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mark Rutland <mark.rutland@arm.com>
To: linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 01/02] ARM: shmobile: force enable of r8a7790 arch timer
Date: Tue, 09 Apr 2013 09:27:11 +0000	[thread overview]
Message-ID: <20130409092711.GT23725@e106331-lin.cambridge.arm.com> (raw)
In-Reply-To: <20130408012328.13555.44487.sendpatchset@w520>

Adding Stephen Boyd and Marc Zyngier to Cc as they're both familiar with the
architected timer.

On Mon, Apr 08, 2013 at 02:23:28AM +0100, Magnus Damm wrote:
> From: Magnus Damm <damm@opensource.se>
> 
> Implement a SoC-specific timer init function for
> r8a7790 that makes sure the architected timer
> is started regardless of boot loader setting.
> 
> Signed-off-by: Magnus Damm <damm@opensource.se>
> ---
> 
>  arch/arm/mach-shmobile/include/mach/r8a7790.h |    1 +
>  arch/arm/mach-shmobile/setup-r8a7790.c        |   14 +++++++++++++-
>  2 files changed, 14 insertions(+), 1 deletion(-)
> 
> --- 0001/arch/arm/mach-shmobile/include/mach/r8a7790.h
> +++ work/arch/arm/mach-shmobile/include/mach/r8a7790.h	2013-04-08 10:13:38.000000000 +0900
> @@ -4,5 +4,6 @@
>  void r8a7790_add_standard_devices(void);
>  void r8a7790_clock_init(void);
>  void r8a7790_pinmux_init(void);
> +void r8a7790_timer_init(void);
>  
>  #endif /* __ASM_R8A7790_H__ */
> --- 0001/arch/arm/mach-shmobile/setup-r8a7790.c
> +++ work/arch/arm/mach-shmobile/setup-r8a7790.c	2013-04-08 10:13:38.000000000 +0900
> @@ -117,6 +117,18 @@ void __init r8a7790_add_standard_devices
>  	r8a7790_register_irqc(0);
>  }
>  
> +void __init r8a7790_timer_init(void)
> +{
> +	void __iomem *cntcr;
> +
> +	/* make sure arch timer is started by setting bit 0 of CNTCT */

Typo: CNTCT should be CNTCR above.

> +	cntcr = ioremap(0xe6080000, PAGE_SIZE);
> +	iowrite32(1, cntcr);
> +	iounmap(cntcr);
> +
> +	shmobile_timer_init();
> +}

Does this mean you have memory-mapped timers and CP15 timers linked together?

Why do your firmware and bootloader not set this up?

Mark.

  reply	other threads:[~2013-04-09  9:27 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-08  1:23 [PATCH 00/02] ARM: shmobile: r8a7790 Lager arch timer fixes Magnus Damm
2013-04-08  1:23 ` [PATCH 01/02] ARM: shmobile: force enable of r8a7790 arch timer Magnus Damm
2013-04-09  9:27   ` Mark Rutland [this message]
2013-04-08  1:23 ` [PATCH 02/02] ARM: shmobile: use r8a7790 timer setup code on Lager Magnus Damm
2013-04-08  1:29 ` [PATCH 00/02] ARM: shmobile: r8a7790 Lager arch timer fixes Kuninori Morimoto
2013-04-08  2:06   ` Simon Horman
2013-04-08  2:35     ` Kuninori Morimoto
2013-04-08  3:32       ` Simon Horman
2013-04-09 12:42   ` Simon Horman
2013-04-08  1:33 ` Simon Horman

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=20130409092711.GT23725@e106331-lin.cambridge.arm.com \
    --to=mark.rutland@arm.com \
    --cc=linux-arm-kernel@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).