forked from Imagelibrary/rtems
confdefs.h: Add SMP enabled field to configuration
Do not use the processor count to determine if SMP is enabled. Instead use a dedicated configuration option. Enable SMP by default in SMP configurations. Add CONFIGURE_DISABLE_SMP_CONFIGURATION to all test which would fail otherwise. Update #3001.
This commit is contained in:
@@ -3320,6 +3320,13 @@ extern rtems_initialization_tasks_table Initialization_tasks[];
|
|||||||
#else
|
#else
|
||||||
false,
|
false,
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef RTEMS_SMP
|
||||||
|
#ifdef _CONFIGURE_SMP_APPLICATION
|
||||||
|
true,
|
||||||
|
#else
|
||||||
|
false,
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
_CONFIGURE_NUMBER_OF_INITIAL_EXTENSIONS, /* number of static extensions */
|
_CONFIGURE_NUMBER_OF_INITIAL_EXTENSIONS, /* number of static extensions */
|
||||||
CONFIGURE_INITIAL_EXTENSION_TABLE, /* pointer to static extensions */
|
CONFIGURE_INITIAL_EXTENSION_TABLE, /* pointer to static extensions */
|
||||||
#if defined(RTEMS_MULTIPROCESSING)
|
#if defined(RTEMS_MULTIPROCESSING)
|
||||||
|
|||||||
@@ -237,6 +237,10 @@ typedef struct {
|
|||||||
*/
|
*/
|
||||||
bool stack_allocator_avoids_work_space;
|
bool stack_allocator_avoids_work_space;
|
||||||
|
|
||||||
|
#ifdef RTEMS_SMP
|
||||||
|
bool smp_enabled;
|
||||||
|
#endif
|
||||||
|
|
||||||
uint32_t number_of_initial_extensions;
|
uint32_t number_of_initial_extensions;
|
||||||
const rtems_extensions_table *User_extension_table;
|
const rtems_extensions_table *User_extension_table;
|
||||||
#if defined(RTEMS_MULTIPROCESSING)
|
#if defined(RTEMS_MULTIPROCESSING)
|
||||||
@@ -360,7 +364,7 @@ extern const rtems_configuration_table Configuration;
|
|||||||
*/
|
*/
|
||||||
#ifdef RTEMS_SMP
|
#ifdef RTEMS_SMP
|
||||||
#define rtems_configuration_is_smp_enabled() \
|
#define rtems_configuration_is_smp_enabled() \
|
||||||
(rtems_configuration_get_maximum_processors() > 1)
|
(Configuration.smp_enabled)
|
||||||
#else
|
#else
|
||||||
#define rtems_configuration_is_smp_enabled() \
|
#define rtems_configuration_is_smp_enabled() \
|
||||||
false
|
false
|
||||||
|
|||||||
@@ -50,6 +50,8 @@ void Task_switch(
|
|||||||
|
|
||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -47,6 +47,8 @@ void Get_all_counters( void );
|
|||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
#define CONFIGURE_EXTRA_TASK_STACKS (20 * RTEMS_MINIMUM_STACK_SIZE)
|
#define CONFIGURE_EXTRA_TASK_STACKS (20 * RTEMS_MINIMUM_STACK_SIZE)
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -166,6 +166,8 @@ rtems_task Init(
|
|||||||
|
|
||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#define CONFIGURE_INIT
|
#define CONFIGURE_INIT
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|||||||
@@ -31,6 +31,8 @@ rtems_task Task_1_through_3(
|
|||||||
#define CONFIGURE_EXTRA_TASK_STACKS (4 * RTEMS_MINIMUM_STACK_SIZE)
|
#define CONFIGURE_EXTRA_TASK_STACKS (4 * RTEMS_MINIMUM_STACK_SIZE)
|
||||||
#define CONFIGURE_MAXIMUM_TASKS 4
|
#define CONFIGURE_MAXIMUM_TASKS 4
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -300,6 +300,8 @@ rtems_task Init(
|
|||||||
|
|
||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#define CONFIGURE_INIT
|
#define CONFIGURE_INIT
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
/* end of file */
|
/* end of file */
|
||||||
|
|||||||
@@ -51,6 +51,8 @@ rtems_task Task_2(
|
|||||||
|
|
||||||
#define CONFIGURE_EXTRA_TASK_STACKS (1 * RTEMS_MINIMUM_STACK_SIZE)
|
#define CONFIGURE_EXTRA_TASK_STACKS (1 * RTEMS_MINIMUM_STACK_SIZE)
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -47,6 +47,8 @@ void Get_all_counters( void );
|
|||||||
|
|
||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -39,6 +39,8 @@ rtems_task Init(
|
|||||||
#define CONFIGURE_MAXIMUM_TASKS 2
|
#define CONFIGURE_MAXIMUM_TASKS 2
|
||||||
#define CONFIGURE_MAXIMUM_TIMERS 1
|
#define CONFIGURE_MAXIMUM_TIMERS 1
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* end of include file */
|
/* end of include file */
|
||||||
|
|||||||
@@ -37,6 +37,8 @@ rtems_task Task_1_through_3(
|
|||||||
#define CONFIGURE_EXTRA_TASK_STACKS (4 * RTEMS_MINIMUM_STACK_SIZE)
|
#define CONFIGURE_EXTRA_TASK_STACKS (4 * RTEMS_MINIMUM_STACK_SIZE)
|
||||||
#define CONFIGURE_MAXIMUM_TASKS 4
|
#define CONFIGURE_MAXIMUM_TASKS 4
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -43,6 +43,8 @@ rtems_task Task_Periodic(
|
|||||||
|
|
||||||
#define CONFIGURE_SCHEDULER_CBS
|
#define CONFIGURE_SCHEDULER_CBS
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
#include <rtems/rtems/clock.h>
|
#include <rtems/rtems/clock.h>
|
||||||
|
|||||||
@@ -47,6 +47,8 @@ rtems_task Tasks_Aperiodic(
|
|||||||
|
|
||||||
#define CONFIGURE_SCHEDULER_CBS
|
#define CONFIGURE_SCHEDULER_CBS
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
#include <rtems/rtems/clock.h>
|
#include <rtems/rtems/clock.h>
|
||||||
|
|||||||
@@ -37,6 +37,8 @@ rtems_task Task_1_through_3(
|
|||||||
#define CONFIGURE_EXTRA_TASK_STACKS (4 * RTEMS_MINIMUM_STACK_SIZE)
|
#define CONFIGURE_EXTRA_TASK_STACKS (4 * RTEMS_MINIMUM_STACK_SIZE)
|
||||||
#define CONFIGURE_MAXIMUM_TASKS 4
|
#define CONFIGURE_MAXIMUM_TASKS 4
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -49,6 +49,8 @@ void Get_all_counters( void );
|
|||||||
|
|
||||||
#define CONFIGURE_SCHEDULER_EDF
|
#define CONFIGURE_SCHEDULER_EDF
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* global variables */
|
/* global variables */
|
||||||
|
|||||||
@@ -47,6 +47,8 @@ rtems_task Tasks_Aperiodic(
|
|||||||
|
|
||||||
#define CONFIGURE_SCHEDULER_EDF
|
#define CONFIGURE_SCHEDULER_EDF
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
#include <rtems/rtems/clock.h>
|
#include <rtems/rtems/clock.h>
|
||||||
|
|||||||
@@ -215,9 +215,9 @@ rtems_task Init(
|
|||||||
|
|
||||||
#define CONFIGURE_MAXIMUM_BARRIERS 1
|
#define CONFIGURE_MAXIMUM_BARRIERS 1
|
||||||
|
|
||||||
#define CONFIGURE_INIT
|
|
||||||
#define CONFIGURE_MAXIMUM_FIFOS 1
|
#define CONFIGURE_MAXIMUM_FIFOS 1
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#define CONFIGURE_INIT
|
#define CONFIGURE_INIT
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|||||||
@@ -270,9 +270,9 @@ rtems_task Init(
|
|||||||
|
|
||||||
#define CONFIGURE_MAXIMUM_BARRIERS 2
|
#define CONFIGURE_MAXIMUM_BARRIERS 2
|
||||||
|
|
||||||
#define CONFIGURE_INIT
|
|
||||||
#define CONFIGURE_MAXIMUM_FIFOS 1
|
#define CONFIGURE_MAXIMUM_FIFOS 1
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#define CONFIGURE_INIT
|
#define CONFIGURE_INIT
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|||||||
@@ -32,6 +32,8 @@ rtems_task Init(
|
|||||||
|
|
||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* end of include file */
|
/* end of include file */
|
||||||
|
|||||||
@@ -38,6 +38,8 @@ rtems_task Init(
|
|||||||
CONFIGURE_MESSAGE_BUFFERS_FOR_QUEUE(100, MESSAGE_SIZE )
|
CONFIGURE_MESSAGE_BUFFERS_FOR_QUEUE(100, MESSAGE_SIZE )
|
||||||
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
|
||||||
|
|
||||||
|
#define CONFIGURE_DISABLE_SMP_CONFIGURATION
|
||||||
|
|
||||||
#include <rtems/confdefs.h>
|
#include <rtems/confdefs.h>
|
||||||
|
|
||||||
/* end of include file */
|
/* end of include file */
|
||||||
|
|||||||
Reference in New Issue
Block a user