summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2017-07-07 07:36:52 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2017-07-07 07:56:24 +0200
commit16347a6b3910b04932225f1ea296a7adf206ec9e (patch)
tree1599a808014267641916c3ed0d2cf80f637774e9 /cpukit/score/include/rtems
parentscore: Introduce _SMP_Get_online_processors() (diff)
downloadrtems-16347a6b3910b04932225f1ea296a7adf206ec9e.tar.bz2
score: Fix default set affinity
The set of online processors must be a subset of the thread processor affinity for the schedulers without arbitrary processor affinity support to avoid problems in case of processor addition and removal. Update #3059.
Diffstat (limited to 'cpukit/score/include/rtems')
-rw-r--r--cpukit/score/include/rtems/score/schedulerimpl.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/cpukit/score/include/rtems/score/schedulerimpl.h b/cpukit/score/include/rtems/score/schedulerimpl.h
index 6f220acf57..49aaf029e1 100644
--- a/cpukit/score/include/rtems/score/schedulerimpl.h
+++ b/cpukit/score/include/rtems/score/schedulerimpl.h
@@ -612,10 +612,9 @@ RTEMS_INLINE_ROUTINE bool _Scheduler_default_Set_affinity_body(
const Processor_mask *affinity
)
{
- return _Processor_mask_Is_subset(
- affinity,
- _Scheduler_Get_processors( scheduler )
- );
+ (void) scheduler;
+ (void) the_thread;
+ return _Processor_mask_Is_subset( affinity, _SMP_Get_online_processors() );
}
bool _Scheduler_Set_affinity(