From 09abedc98781b1c1201fd9f3b9c97ff83fcdf65b Mon Sep 17 00:00:00 2001 From: bernie Date: Mon, 25 Aug 2008 19:24:43 +0000 Subject: [PATCH] proc_switch(): rename from proc_schedule(). Split out the real cooperative scheduler. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@1702 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/kern/preempt.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bertos/kern/preempt.c b/bertos/kern/preempt.c index e24da145..a9201f61 100644 --- a/bertos/kern/preempt.c +++ b/bertos/kern/preempt.c @@ -101,7 +101,7 @@ void proc_preempt(UNUSED_ARG(void *, param) TRACEMSG("preempting %p:%s", CurrentProcess, proc_currentName()); -// FIXME: this still break havocs, probably because of some reentrancy issue +// FIXME: this still breaks havoc, probably because of some reentrancy issue #if 0 SCHED_ENQUEUE(CurrentProcess); proc_schedule(); @@ -127,7 +127,7 @@ void proc_switch(void) IRQ_ASSERT_ENABLED(); ASSERT(preempt_forbid_cnt == 0); - // Will invoke proc_preempt() in interrupt context + // Will invoke proc_switch() in interrupt context kill(0, SIGUSR1); } @@ -153,7 +153,7 @@ void preempt_init(void) MOD_CHECK(irq); MOD_CHECK(timer); - irq_register(SIGUSR1, proc_preempt); + irq_register(SIGUSR1, proc_schedule); timer_setSoftint(&preempt_timer, proc_preempt_timer, NULL); timer_setDelay(&preempt_timer, CONFIG_KERN_QUANTUM); -- 2.25.1