source: rtems/c/src/exec/score/headers/system.h @ 503dc058

4.104.114.84.95
Last change on this file since 503dc058 was 503dc058, checked in by Joel Sherrill <joel.sherrill@…>, on Jul 3, 1996 at 2:20:03 PM

switched from "STATIC INLINE" to "RTEMS_INLINE_ROUTINE"

  • Property mode set to 100644
File size: 3.4 KB
Line 
1/*  system.h
2 *
3 *  This include file contains information that is included in every
4 *  function in the executive.  This must be the first include file
5 *  included in all internal RTEMS files.
6 *
7 *  COPYRIGHT (c) 1989, 1990, 1991, 1992, 1993, 1994.
8 *  On-Line Applications Research Corporation (OAR).
9 *  All rights assigned to U.S. Government, 1994.
10 *
11 *  This material may be reproduced by or for the U.S. Government pursuant
12 *  to the copyright license under the clause at DFARS 252.227-7013.  This
13 *  notice must appear in all copies of this file and its derivatives.
14 *
15 *  $Id$
16 */
17
18#ifndef __RTEMS_SYSTEM_h
19#define __RTEMS_SYSTEM_h
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
25/*
26 *  The following define the CPU Family and Model within the family
27 *
28 *  NOTE: The string "REPLACE_THIS_WITH_USE_INLINE_OR_MACROS" is replaced
29 *        with either "USE_INLINES" or "USE_MACROS" based upon the
30 *        whether this target configuration uses the inline or
31 *        macro implementations of the inlined RTEMS routines.
32 */
33 
34
35#define REPLACE_THIS_WITH_USE_INLINE_OR_MACROS
36
37/*
38 *  The following insures that all data is declared in the space
39 *  of the initialization routine for either the Initialization Manager
40 *  or the initialization file for the appropriate API.  It is
41 *  referenced as "external" in every other file.
42 */
43
44#ifdef SCORE_INIT
45#undef  SCORE_EXTERN
46#define SCORE_EXTERN
47#else
48#undef  SCORE_EXTERN
49#define SCORE_EXTERN  extern
50#endif
51
52#ifdef SAPI_INIT
53#undef  SAPI_EXTERN
54#define SAPI_EXTERN
55#else
56#undef  SAPI_EXTERN
57#define SAPI_EXTERN  extern
58#endif
59
60#ifdef RTEMS_API_INIT
61#undef  RTEMS_EXTERN
62#define RTEMS_EXTERN
63#else
64#undef  RTEMS_EXTERN
65#define RTEMS_EXTERN  extern
66#endif
67
68#ifdef POSIX_API_INIT
69#undef  POSIX_EXTERN
70#define POSIX_EXTERN
71#else
72#undef  POSIX_EXTERN
73#define POSIX_EXTERN  extern
74#endif
75
76/*
77 *  The following (in conjunction with compiler arguments) are used
78 *  to choose between the use of static inline functions and macro
79 *  functions.   The static inline implementation allows better
80 *  type checking with no cost in code size or execution speed.
81 */
82
83#ifdef USE_INLINES
84# ifdef __GNUC__
85#  define RTEMS_INLINE_ROUTINE static __inline__
86# else
87#  define RTEMS_INLINE_ROUTINE static inline
88# endif
89#else
90# define RTEMS_INLINE_ROUTINE
91#endif
92
93/*
94 *  Include a base set of files.
95 */
96
97/*
98 * XXX: Eventually proc_ptr needs to disappear!!!
99 */
100
101typedef void * proc_ptr;
102
103#include <rtems/score/cpu.h>        /* processor specific information */
104
105/*
106 *  Define NULL
107 */
108
109#ifndef NULL
110#define NULL      0          /* NULL value */
111#endif
112
113/*
114 *  Boolean constants
115 */
116
117#if !defined( TRUE ) || (TRUE != 1)
118#undef TRUE
119#define TRUE     (1)
120#endif
121
122#if !defined( FALSE ) || (FALSE != 0)
123#undef FALSE
124#define FALSE     (0)
125#endif
126
127#define stringify( _x ) # _x
128
129#define RTEMS_offsetof(type, field) \
130        ((unsigned32) &(((type *) 0)->field))
131
132/*
133 *  The following is the extern for the RTEMS version string.
134 *  The contents of this string are CPU specific.
135 */
136
137extern const char _RTEMS_version[];         /* RTEMS version string */
138extern const char _Copyright_Notice[];      /* RTEMS copyright string */
139
140/*
141 *  The following defines the CPU dependent information table.
142 */
143
144SCORE_EXTERN rtems_cpu_table _CPU_Table;               /* CPU dependent info */
145
146/*
147 *  XXX weird RTEMS stuff
148 */
149
150#define RTEMS_MAXIMUM_NAME_LENGTH 4
151
152#ifdef __cplusplus
153}
154#endif
155
156#endif
157/* end of include file */
Note: See TracBrowser for help on using the repository browser.