[PATCH V3 3/5] ARM: bcm2708: add system timer
Arnd Bergmann
arnd at arndb.de
Wed Sep 12 06:40:32 EDT 2012
On Wednesday 12 September 2012, Stephen Warren wrote:
> From: Simon Arlott <simon at fire.lp0.eu>
>
> The System Timer peripheral provides four 32-bit timer channels and a
> single 64-bit free running counter. Each channel has an output compare
> register, which is compared against the 32 least significant bits of the
> free running counter values, and generates an interrupt.
>
> Timer 3 is used as the Linux timer.
>
> The BCM2708 also contains an SP804-based timer module. However, it
> apparently has significant differences from the standard SP804 IP block,
> and Broadcom's documentation recommends using the system timer instead.
>
> This patch was extracted from git://github.com/lp0/linux.git branch
> rpi-split as of 2012/09/08, and modified as follows:
>
> * Moved struct sys_timer bcm2708_timer into time.c to encapsulate it more.
> * Added DT binding docs.
> * Moved to drivers/clocksource/. This looks like the desired location for
> such code now.
> * Simplified bcm2708_time_init() to find one matching node and operate on
> it, rather than looping over all matching nodes. This seems more
> consistent with other clocksource code.
> * Renamed struct bcm2708_timer.index to match_mask to better represent its
> purpose.
> * s/printk(PR_INFO/pr_info(/
>
> Signed-off-by: Chris Boot <bootc at bootc.net>
> Signed-off-by: Simon Arlott <simon at fire.lp0.eu>
> Signed-off-by: Dom Cobley <popcornmix at gmail.com>
> Signed-off-by: Dom Cobley <dc4 at broadcom.com>
> Signed-off-by: Stephen Warren <swarren at wwwdotorg.org>
Acked-by: Arnd Bergmann <arnd at arndb.de>
Looks good to me, but I think the use of of_iomap() would be a good
simplification of the init function.
Arnd
More information about the linux-rpi-kernel
mailing list