Changeset 0f8e139e in rtems


Ignore:
Timestamp:
Feb 15, 2020, 1:00:08 PM (6 months ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
5, master
Children:
1608221
Parents:
f45d0b2f
git-author:
Sebastian Huber <sebastian.huber@…> (02/15/20 13:00:08)
git-committer:
Sebastian Huber <sebastian.huber@…> (02/25/20 06:18:36)
Message:

config: Add <rtems/confdefs/percpu.h>

Remove comments and copyrightable content from the moved content. Use
BSD-2-Clause for new file according to file history of
<rtems/confdefs.h>.

Update #3053.
Update #3875.

Location:
cpukit
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/headers.am

    rf45d0b2f r0f8e139e  
    187187include_rtems_confdefs_HEADERS += include/rtems/confdefs/libpci.h
    188188include_rtems_confdefs_HEADERS += include/rtems/confdefs/obsolete.h
     189include_rtems_confdefs_HEADERS += include/rtems/confdefs/percpu.h
    189190include_rtems_debugger_HEADERS += include/rtems/debugger/rtems-debugger-bsp.h
    190191include_rtems_debugger_HEADERS += include/rtems/debugger/rtems-debugger-remote.h
  • cpukit/include/rtems/confdefs.h

    rf45d0b2f r0f8e139e  
    3232#include <rtems/score/apimutex.h>
    3333#include <rtems/score/context.h>
    34 #include <rtems/score/percpu.h>
    3534#include <rtems/score/userextimpl.h>
    3635#include <rtems/score/wkspace.h>
     
    5251#include <rtems/posix/timer.h>
    5352#include <rtems/confdefs/obsolete.h>
    54 #include <rtems/confdefs/bsp.h>
    5553#include <rtems/confdefs/libpci.h>
     54#include <rtems/confdefs/percpu.h>
    5655
    5756#include <limits.h>
     
    133132   */
    134133  const uint32_t rtems_libio_number_iops = RTEMS_ARRAY_SIZE(rtems_libio_iops);
    135 #endif
    136 
    137 /* Ensure that _CONFIGURE_MAXIMUM_PROCESSORS > 1 only in SMP configurations */
    138 #if defined(CONFIGURE_MAXIMUM_PROCESSORS) && defined(RTEMS_SMP)
    139   #define _CONFIGURE_MAXIMUM_PROCESSORS CONFIGURE_MAXIMUM_PROCESSORS
    140 #else
    141   #define _CONFIGURE_MAXIMUM_PROCESSORS 1
    142134#endif
    143135
     
    980972
    981973/**
    982  * @defgroup ConfigurationIdle IDLE Thread Configuration
    983  *
    984  * @addtogroup Configuration
    985  *
    986  * This module contains configuration parameters related to the
    987  * set of IDLE threads. On a uniprocessor system, there is one
    988  * IDLE thread. On an SMP system, there is one for each core.
    989  */
    990 
    991 /*
    992  *  If you said the IDLE task was going to do application initialization
    993  *  and didn't override the IDLE body, then something is amiss.
    994  */
    995 #if (defined(CONFIGURE_IDLE_TASK_INITIALIZES_APPLICATION) && \
    996      !defined(CONFIGURE_IDLE_TASK_BODY))
    997   #error "CONFIGURE_ERROR: You did not override the IDLE task body."
    998 #endif
    999 
    1000 /**
    1001  * @brief Idle task body configuration.
    1002  *
    1003  * There is a default IDLE thread body provided by RTEMS which
    1004  * has the possibility of being CPU specific.  There may be a
    1005  * BSP specific override of the RTEMS default body and in turn,
    1006  * the application may override and provide its own.
    1007  */
    1008 #ifndef CONFIGURE_IDLE_TASK_BODY
    1009   #if defined(BSP_IDLE_TASK_BODY)
    1010     #define CONFIGURE_IDLE_TASK_BODY BSP_IDLE_TASK_BODY
    1011   #endif
    1012 #endif
    1013 
    1014 #if defined(CONFIGURE_INIT) && defined(CONFIGURE_IDLE_TASK_BODY)
    1015 const Thread_Idle_body _Thread_Idle_body = CONFIGURE_IDLE_TASK_BODY;
    1016 #endif
    1017 /**@}*/ /* end of IDLE thread configuration */
    1018 
    1019 /**
    1020  * @defgroup ConfigurationStackSize Configuration Thread Stack Size
    1021  *
    1022  * @addtogroup Configuration
    1023  *
    1024  * This module contains parameters related to thread and interrupt stacks.
    1025  */
    1026 
    1027 /**
    1028  * By default, use the minimum stack size requested by this port.
    1029  */
    1030 #ifndef CONFIGURE_MINIMUM_TASK_STACK_SIZE
    1031   #define CONFIGURE_MINIMUM_TASK_STACK_SIZE CPU_STACK_MINIMUM_SIZE
    1032 #endif
    1033 
    1034 /**
    1035  * This specifies the default POSIX thread stack size. By default, it is
    1036  * twice that recommended for the port.
    1037  */
    1038 #ifndef CONFIGURE_MINIMUM_POSIX_THREAD_STACK_SIZE
    1039 #define CONFIGURE_MINIMUM_POSIX_THREAD_STACK_SIZE \
    1040   (2 * CONFIGURE_MINIMUM_TASK_STACK_SIZE)
    1041 #endif
    1042 
    1043 /**
    1044  * @brief Idle task stack size configuration.
    1045  *
    1046  * By default, the IDLE task will have a stack of minimum size.
    1047  * The BSP or application may override this value.
    1048  */
    1049 #ifndef CONFIGURE_IDLE_TASK_STACK_SIZE
    1050   #ifdef BSP_IDLE_TASK_STACK_SIZE
    1051     #define CONFIGURE_IDLE_TASK_STACK_SIZE BSP_IDLE_TASK_STACK_SIZE
    1052   #else
    1053     #define CONFIGURE_IDLE_TASK_STACK_SIZE CONFIGURE_MINIMUM_TASK_STACK_SIZE
    1054   #endif
    1055 #endif
    1056 #if CONFIGURE_IDLE_TASK_STACK_SIZE < CONFIGURE_MINIMUM_TASK_STACK_SIZE
    1057   #error "CONFIGURE_IDLE_TASK_STACK_SIZE less than CONFIGURE_MINIMUM_TASK_STACK_SIZE"
    1058 #endif
    1059 
    1060 #ifdef CONFIGURE_INIT
    1061   const size_t _Thread_Idle_stack_size = CONFIGURE_IDLE_TASK_STACK_SIZE;
    1062 #endif
    1063 
    1064 /*
    1065  * Interrupt stack configuration.
    1066  *
    1067  * By default, the interrupt stack will be of minimum size.
    1068  * The BSP or application may override this value.
    1069  */
    1070 
    1071 #ifndef CONFIGURE_INTERRUPT_STACK_SIZE
    1072   #ifdef BSP_INTERRUPT_STACK_SIZE
    1073     #define CONFIGURE_INTERRUPT_STACK_SIZE BSP_INTERRUPT_STACK_SIZE
    1074   #else
    1075     #define CONFIGURE_INTERRUPT_STACK_SIZE CPU_STACK_MINIMUM_SIZE
    1076   #endif
    1077 #endif
    1078 
    1079 #if CONFIGURE_INTERRUPT_STACK_SIZE % CPU_INTERRUPT_STACK_ALIGNMENT != 0
    1080   #error "CONFIGURE_INTERRUPT_STACK_SIZE fails to meet the CPU port interrupt stack alignment"
    1081 #endif
    1082 
    1083 #ifdef CONFIGURE_INIT
    1084   RTEMS_DEFINE_GLOBAL_SYMBOL(
    1085     _ISR_Stack_size,
    1086     CONFIGURE_INTERRUPT_STACK_SIZE
    1087   );
    1088 
    1089   char _ISR_Stack_area_begin[
    1090     _CONFIGURE_MAXIMUM_PROCESSORS * CONFIGURE_INTERRUPT_STACK_SIZE
    1091   ] RTEMS_ALIGNED( CPU_INTERRUPT_STACK_ALIGNMENT )
    1092   RTEMS_SECTION( ".rtemsstack.interrupt.begin" );
    1093 
    1094   RTEMS_DEFINE_GLOBAL_SYMBOL_IN_SECTION(
    1095     _ISR_Stack_area_end,
    1096     ".rtemsstack.interrupt.end"
    1097   );
    1098 #endif
    1099 
    1100 /**
    1101  * @addtogroup Configuration
    1102  */
    1103 /**@{*/
    1104 
    1105 /**
    1106974 * @defgroup ConfigurationMalloc RTEMS Malloc configuration
    1107975 *
     
    21061974#define _CONFIGURE_HEAP_HANDLER_OVERHEAD \
    21071975  _Configure_Align_up( HEAP_BLOCK_HEADER_SIZE, CPU_HEAP_ALIGNMENT )
    2108 
    2109 /**
    2110  * This calculates the amount of memory reserved for the IDLE tasks.
    2111  * In an SMP system, each CPU core has its own idle task.
    2112  */
    2113 #define _CONFIGURE_IDLE_TASKS_COUNT _CONFIGURE_MAXIMUM_PROCESSORS
    21141976
    21151977/*
     
    23772239    OBJECTS_INTERNAL_API,
    23782240    OBJECTS_INTERNAL_THREADS,
    2379     _CONFIGURE_IDLE_TASKS_COUNT + _CONFIGURE_MPCI_RECEIVE_SERVER_COUNT
     2241    _CONFIGURE_MAXIMUM_PROCESSORS + _CONFIGURE_MPCI_RECEIVE_SERVER_COUNT
    23802242  );
    2381 
    2382   char _Thread_Idle_stacks[
    2383     _CONFIGURE_IDLE_TASKS_COUNT
    2384       * ( CONFIGURE_IDLE_TASK_STACK_SIZE
    2385         + CPU_IDLE_TASK_IS_FP * CONTEXT_FP_SIZE )
    2386   ] RTEMS_ALIGNED( CPU_INTERRUPT_STACK_ALIGNMENT )
    2387   RTEMS_SECTION( ".rtemsstack.idle" );
    23882243
    23892244  #if CONFIGURE_MAXIMUM_BARRIERS > 0
     
    25292384  #endif
    25302385
    2531   #ifdef RTEMS_SMP
    2532     const uint32_t _SMP_Processor_configured_maximum =
    2533       _CONFIGURE_MAXIMUM_PROCESSORS;
    2534   #endif
    2535 
    25362386  const uintptr_t _Workspace_Size = CONFIGURE_EXECUTIVE_RAM_SIZE;
    25372387
     
    25932443    );
    25942444  #endif
    2595 #endif
    2596 
    2597 #if defined(RTEMS_SMP)
    2598  /*
    2599   * Instantiate the Per CPU information based upon the user configuration.
    2600   */
    2601  #if defined(CONFIGURE_INIT)
    2602    Per_CPU_Control_envelope _Per_CPU_Information[_CONFIGURE_MAXIMUM_PROCESSORS];
    2603  #endif
    2604 
    26052445#endif
    26062446
Note: See TracChangeset for help on using the changeset viewer.