Back to home page

LXR

 
 

    


File indexing completed on 2025-05-11 08:24:13

0001 /* SPDX-License-Identifier: BSD-2-Clause */
0002 
0003 /**
0004  * @file
0005  *
0006  * @ingroup RTEMSAPIConfig
0007  *
0008  * @brief This header file provides parts of the application configuration
0009  *   information API.
0010  */
0011 
0012 /*
0013  * Copyright (C) 2009, 2021 embedded brains GmbH & Co. KG
0014  * Copyright (C) 1988, 2021 On-Line Applications Research Corporation (OAR)
0015  *
0016  * Redistribution and use in source and binary forms, with or without
0017  * modification, are permitted provided that the following conditions
0018  * are met:
0019  * 1. Redistributions of source code must retain the above copyright
0020  *    notice, this list of conditions and the following disclaimer.
0021  * 2. Redistributions in binary form must reproduce the above copyright
0022  *    notice, this list of conditions and the following disclaimer in the
0023  *    documentation and/or other materials provided with the distribution.
0024  *
0025  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
0026  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
0027  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
0028  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
0029  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
0030  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
0031  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
0032  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
0033  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
0034  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
0035  * POSSIBILITY OF SUCH DAMAGE.
0036  */
0037 
0038 /*
0039  * This file is part of the RTEMS quality process and was automatically
0040  * generated.  If you find something that needs to be fixed or
0041  * worded better please post a report or patch to an RTEMS mailing list
0042  * or raise a bug report:
0043  *
0044  * https://www.rtems.org/bugs.html
0045  *
0046  * For information on updating and regenerating please refer to the How-To
0047  * section in the Software Requirements Engineering chapter of the
0048  * RTEMS Software Engineering manual.  The manual is provided as a part of
0049  * a release.  For development sources please refer to the online
0050  * documentation at:
0051  *
0052  * https://docs.rtems.org
0053  */
0054 
0055 /* Generated from spec:/rtems/config/if/header */
0056 
0057 #ifndef _RTEMS_CONFIG_H
0058 #define _RTEMS_CONFIG_H
0059 
0060 #include <stddef.h>
0061 #include <stdint.h>
0062 #include <rtems/rtems/config.h>
0063 #include <rtems/score/cpu.h>
0064 #include <rtems/score/cpuopts.h>
0065 #include <rtems/score/isr.h>
0066 #include <rtems/score/memory.h>
0067 #include <rtems/score/object.h>
0068 #include <rtems/score/smp.h>
0069 #include <rtems/score/stack.h>
0070 #include <rtems/score/threadidledata.h>
0071 #include <rtems/score/userextdata.h>
0072 #include <rtems/score/watchdogticks.h>
0073 #include <rtems/score/wkspacedata.h>
0074 
0075 #if defined(RTEMS_MULTIPROCESSING)
0076   #include <rtems/rtems/types.h>
0077   #include <rtems/score/mpci.h>
0078 #endif
0079 
0080 #ifdef __cplusplus
0081 extern "C" {
0082 #endif
0083 
0084 /* Generated from spec:/rtems/config/if/group */
0085 
0086 /**
0087  * @defgroup RTEMSAPIConfig Application Configuration Information
0088  *
0089  * @ingroup RTEMSAPI
0090  *
0091  * @brief The application configuration information group provides an API to
0092  *   get the configuration of an application.
0093  *
0094  * RTEMS must be configured for an application.  This configuration encompasses
0095  * a variety of information including the length of each clock tick, the
0096  * maximum number of each information RTEMS object that can be created, the
0097  * application initialization tasks, the task scheduling algorithm to be used,
0098  * and the device drivers in the application.
0099  *
0100  * Although this information is contained in data structures that are used by
0101  * RTEMS at system initialization time, the data structures themselves must not
0102  * be generated by hand. RTEMS provides a set of macros system which provides a
0103  * simple standard mechanism to automate the generation of these structures.
0104  *
0105  * The RTEMS header file ``<rtems/confdefs.h>`` is at the core of the automatic
0106  * generation of system configuration. It is based on the idea of setting
0107  * macros which define configuration parameters of interest to the application
0108  * and defaulting or calculating all others. This variety of macros can
0109  * automatically produce all of the configuration data required for an RTEMS
0110  * application.  The term ``confdefs`` is shorthand for a *Configuration
0111  * Defaults*.
0112  *
0113  * As a general rule, application developers only specify values for the
0114  * configuration parameters of interest to them. They define what resources or
0115  * features they require. In most cases, when a parameter is not specified, it
0116  * defaults to zero (0) instances, a standards compliant value, or disabled as
0117  * appropriate. For example, by default there will be 256 task priority levels
0118  * but this can be lowered by the application. This number of priority levels
0119  * is required to be compliant with the RTEID/ORKID standards upon which the
0120  * Classic API is based. There are similar cases where the default is selected
0121  * to be compliant with the POSIX standard.
0122  *
0123  * For each configuration parameter in the configuration tables, the macro
0124  * corresponding to that field is discussed. The RTEMS Maintainers expect that
0125  * all systems can be easily configured using the ``<rtems/confdefs.h>``
0126  * mechanism and that using this mechanism will avoid internal RTEMS
0127  * configuration changes impacting applications.
0128  *
0129  * Some application configuration settings and other system parameters can be
0130  * queried by the application.
0131  */
0132 
0133 /* Generated from spec:/rtems/config/if/unlimited-objects */
0134 
0135 /**
0136  * @ingroup RTEMSAPIConfig
0137  *
0138  * @brief This flag is used in augment a resource number so that it indicates
0139  *   an unlimited resource.
0140  */
0141 #define RTEMS_UNLIMITED_OBJECTS OBJECTS_UNLIMITED_OBJECTS
0142 
0143 /* Generated from spec:/rtems/config/if/get-stack-allocator-avoids-work-space */
0144 
0145 /**
0146  * @ingroup RTEMSAPIConfig
0147  *
0148  * @brief Indicates if the task stack allocator is configured to avoid the
0149  *   RTEMS Workspace for this application.
0150  *
0151  * @return Returns true, if the task stack allocator is configured to avoid the
0152  *   RTEMS Workspace for this application, otherwise false.
0153  *
0154  * @par Notes
0155  * The setting is defined by the @ref
0156  * CONFIGURE_TASK_STACK_ALLOCATOR_AVOIDS_WORK_SPACE application configuration
0157  * option.
0158  *
0159  * @par Constraints
0160  * @parblock
0161  * The following constraints apply to this directive:
0162  *
0163  * * The directive may be called from within any runtime context.
0164  *
0165  * * The directive will not cause the calling task to be preempted.
0166  * @endparblock
0167  */
0168 #define rtems_configuration_get_stack_allocator_avoids_work_space() \
0169   _Stack_Allocator_avoids_workspace
0170 
0171 /* Generated from spec:/rtems/config/if/get-stack-space-size */
0172 
0173 /**
0174  * @ingroup RTEMSAPIConfig
0175  *
0176  * @brief Gets the configured size in bytes of the memory space used to
0177  *   allocate thread stacks for this application.
0178  *
0179  * @return Returns the configured size in bytes of the memory space used to
0180  *   allocate thread stacks for this application.
0181  *
0182  * @par Notes
0183  * The size takes only threads and tasks into account with are known at the
0184  * application configuration time.
0185  *
0186  * @par Constraints
0187  * @parblock
0188  * The following constraints apply to this directive:
0189  *
0190  * * The directive may be called from within any runtime context.
0191  *
0192  * * The directive will not cause the calling task to be preempted.
0193  * @endparblock
0194  */
0195 uintptr_t rtems_configuration_get_stack_space_size( void );
0196 
0197 /* Generated from spec:/rtems/config/if/has-hardware-fp */
0198 
0199 /**
0200  * @ingroup RTEMSAPIConfig
0201  *
0202  * @brief This constant evaluates to #TRUE, if this processor variant has
0203  *   hardware floating point support, otherwise to #FALSE.
0204  */
0205 #define RTEMS_HAS_HARDWARE_FP CPU_HARDWARE_FP
0206 
0207 /* Generated from spec:/rtems/config/if/stack-allocate-hook */
0208 
0209 /**
0210  * @ingroup RTEMSAPIConfig
0211  *
0212  * @brief A thread stack allocator allocate handler shall have this type.
0213  */
0214 typedef Stack_Allocator_allocate rtems_stack_allocate_hook;
0215 
0216 /* Generated from spec:/rtems/config/if/stack-allocate-init-hook */
0217 
0218 /**
0219  * @ingroup RTEMSAPIConfig
0220  *
0221  * @brief A task stack allocator initialization handler shall have this type.
0222  */
0223 typedef Stack_Allocator_initialize rtems_stack_allocate_init_hook;
0224 
0225 /* Generated from spec:/rtems/config/if/stack-free-hook */
0226 
0227 /**
0228  * @ingroup RTEMSAPIConfig
0229  *
0230  * @brief A task stack allocator free handler shall have this type.
0231  */
0232 typedef Stack_Allocator_free rtems_stack_free_hook;
0233 
0234 /* Generated from spec:/rtems/config/if/get-build-label */
0235 
0236 /**
0237  * @ingroup RTEMSAPIConfig
0238  *
0239  * @brief Gets the RTEMS build label.
0240  *
0241  * The build label is a user-provided string defined by the build configuration
0242  * through the ``RTEMS_BUILD_LABEL`` build option.  The format of the string is
0243  * completely user-defined.
0244  *
0245  * @return Returns a pointer to the RTEMS build label.
0246  *
0247  * @par Notes
0248  * The build label can be used to distinguish test suite results obtained from
0249  * different build configurations.  A use case is to record test results with
0250  * performance data to track performance regressions.  For this a database of
0251  * performance limits is required.  The build label and the target hash
0252  * obtained from rtems_get_target_hash() can be used as a key to obtain
0253  * performance limits.
0254  *
0255  * @par Constraints
0256  * @parblock
0257  * The following constraints apply to this directive:
0258  *
0259  * * The directive may be called from within any runtime context.
0260  *
0261  * * The directive will not cause the calling task to be preempted.
0262  * @endparblock
0263  */
0264 const char *rtems_get_build_label( void );
0265 
0266 /* Generated from spec:/rtems/config/if/get-copyright-notice */
0267 
0268 /**
0269  * @ingroup RTEMSAPIConfig
0270  *
0271  * @brief Gets the RTEMS copyright notice.
0272  *
0273  * @return Returns a pointer to the RTEMS copyright notice.
0274  *
0275  * @par Constraints
0276  * @parblock
0277  * The following constraints apply to this directive:
0278  *
0279  * * The directive may be called from within any runtime context.
0280  *
0281  * * The directive will not cause the calling task to be preempted.
0282  * @endparblock
0283  */
0284 const char *rtems_get_copyright_notice( void );
0285 
0286 /* Generated from spec:/rtems/config/if/get-target-hash */
0287 
0288 /**
0289  * @ingroup RTEMSAPIConfig
0290  *
0291  * @brief Gets the RTEMS target hash.
0292  *
0293  * The target hash is calculated from BSP-specific values which characterize a
0294  * target system.  The target hash is encoded as a base64url string.  The
0295  * target hash algorithm is unspecified.
0296  *
0297  * @return Returns a pointer to the RTEMS target hash.
0298  *
0299  * @par Notes
0300  * @parblock
0301  * For example, the device tree, settings of the memory controller, processor
0302  * and bus frequencies, a serial number of a chip may be used to calculate the
0303  * target hash.
0304  *
0305  * The target hash can be used to distinguish test suite results obtained from
0306  * different target systems.  See also rtems_get_build_label().
0307  * @endparblock
0308  *
0309  * @par Constraints
0310  * @parblock
0311  * The following constraints apply to this directive:
0312  *
0313  * * The directive may be called from within any runtime context.
0314  *
0315  * * The directive will not cause the calling task to be preempted.
0316  * @endparblock
0317  */
0318 const char *rtems_get_target_hash( void );
0319 
0320 /* Generated from spec:/rtems/config/if/get-version-string */
0321 
0322 /**
0323  * @ingroup RTEMSAPIConfig
0324  *
0325  * @brief Gets the RTEMS version string.
0326  *
0327  * @return Returns a pointer to the RTEMS version string.
0328  *
0329  * @par Notes
0330  * The version string has no particular format.  Parsing the string may break
0331  * across RTEMS releases.
0332  *
0333  * @par Constraints
0334  * @parblock
0335  * The following constraints apply to this directive:
0336  *
0337  * * The directive may be called from within any runtime context.
0338  *
0339  * * The directive will not cause the calling task to be preempted.
0340  * @endparblock
0341  */
0342 const char *rtems_get_version_string( void );
0343 
0344 /* Generated from spec:/rtems/config/if/get-do-zero-of-workspace */
0345 
0346 /**
0347  * @ingroup RTEMSAPIConfig
0348  *
0349  * @brief Indicates if the RTEMS Workspace is configured to be zeroed during
0350  *   system initialization for this application.
0351  *
0352  * @return Returns true, if the RTEMS Workspace is configured to be zeroed
0353  *   during system initialization for this application, otherwise false.
0354  *
0355  * @par Notes
0356  * The setting is defined by the @ref CONFIGURE_ZERO_WORKSPACE_AUTOMATICALLY
0357  * application configuration option.
0358  *
0359  * @par Constraints
0360  * @parblock
0361  * The following constraints apply to this directive:
0362  *
0363  * * The directive may be called from within any runtime context.
0364  *
0365  * * The directive will not cause the calling task to be preempted.
0366  * @endparblock
0367  */
0368 #define rtems_configuration_get_do_zero_of_workspace() _Memory_Zero_before_use
0369 
0370 /* Generated from spec:/rtems/config/if/get-idle-task-stack-size */
0371 
0372 /**
0373  * @ingroup RTEMSAPIConfig
0374  *
0375  * @brief Gets the IDLE task stack size in bytes of this application.
0376  *
0377  * @return Returns the IDLE task stack size in bytes of this application.
0378  *
0379  * @par Notes
0380  * The IDLE task stack size is defined by the @ref
0381  * CONFIGURE_IDLE_TASK_STACK_SIZE application configuration option.
0382  *
0383  * @par Constraints
0384  * @parblock
0385  * The following constraints apply to this directive:
0386  *
0387  * * The directive may be called from within any runtime context.
0388  *
0389  * * The directive will not cause the calling task to be preempted.
0390  * @endparblock
0391  */
0392 #define rtems_configuration_get_idle_task_stack_size() _Thread_Idle_stack_size
0393 
0394 /* Generated from spec:/rtems/config/if/get-idle-task */
0395 
0396 /**
0397  * @ingroup RTEMSAPIConfig
0398  *
0399  * @brief Gets the IDLE task body of this application.
0400  *
0401  * @return Returns the IDLE task body of this application.
0402  *
0403  * @par Notes
0404  * The IDLE task body is defined by the @ref CONFIGURE_IDLE_TASK_BODY
0405  * application configuration option.
0406  *
0407  * @par Constraints
0408  * @parblock
0409  * The following constraints apply to this directive:
0410  *
0411  * * The directive may be called from within any runtime context.
0412  *
0413  * * The directive will not cause the calling task to be preempted.
0414  * @endparblock
0415  */
0416 #define rtems_configuration_get_idle_task() _Thread_Idle_body
0417 
0418 /* Generated from spec:/rtems/config/if/get-interrupt-stack-size */
0419 
0420 /**
0421  * @ingroup RTEMSAPIConfig
0422  *
0423  * @brief Gets the interrupt stack size in bytes of this application.
0424  *
0425  * @return Returns the interrupt stack size in bytes of this application.
0426  *
0427  * @par Notes
0428  * The interrupt stack size is defined by the @ref
0429  * CONFIGURE_INTERRUPT_STACK_SIZE application configuration option.
0430  *
0431  * @par Constraints
0432  * @parblock
0433  * The following constraints apply to this directive:
0434  *
0435  * * The directive may be called from within any runtime context.
0436  *
0437  * * The directive will not cause the calling task to be preempted.
0438  * @endparblock
0439  */
0440 #define rtems_configuration_get_interrupt_stack_size() \
0441   ((size_t) _ISR_Stack_size_object)
0442 
0443 /* Generated from spec:/rtems/config/if/get-maximum-extensions */
0444 
0445 /**
0446  * @ingroup RTEMSAPIConfig
0447  *
0448  * @brief Gets the resource number of @ref RTEMSAPIClassicUserExt objects
0449  *   configured for this application.
0450  *
0451  * @return Returns the resource number of @ref RTEMSAPIClassicUserExt objects
0452  *   configured for this application.
0453  *
0454  * @par Notes
0455  * The resource number is defined by the @ref CONFIGURE_MAXIMUM_USER_EXTENSIONS
0456  * application configuration option.  See also rtems_resource_is_unlimited()
0457  * and rtems_resource_maximum_per_allocation().
0458  *
0459  * @par Constraints
0460  * @parblock
0461  * The following constraints apply to this directive:
0462  *
0463  * * The directive may be called from within any runtime context.
0464  *
0465  * * The directive will not cause the calling task to be preempted.
0466  * @endparblock
0467  */
0468 uint32_t rtems_configuration_get_maximum_extensions( void );
0469 
0470 /* Generated from spec:/rtems/config/if/get-maximum-processors */
0471 
0472 /**
0473  * @ingroup RTEMSAPIConfig
0474  *
0475  * @brief Gets the maximum number of processors configured for this
0476  *   application.
0477  *
0478  * @return Returns the maximum number of processors configured for this
0479  *   application.
0480  *
0481  * @par Notes
0482  * @parblock
0483  * The actual number of processors available to the application is returned by
0484  * rtems_scheduler_get_processor_maximum() which less than or equal to the
0485  * configured maximum number of processors (@ref CONFIGURE_MAXIMUM_PROCESSORS).
0486  *
0487  * In uniprocessor configurations, this macro is a compile time constant which
0488  * evaluates to one.
0489  * @endparblock
0490  *
0491  * @par Constraints
0492  * @parblock
0493  * The following constraints apply to this directive:
0494  *
0495  * * The directive may be called from within any runtime context.
0496  *
0497  * * The directive will not cause the calling task to be preempted.
0498  * @endparblock
0499  */
0500 #define rtems_configuration_get_maximum_processors() \
0501   _SMP_Processor_configured_maximum
0502 
0503 /* Generated from spec:/rtems/config/if/get-microseconds-per-tick */
0504 
0505 /**
0506  * @ingroup RTEMSAPIConfig
0507  *
0508  * @brief Gets the number of microseconds per clock tick configured for this
0509  *   application.
0510  *
0511  * @return Returns the number of microseconds per clock tick configured for
0512  *   this application.
0513  *
0514  * @par Notes
0515  * The number of microseconds per clock tick is defined by the @ref
0516  * CONFIGURE_MICROSECONDS_PER_TICK application configuration option.
0517  *
0518  * @par Constraints
0519  * @parblock
0520  * The following constraints apply to this directive:
0521  *
0522  * * The directive may be called from within any runtime context.
0523  *
0524  * * The directive will not cause the calling task to be preempted.
0525  * @endparblock
0526  */
0527 #define rtems_configuration_get_microseconds_per_tick() \
0528   _Watchdog_Microseconds_per_tick
0529 
0530 /* Generated from spec:/rtems/config/if/get-milliseconds-per-tick */
0531 
0532 /**
0533  * @ingroup RTEMSAPIConfig
0534  *
0535  * @brief Gets the number of milliseconds per clock tick configured for this
0536  *   application.
0537  *
0538  * @return Returns the number of milliseconds per clock tick configured for
0539  *   this application.
0540  *
0541  * @par Notes
0542  * The number of milliseconds per clock tick is defined by the @ref
0543  * CONFIGURE_MICROSECONDS_PER_TICK application configuration option.
0544  *
0545  * @par Constraints
0546  * @parblock
0547  * The following constraints apply to this directive:
0548  *
0549  * * The directive may be called from within any runtime context.
0550  *
0551  * * The directive will not cause the calling task to be preempted.
0552  * @endparblock
0553  */
0554 #define rtems_configuration_get_milliseconds_per_tick() \
0555   ( _Watchdog_Microseconds_per_tick / 1000 )
0556 
0557 /* Generated from spec:/rtems/config/if/get-nanoseconds-per-tick */
0558 
0559 /**
0560  * @ingroup RTEMSAPIConfig
0561  *
0562  * @brief Gets the number of microseconds per clock tick configured for this
0563  *   application.
0564  *
0565  * @return Returns the number of microseconds per clock tick configured for
0566  *   this application.
0567  *
0568  * @par Notes
0569  * The number of nanoseconds per clock tick is defined by the @ref
0570  * CONFIGURE_MICROSECONDS_PER_TICK application configuration option.
0571  *
0572  * @par Constraints
0573  * @parblock
0574  * The following constraints apply to this directive:
0575  *
0576  * * The directive may be called from within any runtime context.
0577  *
0578  * * The directive will not cause the calling task to be preempted.
0579  * @endparblock
0580  */
0581 #define rtems_configuration_get_nanoseconds_per_tick() \
0582   _Watchdog_Nanoseconds_per_tick
0583 
0584 /* Generated from spec:/rtems/config/if/get-number-of-initial-extensions */
0585 
0586 /**
0587  * @ingroup RTEMSAPIConfig
0588  *
0589  * @brief Gets the number of initial extensions configured for this
0590  *   application.
0591  *
0592  * @return Returns the number of initial extensions configured for this
0593  *   application.
0594  *
0595  * @par Notes
0596  * The number of initial extensions is defined by the @ref
0597  * CONFIGURE_INITIAL_EXTENSIONS application configuration option and related
0598  * options.
0599  *
0600  * @par Constraints
0601  * @parblock
0602  * The following constraints apply to this directive:
0603  *
0604  * * The directive may be called from within any runtime context.
0605  *
0606  * * The directive will not cause the calling task to be preempted.
0607  * @endparblock
0608  */
0609 #define rtems_configuration_get_number_of_initial_extensions() \
0610   ((uint32_t) _User_extensions_Initial_count)
0611 
0612 /* Generated from spec:/rtems/config/if/get-stack-allocate-for-idle-hook */
0613 
0614 /**
0615  * @ingroup RTEMSAPIConfig
0616  *
0617  * @brief Gets the task stack allocator allocate hook used to allocate the
0618  *   stack of each IDLE task configured for this application.
0619  *
0620  * @return Returns the task stack allocator allocate hook used to allocate the
0621  *   stack of each IDLE task configured for this application.
0622  *
0623  * @par Notes
0624  * The task stack allocator allocate hook for idle tasks is defined by the @ref
0625  * CONFIGURE_TASK_STACK_ALLOCATOR_FOR_IDLE application configuration option.
0626  *
0627  * @par Constraints
0628  * @parblock
0629  * The following constraints apply to this directive:
0630  *
0631  * * The directive may be called from within any runtime context.
0632  *
0633  * * The directive will not cause the calling task to be preempted.
0634  * @endparblock
0635  */
0636 #define rtems_configuration_get_stack_allocate_for_idle_hook() \
0637   _Stack_Allocator_allocate_for_idle
0638 
0639 /* Generated from spec:/rtems/config/if/get-stack-allocate-hook */
0640 
0641 /**
0642  * @ingroup RTEMSAPIConfig
0643  *
0644  * @brief Gets the task stack allocator allocate hook configured for this
0645  *   application.
0646  *
0647  * @return Returns the task stack allocator allocate hook configured for this
0648  *   application.
0649  *
0650  * @par Notes
0651  * The task stack allocator allocate hook is defined by the @ref
0652  * CONFIGURE_TASK_STACK_ALLOCATOR application configuration option.
0653  *
0654  * @par Constraints
0655  * @parblock
0656  * The following constraints apply to this directive:
0657  *
0658  * * The directive may be called from within any runtime context.
0659  *
0660  * * The directive will not cause the calling task to be preempted.
0661  * @endparblock
0662  */
0663 #define rtems_configuration_get_stack_allocate_hook() _Stack_Allocator_allocate
0664 
0665 /* Generated from spec:/rtems/config/if/get-stack-allocate-init-hook */
0666 
0667 /**
0668  * @ingroup RTEMSAPIConfig
0669  *
0670  * @brief Gets the task stack allocator initialization hook configured for this
0671  *   application.
0672  *
0673  * @return Returns the task stack allocator initialization hook configured for
0674  *   this application.
0675  *
0676  * @par Notes
0677  * The task stack allocator initialization hook is defined by the @ref
0678  * CONFIGURE_TASK_STACK_ALLOCATOR_INIT application configuration option.
0679  *
0680  * @par Constraints
0681  * @parblock
0682  * The following constraints apply to this directive:
0683  *
0684  * * The directive may be called from within any runtime context.
0685  *
0686  * * The directive will not cause the calling task to be preempted.
0687  * @endparblock
0688  */
0689 #define rtems_configuration_get_stack_allocate_init_hook() \
0690   _Stack_Allocator_initialize
0691 
0692 /* Generated from spec:/rtems/config/if/get-stack-free-hook */
0693 
0694 /**
0695  * @ingroup RTEMSAPIConfig
0696  *
0697  * @brief Gets the task stack allocator free hook configured for this
0698  *   application.
0699  *
0700  * @return Returns the task stack allocator free hook configured for this
0701  *   application.
0702  *
0703  * @par Notes
0704  * The task stack allocator free hook is defined by the @ref
0705  * CONFIGURE_TASK_STACK_DEALLOCATOR application configuration option.
0706  *
0707  * @par Constraints
0708  * @parblock
0709  * The following constraints apply to this directive:
0710  *
0711  * * The directive may be called from within any runtime context.
0712  *
0713  * * The directive will not cause the calling task to be preempted.
0714  * @endparblock
0715  */
0716 #define rtems_configuration_get_stack_free_hook() _Stack_Allocator_free
0717 
0718 /* Generated from spec:/rtems/config/if/get-ticks-per-timeslice */
0719 
0720 /**
0721  * @ingroup RTEMSAPIConfig
0722  *
0723  * @brief Gets the clock ticks per timeslice configured for this application.
0724  *
0725  * @return Returns the clock ticks per timeslice configured for this
0726  *   application.
0727  *
0728  * @par Notes
0729  * The clock ticks per timeslice is defined by the @ref
0730  * CONFIGURE_TICKS_PER_TIMESLICE application configuration option.
0731  *
0732  * @par Constraints
0733  * @parblock
0734  * The following constraints apply to this directive:
0735  *
0736  * * The directive may be called from within any runtime context.
0737  *
0738  * * The directive will not cause the calling task to be preempted.
0739  * @endparblock
0740  */
0741 #define rtems_configuration_get_ticks_per_timeslice() \
0742   _Watchdog_Ticks_per_timeslice
0743 
0744 /* Generated from spec:/rtems/config/if/get-unified-work-area */
0745 
0746 /**
0747  * @ingroup RTEMSAPIConfig
0748  *
0749  * @brief Indicates if the RTEMS Workspace and C Program Heap are configured to
0750  *   be unified for this application.
0751  *
0752  * @return Returns true, if the RTEMS Workspace and C Program Heap are
0753  *   configured to be unified for this application, otherwise false.
0754  *
0755  * @par Notes
0756  * The setting is defined by the @ref CONFIGURE_UNIFIED_WORK_AREAS application
0757  * configuration option.
0758  *
0759  * @par Constraints
0760  * @parblock
0761  * The following constraints apply to this directive:
0762  *
0763  * * The directive may be called from within any runtime context.
0764  *
0765  * * The directive will not cause the calling task to be preempted.
0766  * @endparblock
0767  */
0768 #define rtems_configuration_get_unified_work_area() _Workspace_Is_unified
0769 
0770 /* Generated from spec:/rtems/config/if/get-user-extension-table */
0771 
0772 /**
0773  * @ingroup RTEMSAPIConfig
0774  *
0775  * @brief Gets the initial extensions table configured for this application.
0776  *
0777  * @return Returns a pointer to the initial extensions table configured for
0778  *   this application.
0779  *
0780  * @par Constraints
0781  * @parblock
0782  * The following constraints apply to this directive:
0783  *
0784  * * The directive may be called from within any runtime context.
0785  *
0786  * * The directive will not cause the calling task to be preempted.
0787  * @endparblock
0788  */
0789 #define rtems_configuration_get_user_extension_table() \
0790   _User_extensions_Initial_extensions
0791 
0792 /* Generated from spec:/rtems/config/if/get-user-multiprocessing-table */
0793 
0794 /**
0795  * @ingroup RTEMSAPIConfig
0796  *
0797  * @brief Gets the MPCI configuration table configured for this application.
0798  *
0799  * @return Returns a pointer to the MPCI configuration table configured for
0800  *   this application.
0801  *
0802  * @par Constraints
0803  * @parblock
0804  * The following constraints apply to this directive:
0805  *
0806  * * The directive may be called from within any runtime context.
0807  *
0808  * * The directive will not cause the calling task to be preempted.
0809  * @endparblock
0810  */
0811 #if defined(RTEMS_MULTIPROCESSING)
0812   #define rtems_configuration_get_user_multiprocessing_table() \
0813     ( &_MPCI_Configuration )
0814 #else
0815   #define rtems_configuration_get_user_multiprocessing_table() NULL
0816 #endif
0817 
0818 /* Generated from spec:/rtems/config/if/get-work-space-size */
0819 
0820 /**
0821  * @ingroup RTEMSAPIConfig
0822  *
0823  * @brief Gets the RTEMS Workspace size in bytes configured for this
0824  *   application.
0825  *
0826  * @return Returns the RTEMS Workspace size in bytes configured for this
0827  *   application.
0828  *
0829  * @par Constraints
0830  * @parblock
0831  * The following constraints apply to this directive:
0832  *
0833  * * The directive may be called from within any runtime context.
0834  *
0835  * * The directive will not cause the calling task to be preempted.
0836  * @endparblock
0837  */
0838 #define rtems_configuration_get_work_space_size() \
0839   ( _Workspace_Size + \
0840     ( rtems_configuration_get_stack_allocator_avoids_work_space() ? \
0841       0 : rtems_configuration_get_stack_space_size() ) )
0842 
0843 /* Generated from spec:/rtems/config/if/resource-is-unlimited */
0844 
0845 /**
0846  * @ingroup RTEMSAPIConfig
0847  *
0848  * @brief Indicates if the resource is unlimited.
0849  *
0850  * @param _resource is the resource number.
0851  *
0852  * @return Returns true, if the resource is unlimited, otherwise false.
0853  *
0854  * @par Constraints
0855  * @parblock
0856  * The following constraints apply to this directive:
0857  *
0858  * * The directive is implemented by a macro and may be called from within
0859  *   C/C++ constant expressions.  In addition, a function implementation of the
0860  *   directive exists for bindings to other programming languages.
0861  *
0862  * * The directive will not cause the calling task to be preempted.
0863  * @endparblock
0864  */
0865 #define rtems_resource_is_unlimited( _resource ) \
0866   _Objects_Is_unlimited( _resource )
0867 
0868 /* Generated from spec:/rtems/config/if/resource-maximum-per-allocation */
0869 
0870 /**
0871  * @ingroup RTEMSAPIConfig
0872  *
0873  * @brief Gets the maximum number per allocation of a resource number.
0874  *
0875  * @param _resource is the resource number.
0876  *
0877  * @return Returns the maximum number per allocation of a resource number.
0878  *
0879  * @par Constraints
0880  * @parblock
0881  * The following constraints apply to this directive:
0882  *
0883  * * The directive is implemented by a macro and may be called from within
0884  *   C/C++ constant expressions.  In addition, a function implementation of the
0885  *   directive exists for bindings to other programming languages.
0886  *
0887  * * The directive will not cause the calling task to be preempted.
0888  * @endparblock
0889  */
0890 #define rtems_resource_maximum_per_allocation( _resource ) \
0891   _Objects_Maximum_per_allocation( _resource )
0892 
0893 /* Generated from spec:/rtems/config/if/resource-unlimited */
0894 
0895 /**
0896  * @ingroup RTEMSAPIConfig
0897  *
0898  * @brief Augments the resource number so that it indicates an unlimited
0899  *   resource.
0900  *
0901  * @param _resource is the resource number to augment.
0902  *
0903  * @return Returns the resource number augmented to indicate an unlimited
0904  *   resource.
0905  *
0906  * @par Notes
0907  * This directive should be used to configure unlimited objects, see Unlimited
0908  * Objects.
0909  *
0910  * @par Constraints
0911  * @parblock
0912  * The following constraints apply to this directive:
0913  *
0914  * * The directive is implemented by a macro and may be called from within
0915  *   C/C++ constant expressions.  In addition, a function implementation of the
0916  *   directive exists for bindings to other programming languages.
0917  *
0918  * * The directive will not cause the calling task to be preempted.
0919  * @endparblock
0920  */
0921 #define rtems_resource_unlimited( _resource ) \
0922   ( ( _resource ) | RTEMS_UNLIMITED_OBJECTS )
0923 
0924 #ifdef __cplusplus
0925 }
0926 #endif
0927 
0928 #endif /* _RTEMS_CONFIG_H */