source: rtems/c/src/exec/sapi/headers/extension.h @ 03f2154e

4.104.114.84.95
Last change on this file since 03f2154e was 03f2154e, checked in by Joel Sherrill <joel.sherrill@…>, on Apr 22, 1997 at 5:20:27 PM

headers updated to reflect new style copyright notice as part
of switching to the modified GNU GPL.

  • Property mode set to 100644
File size: 3.5 KB
Line 
1/*  extension.h
2 *
3 *  This include file contains all the constants, structures, and
4 *  prototypes associated with the User Extension Manager.  This manager
5 *  provides a mechanism for manipulating sets of user-defined extensions.
6 *
7 *  Directives provided are:
8 *
9 *     + create user extension set
10 *     + get ID of user extension set
11 *     + delete user extension set
12 *
13 *  COPYRIGHT (c) 1989-1997.
14 *  On-Line Applications Research Corporation (OAR).
15 *  Copyright assigned to U.S. Government, 1994.
16 *
17 *  The license and distribution terms for this file may in
18 *  the file LICENSE in this distribution or at
19 *  http://www.OARcorp.com/rtems/license.html.
20 *
21 *  $Id$
22 */
23
24#ifndef __RTEMS_EXTENSION_MANAGER_h
25#define __RTEMS_EXTENSION_MANAGER_h
26
27#ifdef __cplusplus
28extern "C" {
29#endif
30
31#include <rtems/score/object.h>
32#include <rtems/score/userext.h>
33#include <rtems/rtems/status.h>  /* XXX */
34#include <rtems/rtems/types.h>  /* XXX */
35
36/*
37 *  Extension related types
38 */
39
40typedef User_extensions_routine                   rtems_extension;
41typedef User_extensions_thread_create_extension   rtems_task_create_extension;
42typedef User_extensions_thread_delete_extension   rtems_task_delete_extension;
43typedef User_extensions_thread_start_extension    rtems_task_start_extension;
44typedef User_extensions_thread_restart_extension  rtems_task_restart_extension;
45typedef User_extensions_thread_switch_extension   rtems_task_switch_extension;
46typedef User_extensions_thread_begin_extension    rtems_task_begin_extension;
47typedef User_extensions_thread_exitted_extension  rtems_task_exitted_extension;
48typedef User_extensions_fatal_extension           rtems_fatal_extension;
49
50typedef User_extensions_Table                     rtems_extensions_table;
51
52/*
53 *  The following defines the information control block used to manage
54 *  this class of objects.
55 */
56
57SAPI_EXTERN Objects_Information  _Extension_Information;
58
59/*
60 *  The following records define the control block used to manage
61 *  each extension.
62 */
63
64typedef struct {
65  Objects_Control          Object;
66  User_extensions_Control  Extension;
67}   Extension_Control;
68
69/*
70 *  _Extension_Manager_initialization
71 *
72 *  DESCRIPTION:
73 *
74 *  This routine performs the initialization necessary for this manager.
75 */
76
77void _Extension_Manager_initialization(
78  unsigned32 maximum_extensions
79);
80
81/*
82 *  rtems_extension_create
83 *
84 *  DESCRIPTION:
85 *
86 *  This routine implements the rtems_extension_create directive.  The
87 *  extension will have the name name.   The entry points of the
88 *  routines which constitute this extension set are in EXTENSION_TABLE.
89 *  It returns the id of the created extension in ID.
90 */
91
92rtems_status_code rtems_extension_create(
93  rtems_name              name,
94  rtems_extensions_table *extension_table,
95  Objects_Id              *id
96);
97
98/*
99 *  rtems_extension_ident
100 *
101 *  DESCRIPTION:
102 *
103 *  This routine implements the rtems_extension_ident directive.
104 *  This directive returns the extension ID associated with name.
105 *  If more than one extension is named name, then the extension
106 *  to which the ID belongs is arbitrary.
107 */
108
109rtems_status_code rtems_extension_ident(
110  rtems_name    name,
111  Objects_Id   *id
112);
113
114/*
115 *  rtems_extension_delete
116 *
117 *  DESCRIPTION:
118 *
119 *  This routine implements the rtems_extension_delete directive.  The
120 *  extension indicated by ID is deleted.
121 */
122
123rtems_status_code rtems_extension_delete(
124  Objects_Id id
125);
126
127#ifndef __RTEMS_APPLICATION__
128#include <rtems/extension.inl>
129#endif
130
131#ifdef __cplusplus
132}
133#endif
134
135#endif
136/* end of include file */
Note: See TracBrowser for help on using the repository browser.