Skip to content

Commit

Permalink
clocksource: nomadik-mtu: fix up clocksource/timer
Browse files Browse the repository at this point in the history
The Nomadik clocksource driver has had a bad define making it
impossible to use it for sched_clock() for a while. Fix this
and also enable it for the Nomadik.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Olof Johansson <olof@lixom.net>
  • Loading branch information
Linus Walleij authored and Olof Johansson committed Apr 27, 2013
1 parent 772ba2f commit ea7113f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions arch/arm/mach-nomadik/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ config ARCH_NOMADIK
select ARM_AMBA
select ARM_VIC
select CLKSRC_NOMADIK_MTU
select CLKSRC_NOMADIK_MTU_SCHED_CLOCK
select COMMON_CLK
select CPU_ARM926T
select GENERIC_CLOCKEVENTS
Expand Down
4 changes: 2 additions & 2 deletions drivers/clocksource/nomadik-mtu.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ static u32 clk_prescale;
static u32 nmdk_cycle; /* write-once */
static struct delay_timer mtu_delay_timer;

#ifdef CONFIG_NOMADIK_MTU_SCHED_CLOCK
#ifdef CONFIG_CLKSRC_NOMADIK_MTU_SCHED_CLOCK
/*
* Override the global weak sched_clock symbol with this
* local implementation which uses the clocksource to get some
Expand Down Expand Up @@ -233,7 +233,7 @@ void __init nmdk_timer_init(void __iomem *base, int irq)
pr_err("timer: failed to initialize clock source %s\n",
"mtu_0");

#ifdef CONFIG_NOMADIK_MTU_SCHED_CLOCK
#ifdef CONFIG_CLKSRC_NOMADIK_MTU_SCHED_CLOCK
setup_sched_clock(nomadik_read_sched_clock, 32, rate);
#endif

Expand Down

0 comments on commit ea7113f

Please sign in to comment.