Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ee348d5a authored by Russell King's avatar Russell King Committed by Russell King
Browse files

[ARM] realview: fix broadcast tick support



Having discussed broadcast tick support with Thomas Glexiner, the
broadcast tick devices should be registered with a higher rating
than the global tick device, and it should have the ONESHOT and
PERIODIC feature flags set.

Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
Acked-by: default avatarThomas Glexiner <tglx@linutronix.de>
parent 78d236c2
Loading
Loading
Loading
Loading
+0 −8
Original line number Original line Diff line number Diff line
@@ -750,14 +750,6 @@ void __init realview_timer_init(unsigned int timer_irq)
{
{
	u32 val;
	u32 val;


#ifdef CONFIG_GENERIC_CLOCKEVENTS_BROADCAST
	/*
	 * The dummy clock device has to be registered before the main device
	 * so that the latter will broadcast the clock events
	 */
	local_timer_setup();
#endif

	/* 
	/* 
	 * set clock frequency: 
	 * set clock frequency: 
	 *	REALVIEW_REFCLK is 32KHz
	 *	REALVIEW_REFCLK is 32KHz
+4 −2
Original line number Original line Diff line number Diff line
@@ -189,8 +189,10 @@ void __cpuinit local_timer_setup(void)
	struct clock_event_device *clk = &per_cpu(local_clockevent, cpu);
	struct clock_event_device *clk = &per_cpu(local_clockevent, cpu);


	clk->name		= "dummy_timer";
	clk->name		= "dummy_timer";
	clk->features		= CLOCK_EVT_FEAT_DUMMY;
	clk->features		= CLOCK_EVT_FEAT_ONESHOT |
	clk->rating		= 200;
				  CLOCK_EVT_FEAT_PERIODIC |
				  CLOCK_EVT_FEAT_DUMMY;
	clk->rating		= 400;
	clk->mult               = 1;
	clk->mult               = 1;
	clk->set_mode		= dummy_timer_set_mode;
	clk->set_mode		= dummy_timer_set_mode;
	clk->broadcast		= smp_timer_broadcast;
	clk->broadcast		= smp_timer_broadcast;
+2 −4
Original line number Original line Diff line number Diff line
@@ -217,11 +217,9 @@ void __init smp_prepare_cpus(unsigned int max_cpus)
	if (max_cpus > ncores)
	if (max_cpus > ncores)
		max_cpus = ncores;
		max_cpus = ncores;


#ifdef CONFIG_LOCAL_TIMERS
#if defined(CONFIG_LOCAL_TIMERS) || defined(CONFIG_GENERIC_CLOCKEVENTS_BROADCAST)
	/*
	/*
	 * Enable the local timer for primary CPU. If the device is
	 * Enable the local timer or broadcast device for the boot CPU.
	 * dummy (!CONFIG_LOCAL_TIMERS), it was already registers in
	 * realview_timer_init
	 */
	 */
	local_timer_setup();
	local_timer_setup();
#endif
#endif