[rtems-libbsd commit] linux/percpu.h: Fix for uni-processor config

Sebastian Huber sebh at rtems.org
Mon Feb 5 10:55:52 UTC 2018


Module:    rtems-libbsd
Branch:    master
Commit:    0f9258f2fb7d927bb8b6ab3417a56552204a2b28
Changeset: http://git.rtems.org/rtems-libbsd/commit/?id=0f9258f2fb7d927bb8b6ab3417a56552204a2b28

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Wed Nov 29 15:26:17 2017 +0100

linux/percpu.h: Fix for uni-processor config

---

 rtemsbsd/powerpc/include/linux/percpu.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/rtemsbsd/powerpc/include/linux/percpu.h b/rtemsbsd/powerpc/include/linux/percpu.h
index 5a189bc..6f5ef26 100644
--- a/rtemsbsd/powerpc/include/linux/percpu.h
+++ b/rtemsbsd/powerpc/include/linux/percpu.h
@@ -30,6 +30,7 @@
 #include <linux/cpumask.h>
 #include <linux/threads.h>
 
+#include <rtems/score/smp.h>
 #include <rtems/score/threaddispatch.h>
 
 #ifdef __cplusplus
@@ -43,7 +44,7 @@ extern "C" {
     (_designator[_cpu])
 
 #define this_cpu_ptr(_designator) \
-    (&_designator[_CPU_SMP_Get_current_processor()])
+    (&_designator[_SMP_Get_current_processor()])
 
 #define get_cpu_var(_designator) \
     (*({ Per_CPU_Control *_cpu_self = _Thread_Dispatch_disable(); \
@@ -56,7 +57,7 @@ extern "C" {
     ((_ptr) + (_index))
 
 #define	raw_cpu_ptr(_ptr) \
-    per_cpu_ptr(_ptr, _CPU_SMP_Get_current_processor())
+    per_cpu_ptr(_ptr, _SMP_Get_current_processor())
 
 #ifdef __cplusplus
 }




More information about the vc mailing list