aboutsummaryrefslogtreecommitdiffstats
path: root/arch/hexagon
diff options
context:
space:
mode:
Diffstat (limited to 'arch/hexagon')
-rw-r--r--arch/hexagon/Kconfig1
-rw-r--r--arch/hexagon/kernel/process.c23
-rw-r--r--arch/hexagon/kernel/smp.c2
3 files changed, 5 insertions, 21 deletions
diff --git a/arch/hexagon/Kconfig b/arch/hexagon/Kconfig
index e4decc6b8947..6e3710e84a6c 100644
--- a/arch/hexagon/Kconfig
+++ b/arch/hexagon/Kconfig
@@ -24,6 +24,7 @@ config HEXAGON
24 select NO_IOPORT 24 select NO_IOPORT
25 select GENERIC_IOMAP 25 select GENERIC_IOMAP
26 select GENERIC_SMP_IDLE_THREAD 26 select GENERIC_SMP_IDLE_THREAD
27 select GENERIC_IDLE_LOOP
27 select STACKTRACE_SUPPORT 28 select STACKTRACE_SUPPORT
28 select KTIME_SCALAR 29 select KTIME_SCALAR
29 select GENERIC_CLOCKEVENTS 30 select GENERIC_CLOCKEVENTS
diff --git a/arch/hexagon/kernel/process.c b/arch/hexagon/kernel/process.c
index 06ae9ffcabd5..9b948c619a03 100644
--- a/arch/hexagon/kernel/process.c
+++ b/arch/hexagon/kernel/process.c
@@ -51,28 +51,11 @@ void start_thread(struct pt_regs *regs, unsigned long pc, unsigned long sp)
51 * If hardware or VM offer wait termination even though interrupts 51 * If hardware or VM offer wait termination even though interrupts
52 * are disabled. 52 * are disabled.
53 */ 53 */
54static void default_idle(void) 54void arch_cpu_idle(void)
55{ 55{
56 __vmwait(); 56 __vmwait();
57} 57 /* interrupts wake us up, but irqs are still disabled */
58 58 local_irq_enable();
59void (*idle_sleep)(void) = default_idle;
60
61void cpu_idle(void)
62{
63 while (1) {
64 tick_nohz_idle_enter();
65 local_irq_disable();
66 while (!need_resched()) {
67 idle_sleep();
68 /* interrupts wake us up, but aren't serviced */
69 local_irq_enable(); /* service interrupt */
70 local_irq_disable();
71 }
72 local_irq_enable();
73 tick_nohz_idle_exit();
74 schedule();
75 }
76} 59}
77 60
78/* 61/*
diff --git a/arch/hexagon/kernel/smp.c b/arch/hexagon/kernel/smp.c
index 8e095dffd070..0e364ca43198 100644
--- a/arch/hexagon/kernel/smp.c
+++ b/arch/hexagon/kernel/smp.c
@@ -184,7 +184,7 @@ void __cpuinit start_secondary(void)
184 184
185 local_irq_enable(); 185 local_irq_enable();
186 186
187 cpu_idle(); 187 cpu_startup_entry(CPUHP_ONLINE);
188} 188}
189 189
190 190