OSDN Git Service

fix arch_cpu_idle
authorYoshinori Sato <ysato@users.sourceforge.jp>
Sun, 13 Jan 2019 14:01:13 +0000 (23:01 +0900)
committerYoshinori Sato <yo-satoh@sios.com>
Sat, 29 Jan 2022 07:36:42 +0000 (16:36 +0900)
arch/rx/kernel/process.c
kernel/sched/Makefile

index 0be56cc..5169309 100644 (file)
 void (*pm_power_off)(void) = NULL;
 EXPORT_SYMBOL(pm_power_off);
 
-/*
- * The idle thread. There's no useful work to be
- * done, so just try to conserve power and have a
- * low exit latency (ie sit in a loop waiting for
- * somebody to say that they'd like to reschedule)
- */
-void cpu_idle(void)
+void arch_cpu_idle(void)
 {
-       while (1) {
-               while (!need_resched())
-                       __asm__ volatile("wait");
-               preempt_enable_no_resched();
-               schedule();
-               preempt_disable();
-       }
+       local_irq_enable();
+       __asm__ volatile("wait");
 }
 
 void __noreturn machine_restart(char * __unused)
index c7421f2..4e0ecaf 100644 (file)
@@ -41,3 +41,7 @@ obj-$(CONFIG_MEMBARRIER) += membarrier.o
 obj-$(CONFIG_CPU_ISOLATION) += isolation.o
 obj-$(CONFIG_PSI) += psi.o
 obj-$(CONFIG_SCHED_CORE) += core_sched.o
+ifeq ($(CONFIG_RX),y)
+# workaround for gcc bug69073
+CFLAGS_REMOVE_core.o = -g
+endif