From 197a614209beb9359e127151c219722f56054677 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 5 Jul 2017 15:14:26 +0200 Subject: score: Add scheduler node to set affinity op Update #3059. --- cpukit/score/include/rtems/score/scheduler.h | 3 +++ cpukit/score/include/rtems/score/schedulerimpl.h | 2 ++ cpukit/score/include/rtems/score/schedulerpriorityaffinitysmp.h | 1 + 3 files changed, 6 insertions(+) (limited to 'cpukit/score/include/rtems') diff --git a/cpukit/score/include/rtems/score/scheduler.h b/cpukit/score/include/rtems/score/scheduler.h index 5f3fb01206..a2a72b037c 100644 --- a/cpukit/score/include/rtems/score/scheduler.h +++ b/cpukit/score/include/rtems/score/scheduler.h @@ -207,6 +207,7 @@ typedef struct { bool ( *set_affinity )( const Scheduler_Control *, Thread_Control *, + Scheduler_Node *, const Processor_mask * ); #endif @@ -510,6 +511,7 @@ void _Scheduler_default_Start_idle( * * @param[in] scheduler The scheduler instance. * @param[in] thread The associated thread. + * @param[in] node The home scheduler node of the associated thread. * @param[in] affinity The new processor affinity set for the thread. * * @retval true The processor set of the scheduler is a subset of the affinity set. @@ -518,6 +520,7 @@ void _Scheduler_default_Start_idle( bool _Scheduler_default_Set_affinity( const Scheduler_Control *scheduler, Thread_Control *thread, + Scheduler_Node *node, const Processor_mask *affinity ); diff --git a/cpukit/score/include/rtems/score/schedulerimpl.h b/cpukit/score/include/rtems/score/schedulerimpl.h index 49aaf029e1..cb9fd7e841 100644 --- a/cpukit/score/include/rtems/score/schedulerimpl.h +++ b/cpukit/score/include/rtems/score/schedulerimpl.h @@ -609,11 +609,13 @@ bool _Scheduler_Get_affinity( RTEMS_INLINE_ROUTINE bool _Scheduler_default_Set_affinity_body( const Scheduler_Control *scheduler, Thread_Control *the_thread, + Scheduler_Node *node, const Processor_mask *affinity ) { (void) scheduler; (void) the_thread; + (void) node; return _Processor_mask_Is_subset( affinity, _SMP_Get_online_processors() ); } diff --git a/cpukit/score/include/rtems/score/schedulerpriorityaffinitysmp.h b/cpukit/score/include/rtems/score/schedulerpriorityaffinitysmp.h index d53f76b090..e5eb916133 100644 --- a/cpukit/score/include/rtems/score/schedulerpriorityaffinitysmp.h +++ b/cpukit/score/include/rtems/score/schedulerpriorityaffinitysmp.h @@ -149,6 +149,7 @@ Thread_Control *_Scheduler_priority_affinity_SMP_Remove_processor( bool _Scheduler_priority_affinity_SMP_Set_affinity( const Scheduler_Control *scheduler, Thread_Control *thread, + Scheduler_Node *node, const Processor_mask *affinity ); -- cgit v1.2.3