source: rtems/cpukit/score/macros/rtems/score/watchdog.inl @ 3a4ae6c

4.104.114.84.95
Last change on this file since 3a4ae6c was 3a4ae6c, checked in by Joel Sherrill <joel.sherrill@…>, on Sep 11, 1995 at 7:35:39 PM

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.2 KB
Line 
1/*  watchdog.inl
2 *
3 *  This file contains the macro implementation of all inlined routines
4 *  in the Watchdog Handler.
5 *
6 *  COPYRIGHT (c) 1989, 1990, 1991, 1992, 1993, 1994.
7 *  On-Line Applications Research Corporation (OAR).
8 *  All rights assigned to U.S. Government, 1994.
9 *
10 *  This material may be reproduced by or for the U.S. Government pursuant
11 *  to the copyright license under the clause at DFARS 252.227-7013.  This
12 *  notice must appear in all copies of this file and its derivatives.
13 *
14 *  $Id$
15 */
16
17#ifndef __WATCHDOG_inl
18#define __WATCHDOG_inl
19
20#include <rtems/core/object.h>
21
22/*PAGE
23 *
24 *  _Watchdog_Initialize
25 *
26 */
27
28#define _Watchdog_Initialize( _the_watchdog, _routine, _id, _user_data )  \
29  { \
30    (_the_watchdog)->state     = WATCHDOG_INACTIVE; \
31    (_the_watchdog)->routine   = (_routine); \
32    (_the_watchdog)->id        = (_id); \
33    (_the_watchdog)->user_data = (_user_data); \
34  }
35
36/*PAGE
37 *
38 *  _Watchdog_Is_active
39 *
40 */
41
42#define _Watchdog_Is_active( _the_watchdog ) \
43  ( (_the_watchdog)->state == WATCHDOG_ACTIVE )
44
45/*PAGE
46 *
47 *  _Watchdog_Activate
48 *
49 */
50
51#define _Watchdog_Activate( _the_watchdog ) \
52  (_the_watchdog)->state = WATCHDOG_ACTIVE
53
54/*PAGE
55 *
56 *  _Watchdog_Deactivate
57 *
58 */
59
60#define _Watchdog_Deactivate( _the_watchdog ) \
61  (_the_watchdog)->state = WATCHDOG_REMOVE_IT
62
63/*PAGE
64 *
65 *  _Watchdog_Tickle_ticks
66 *
67 */
68
69#define _Watchdog_Tickle_ticks() \
70  _Watchdog_Tickle( &_Watchdog_Ticks_chain )
71
72/*PAGE
73 *
74 *  _Watchdog_Tickle_seconds
75 *
76 */
77
78#define _Watchdog_Tickle_seconds() \
79  _Watchdog_Tickle( &_Watchdog_Seconds_chain )
80
81/*PAGE
82 *
83 *  _Watchdog_Insert_ticks
84 *
85 */
86
87#define _Watchdog_Insert_ticks( _the_watchdog, _units, _insert_mode ) \
88  { \
89    (_the_watchdog)->initial = (_units); \
90    _Watchdog_Insert( &_Watchdog_Ticks_chain, \
91                        (_the_watchdog), (_insert_mode) ); \
92  }
93
94/*PAGE
95 *
96 *  _Watchdog_Insert_seconds
97 *
98 */
99
100#define _Watchdog_Insert_seconds( _the_watchdog, _units, _insert_mode ) \
101  { \
102    (_the_watchdog)->initial = (_units); \
103    _Watchdog_Insert( &_Watchdog_Seconds_chain, \
104                        (_the_watchdog), (_insert_mode) ); \
105  }
106
107/*PAGE
108 *
109 *  _Watchdog_Adjust_seconds
110 *
111 */
112
113#define _Watchdog_Adjust_seconds( _direction, _units ) \
114  _Watchdog_Adjust( &_Watchdog_Seconds_chain, (_direction), (_units) )
115
116/*PAGE
117 *
118 *  _Watchdog_Adjust_ticks
119 *
120 */
121
122#define _Watchdog_Adjust_ticks( _direction, _units ) \
123  _Watchdog_Adjust( &_Watchdog_Ticks_chain, (_direction), (_units) )
124
125/*PAGE
126 *
127 *  _Watchdog_Reset
128 *
129 */
130
131#define _Watchdog_Reset( _the_watchdog ) \
132   { \
133     (void) _Watchdog_Remove( (_the_watchdog) ); \
134     _Watchdog_Insert( &_Watchdog_Ticks_chain, \
135                         (_the_watchdog), WATCHDOG_ACTIVATE_NOW ); \
136   }
137
138/*PAGE
139 *
140 *  _Watchdog_Next
141 *
142 */
143
144#define _Watchdog_Next( _watchdog ) \
145  ((Watchdog_Control *) (_watchdog)->Node.next)
146
147/*PAGE
148 *
149 *  _Watchdog_Previous
150 *
151 */
152
153#define _Watchdog_Previous( _watchdog ) \
154  ((Watchdog_Control *) (_watchdog)->Node.previous)
155
156/*PAGE
157 *
158 *  _Watchdog_First
159 *
160 */
161
162#define _Watchdog_First( _header ) \
163  ((Watchdog_Control *) (_header)->first)
164
165/*PAGE
166 *
167 *  _Watchdog_Last
168 *
169 */
170
171#define _Watchdog_Last( _header ) \
172  ((Watchdog_Control *) (_header)->last)
173
174#endif
175/* end of include file */
Note: See TracBrowser for help on using the repository browser.