File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1919#include <asm-generic/irq.h>
2020
2121extern void arc_init_IRQ (void );
22- void arc_local_timer_setup (unsigned int cpu );
22+ void arc_local_timer_setup (void );
2323
2424#endif
Original file line number Diff line number Diff line change @@ -138,7 +138,7 @@ void start_kernel_secondary(void)
138138 if (machine_desc -> init_smp )
139139 machine_desc -> init_smp (smp_processor_id ());
140140
141- arc_local_timer_setup (cpu );
141+ arc_local_timer_setup ();
142142
143143 local_irq_enable ();
144144 preempt_disable ();
Original file line number Diff line number Diff line change @@ -219,12 +219,13 @@ static struct irqaction arc_timer_irq = {
219219/*
220220 * Setup the local event timer for @cpu
221221 */
222- void arc_local_timer_setup (unsigned int cpu )
222+ void arc_local_timer_setup ()
223223{
224- struct clock_event_device * clk = & per_cpu (arc_clockevent_device , cpu );
224+ struct clock_event_device * evt = this_cpu_ptr (& arc_clockevent_device );
225+ int cpu = smp_processor_id ();
225226
226- clk -> cpumask = cpumask_of (cpu );
227- clockevents_config_and_register (clk , arc_get_core_freq (),
227+ evt -> cpumask = cpumask_of (cpu );
228+ clockevents_config_and_register (evt , arc_get_core_freq (),
228229 0 , ARC_TIMER_MAX );
229230
230231 /*
@@ -261,7 +262,7 @@ void __init time_init(void)
261262 clocksource_register_hz (& arc_counter , arc_get_core_freq ());
262263
263264 /* sets up the periodic event timer */
264- arc_local_timer_setup (smp_processor_id () );
265+ arc_local_timer_setup ();
265266
266267 if (machine_desc -> init_time )
267268 machine_desc -> init_time ();
You can’t perform that action at this time.
0 commit comments