From 9520ec3a2aab575e264410d1ce95c468897c3bc9 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Fri, 14 Feb 2020 09:31:44 +0100 Subject: config: Simplify initialization task config With the removal of the CONFIGURE_HAS_OWN_INIT_TASK_TABLE configuration option at most one Classic API user initialization task can be configured. Provide an RTEMS API configuration table for backward compatibility. Update #3873. --- cpukit/include/rtems/confdefs.h | 59 ++++++++--------------------------------- 1 file changed, 11 insertions(+), 48 deletions(-) (limited to 'cpukit/include/rtems/confdefs.h') diff --git a/cpukit/include/rtems/confdefs.h b/cpukit/include/rtems/confdefs.h index b5f8de4cd1..13ba4466f0 100644 --- a/cpukit/include/rtems/confdefs.h +++ b/cpukit/include/rtems/confdefs.h @@ -103,11 +103,6 @@ extern "C" { * used remarkably reliably by most applications. */ -/** - * This is the Classic API initialization tasks table. - */ -extern rtems_initialization_tasks_table Initialization_tasks[]; - /** * This macro determines whether the RTEMS reentrancy support for * the Newlib C Library is enabled. @@ -1362,42 +1357,8 @@ extern rtems_initialization_tasks_table Initialization_tasks[]; #define CONFIGURE_INIT_TASK_ARGUMENTS 0 #endif -#ifdef CONFIGURE_INIT - rtems_initialization_tasks_table Initialization_tasks[] = { - { CONFIGURE_INIT_TASK_NAME, - CONFIGURE_INIT_TASK_STACK_SIZE, - CONFIGURE_INIT_TASK_PRIORITY, - CONFIGURE_INIT_TASK_ATTRIBUTES, - CONFIGURE_INIT_TASK_ENTRY_POINT, - CONFIGURE_INIT_TASK_INITIAL_MODES, - CONFIGURE_INIT_TASK_ARGUMENTS - } - }; -#endif - -/** - * This is the name of the Initialization Tasks Table generated. - */ -#define CONFIGURE_INIT_TASK_TABLE Initialization_tasks - -/* - * This is the size of the Initialization Tasks Table generated. - */ -#define CONFIGURE_INIT_TASK_TABLE_SIZE \ - RTEMS_ARRAY_SIZE(CONFIGURE_INIT_TASK_TABLE) - #else /* CONFIGURE_RTEMS_INIT_TASKS_TABLE */ -/* - * This is the name of the Initialization Task when none is configured. - */ -#define CONFIGURE_INIT_TASK_TABLE NULL - -/* - * This is the size of the Initialization Task when none is configured. - */ -#define CONFIGURE_INIT_TASK_TABLE_SIZE 0 - /* * This is the stack size of the Initialization Task when none is configured. */ @@ -2580,14 +2541,6 @@ struct _reent *__getreent(void) EXTENSION_INFORMATION_DEFINE( CONFIGURE_MAXIMUM_USER_EXTENSIONS ); #endif - /** - * This is the Classic API Configuration Table. - */ - rtems_api_configuration_table Configuration_RTEMS_API = { - CONFIGURE_INIT_TASK_TABLE_SIZE, - CONFIGURE_INIT_TASK_TABLE - }; - #if CONFIGURE_MAXIMUM_POSIX_KEY_VALUE_PAIRS > 0 POSIX_Keys_Key_value_pair _POSIX_Keys_Key_value_pairs[ rtems_resource_maximum_per_allocation( @@ -2779,8 +2732,18 @@ struct _reent *__getreent(void) */ #ifdef CONFIGURE_INIT #if defined(CONFIGURE_RTEMS_INIT_TASKS_TABLE) + const rtems_initialization_tasks_table _RTEMS_tasks_User_task_table = { + CONFIGURE_INIT_TASK_NAME, + CONFIGURE_INIT_TASK_STACK_SIZE, + CONFIGURE_INIT_TASK_PRIORITY, + CONFIGURE_INIT_TASK_ATTRIBUTES, + CONFIGURE_INIT_TASK_ENTRY_POINT, + CONFIGURE_INIT_TASK_INITIAL_MODES, + CONFIGURE_INIT_TASK_ARGUMENTS + }; + RTEMS_SYSINIT_ITEM( - _RTEMS_tasks_Initialize_user_tasks_body, + _RTEMS_tasks_Initialize_user_task, RTEMS_SYSINIT_CLASSIC_USER_TASKS, RTEMS_SYSINIT_ORDER_MIDDLE ); -- cgit v1.2.3