diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2019-12-12 07:11:54 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2019-12-13 08:35:17 +0100 |
commit | 24f8915a079446918abd4f7b2a8e1b8385930f85 (patch) | |
tree | 708417a866d436b619e471d834b56f95109eb66f /cpukit/score/src/mpci.c | |
parent | a00dff42cfdf201abe15829baeeb2b6341a0426b (diff) |
config: Add _MPCI_Configuration
Replace the user MPCI configuration table with a system provided
_MPCI_Configuration.
Update #3735.
Diffstat (limited to 'cpukit/score/src/mpci.c')
-rw-r--r-- | cpukit/score/src/mpci.c | 26 |
1 files changed, 3 insertions, 23 deletions
diff --git a/cpukit/score/src/mpci.c b/cpukit/score/src/mpci.c index f488325fc5..513d096480 100644 --- a/cpukit/score/src/mpci.c +++ b/cpukit/score/src/mpci.c @@ -27,7 +27,6 @@ #include <rtems/score/schedulerimpl.h> #include <rtems/score/threadimpl.h> #include <rtems/score/threadqimpl.h> -#include <rtems/config.h> #include <rtems/sysinit.h> RTEMS_STATIC_ASSERT( @@ -39,18 +38,6 @@ RTEMS_STATIC_ASSERT( bool _System_state_Is_multiprocessing; -rtems_multiprocessing_table *_Configuration_MP_table; - -const rtems_multiprocessing_table - _Initialization_Default_multiprocessing_table = { - 1, /* local node number */ - 1, /* maximum number nodes in system */ - 0, /* maximum number global objects */ - 0, /* maximum number proxies */ - STACK_MINIMUM_SIZE, /* MPCI receive server stack size */ - NULL /* pointer to MPCI address table */ -}; - /** * This is the core semaphore which the MPCI Receive Server blocks on. */ @@ -72,14 +59,7 @@ static void _MPCI_Handler_early_initialization( void ) * In an MP configuration, internally we view single processor * systems as a very restricted multiprocessor system. */ - _Configuration_MP_table = rtems_configuration_get_user_multiprocessing_table(); - - if ( _Configuration_MP_table == NULL ) { - _Configuration_MP_table = RTEMS_DECONST( - rtems_multiprocessing_table *, - &_Initialization_Default_multiprocessing_table - ); - } else { + if ( _MPCI_Configuration.maximum_nodes > 1 ) { _System_state_Is_multiprocessing = true; } @@ -92,7 +72,7 @@ static void _MPCI_Handler_initialization( void ) _Objects_MP_Handler_initialization(); - users_mpci_table = _Configuration_MP_table->User_mpci_table; + users_mpci_table = _MPCI_Configuration.User_mpci_table; if ( _System_state_Is_multiprocessing && !users_mpci_table ) _Internal_error( INTERNAL_ERROR_NO_MPCI ); @@ -152,7 +132,7 @@ static void _MPCI_Create_server( void ) NULL, /* allocate the stack */ _Stack_Minimum() + CPU_MPCI_RECEIVE_SERVER_EXTRA_STACK + - _Configuration_MP_table->extra_mpci_receive_server_stack, + _MPCI_Configuration.extra_mpci_receive_server_stack, CPU_ALL_TASKS_ARE_FP, PRIORITY_PSEUDO_ISR, false, /* no preempt */ |