source: rtems/c/src/exec/score/headers/sysstate.h @ 3a4ae6c

4.104.114.84.95
Last change on this file since 3a4ae6c was 3a4ae6c, checked in by Joel Sherrill <joel.sherrill@…>, on 09/11/95 at 19:35:39

The word "RTEMS" almost completely removed from the core.

Configuration Table Template file added and all tests
modified to use this. All gvar.h and conftbl.h files
removed from test directories.

Configuration parameter maximum_devices added.

Core semaphore and mutex handlers added and RTEMS API Semaphore
Manager updated to reflect this.

Initialization sequence changed to invoke API specific initialization
routines. Initialization tasks table now owned by RTEMS Tasks Manager.

Added user extension for post-switch.

Utilized user extensions to implement API specific functionality
like signal dispatching.

Added extensions to the System Initialization Thread so that an
API can register a function to be invoked while the system
is being initialized. These are largely equivalent to the
pre-driver and post-driver hooks.

Added the Modules file oar-go32_p5, modified oar-go32, and modified
the file make/custom/go32.cfg to look at an environment varable which
determines what CPU model is being used.

All BSPs updated to reflect named devices and clock driver's IOCTL
used by the Shared Memory Driver. Also merged clock isr into
main file and removed ckisr.c where possible.

Updated spsize to reflect new and moved variables.

Makefiles for the executive source and include files updated to show
break down of files into Core, RTEMS API, and Neither.

Header and inline files installed into subdirectory based on whether
logically in the Core or a part of the RTEMS API.

  • Property mode set to 100644
File size: 3.4 KB
Line 
1/*  sysstates.h
2 *
3 *  This include file contains information regarding the system state.
4 *
5 *  COPYRIGHT (c) 1989, 1990, 1991, 1992, 1993, 1994.
6 *  On-Line Applications Research Corporation (OAR).
7 *  All rights assigned to U.S. Government, 1994.
8 *
9 *  This material may be reproduced by or for the U.S. Government pursuant
10 *  to the copyright license under the clause at DFARS 252.227-7013.  This
11 *  notice must appear in all copies of this file and its derivatives.
12 *
13 *  $Id$
14 */
15
16#ifndef __RTEMS_SYSTEM_STATE_h
17#define __RTEMS_SYSTEM_STATE_h
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
23/* types */
24
25/* enumerated constants */
26
27/*
28 *  The following type defines the possible system states.
29 */
30
31typedef enum {
32  SYSTEM_STATE_BEFORE_INITIALIZATION,   /* start -> end of 1st init part */
33  SYSTEM_STATE_BEFORE_MULTITASKING,     /* end of 1st -> beginning of 2nd */
34  SYSTEM_STATE_BEGIN_MULTITASKING,      /* beginning of 2nd -> end of SYSI */
35  SYSTEM_STATE_UP,                      /* normal operation */
36  SYSTEM_STATE_FAILED                   /* fatal error occurred */
37} System_state_Codes;
38
39#define SYSTEM_STATE_CODES_FIRST SYSTEM_STATE_BEFORE_INITIALIZATION
40#define SYSTEM_STATE_CODES_LAST  SYSTEM_STATE_FAILED
41
42/*
43 *  The following variable indicates whether or not this is
44 *  an multiprocessing system.
45 */
46 
47EXTERN boolean _System_state_Is_multiprocessing;
48
49/*
50 *  The following variable contains the current system state.
51 */
52
53EXTERN System_state_Codes _System_state_Current;
54
55/*
56 *  _System_state_Handler_initialization
57 *
58 *  DESCRIPTION:
59 *
60 *  This routine initializes the system state handler.
61 */
62 
63STATIC INLINE void _System_state_Handler_initialization (
64  boolean  is_multiprocessing
65);
66 
67/*
68 *  _System_state_Set
69 *
70 *  DESCRIPTION:
71 *
72 *  This routine sets the current system state to that specified by
73 *  the called.
74 */
75
76STATIC INLINE void _System_state_Set (
77  System_state_Codes state
78);
79
80/*
81 *  _System_state_Get
82 *
83 *  DESCRIPTION:
84 *
85 *  This function returns the current system state.
86 */
87
88STATIC INLINE System_state_Codes _System_state_Get ( void );
89
90/*
91 *  _System_state_Is_before_initialization
92 *
93 *  DESCRIPTION:
94 *
95 *  This function returns TRUE if the state is equal to the
96 *  "before initialization" state, and FALSE otherwise.
97 */
98
99STATIC INLINE boolean _System_state_Is_before_initialization (
100  System_state_Codes state
101);
102
103/*
104 *  _System_state_Is_before_multitasking
105 *
106 *  DESCRIPTION:
107 *
108 *  This function returns TRUE if the state is equal to the
109 *  "before multitasking" state, and FALSE otherwise.
110 */
111
112STATIC INLINE boolean _System_state_Is_before_multitasking (
113  System_state_Codes state
114);
115
116/*
117 *  _System_state_Is_begin_multitasking
118 *
119 *  DESCRIPTION:
120 *
121 *  This function returns TRUE if the state is equal to the
122 *  "begin multitasking" state, and FALSE otherwise.
123 */
124
125STATIC INLINE boolean _System_state_Is_begin_multitasking (
126  System_state_Codes state
127);
128
129/*
130 *  _System_state_Is_up
131 *
132 *  DESCRIPTION:
133 *
134 *  This function returns TRUE if the state is equal to the
135 *  "up" state, and FALSE otherwise.
136 */
137
138STATIC INLINE boolean _System_state_Is_up (
139  System_state_Codes state
140);
141
142/*
143 *  _System_state_Is_failed
144 *
145 *  DESCRIPTION:
146 *
147 *  This function returns TRUE if the state is equal to the
148 *  "failed" state, and FALSE otherwise.
149 */
150
151STATIC INLINE boolean _System_state_Is_failed (
152  System_state_Codes state
153);
154
155#include <rtems/sysstate.inl>
156
157#ifdef __cplusplus
158}
159#endif
160
161#endif
162/* end of include file */
Note: See TracBrowser for help on using the repository browser.