An extension set is defined as a set of routines which are invoked at each of the critical system events at which user extension routines are invoked. Together a set of these routines typically perform a specific functionality such as performance monitoring or debugger support. RTEMS is informed of the entry points which constitute an extension set via the following structure:
typedef struct { User_extensions_thread_create_extension thread_create; User_extensions_thread_start_extension thread_start; User_extensions_thread_restart_extension thread_restart; User_extensions_thread_delete_extension thread_delete; User_extensions_thread_switch_extension thread_switch; User_extensions_thread_post_switch_extension thread_post_switch; User_extensions_thread_begin_extension thread_begin; User_extensions_thread_exitted_extension thread_exitted; User_extensions_fatal_error_extension fatal; } User_extensions_Table;
RTEMS allows the user to have multiple extension sets active at the same time. First, a single static extension set may be defined as the application's User Extension Table which is included as part of the Configuration Table. This extension set is active for the entire life of the system and may not be deleted. This extension set is especially important because it is the only way the application can provided a FATAL error extension which is invoked if RTEMS fails during the initialize_executive directive. The static extension set is optional and may be configured as NULL if no static extension set is required.
Second, the user can install dynamic extensions using
the rtems_extension_create
directive. These extensions are RTEMS
objects in that they have a name, an ID, and can be dynamically
created and deleted. In contrast to the static extension set,
these extensions can only be created and installed after the
initialize_executive directive successfully completes execution.
Dynamic extensions are useful for encapsulating the
functionality of an extension set. For example, the application
could use extensions to manage a special coprocessor, do
performance monitoring, and to do stack bounds checking. Each
of these extension sets could be written and installed
independently of the others.
All user extensions are optional and RTEMS places no naming restrictions on the user.
Copyright © 1988-1998 OAR Corporation