projects
/
bertos.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use generic include.
[bertos.git]
/
bertos
/
cpu
/
power.h
diff --git
a/bertos/cpu/power.h
b/bertos/cpu/power.h
index b4550ad6d0b4ba64f8d5b05dfca8113d65799670..4e88def111bf414471cdd43adb66aefb76b5d958 100644
(file)
--- a/
bertos/cpu/power.h
+++ b/
bertos/cpu/power.h
@@
-37,8
+37,10
@@
#ifndef CPU_POWER_H
#define CPU_POWER_H
#ifndef CPU_POWER_H
#define CPU_POWER_H
-#include <cfg/cfg_kern.h>
-#include <cfg/cfg_wdt.h>
+#include "cfg/cfg_proc.h"
+#include "cfg/cfg_wdt.h"
+
+#include <cfg/compiler.h>
#if CONFIG_KERN
#include <kern/proc.h>
#if CONFIG_KERN
#include <kern/proc.h>
@@
-67,7
+69,8
@@
INLINE void cpu_relax(void)
{
#if CONFIG_KERN
INLINE void cpu_relax(void)
{
#if CONFIG_KERN
- proc_yield();
+ if (proc_preemptAllowed())
+ proc_yield();
#endif
#if CONFIG_WATCHDOG
#endif
#if CONFIG_WATCHDOG