source: rtems/c/src/ada/rtems.ads @ 4c3340c

4.104.114.84.95
Last change on this file since 4c3340c was 4c3340c, checked in by Joel Sherrill <joel.sherrill@…>, on 06/03/97 at 15:22:09

Added Pending_Events and lined up other event constants

  • Property mode set to 100644
File size: 43.1 KB
RevLine 
[f3f06f79]1--
2--  RTEMS / Specification
3--
4--  DESCRIPTION:
5--
6--  This package provides the interface to the RTEMS API.
7--
8--  DEPENDENCIES:
9--
10--
11--
[d348ad96]12--  COPYRIGHT (c) 1997.
[f3f06f79]13--  On-Line Applications Research Corporation (OAR).
14--
[d348ad96]15--  The license and distribution terms for this file may in
16--  the file LICENSE in this distribution or at
17--  http://www.OARcorp.com/rtems/license.html.
18--
19--  $Id$
20--
[f3f06f79]21
22with System;
[a6b44a8a]23with System.Storage_Elements; use System.Storage_Elements;
[f3f06f79]24with Interfaces;
25with Interfaces.C;
26
27package RTEMS is
28
[d348ad96]29   Structure_Alignment : constant := 8;
[a6b44a8a]30
[f3f06f79]31   --
32   --  RTEMS Base Types
33   --
34
35   subtype Unsigned8  is Interfaces.Unsigned_8;
36   subtype Unsigned16 is Interfaces.Unsigned_16;
37   subtype Unsigned32 is Interfaces.Unsigned_32;
38
39   type Unsigned32_Pointer     is access all RTEMS.Unsigned32;
40   type Unsigned16_Pointer     is access all RTEMS.Unsigned16;
41   type Unsigned8_Pointer      is access all RTEMS.Unsigned8;
42
43   subtype Boolean             is RTEMS.Unsigned32;
44   subtype Address             is System.Address;
45   subtype Single              is Interfaces.C.C_float;
46   subtype Double              is Interfaces.C.Double;
47
48   --
49   --  The following define the size of each of the base types in
50   --  both bits and system units.
51   --
52
53   Unsigned8_Bits   : constant := 7;
54   Unsigned16_Bits  : constant := 15;
55   Unsigned32_Bits  : constant := 31;
56   Boolean_Bits     : constant := 31;
57   Address_Bits     : constant := 31;
58   Single_Bits      : constant := 31;
59   Double_Bits      : constant := 63;
60
61   Unsigned8_Units  : constant := 1;
62   Unsigned16_Units : constant := 2;
63   Unsigned32_Units : constant := 4;
64   Boolean_Units    : constant := 4;
65   Address_Units    : constant := 4;
66   Single_Units     : constant := 4;
67   Double_Units     : constant := 8;
68
[a6b44a8a]69   Null_Address     : constant RTEMS.Address :=
70      System.Storage_Elements.To_Address(0);
71
[f3f06f79]72   --  More Types
73   --
74
75   subtype Name                is RTEMS.Unsigned32;
76   subtype ID                  is RTEMS.Unsigned32;
77   subtype Interval            is RTEMS.Unsigned32;
78   subtype Attribute           is RTEMS.Unsigned32;
79   subtype Mode                is RTEMS.Unsigned32;
80   subtype Option              is RTEMS.Unsigned32;
81   subtype Task_Priority       is RTEMS.Unsigned32;
[d348ad96]82   subtype Notepad_Index       is RTEMS.Unsigned32 range 0 .. 15;
[f3f06f79]83
84   subtype Event_Set           is RTEMS.Unsigned32;
85   subtype Signal_Set          is RTEMS.Unsigned32;
86   subtype Debug_Set           is RTEMS.Unsigned32;
87   subtype Device_Major_Number is RTEMS.Unsigned32;
88   subtype Device_Minor_Number is RTEMS.Unsigned32;
89   subtype Vector_Number       is RTEMS.Unsigned32;
90   subtype ISR_Level           is RTEMS.Unsigned32;
91
92   subtype Node                is RTEMS.Unsigned32;
93
94   --
95   --  Task Related Types
96   --  XXXX fix this
97   subtype Task_Argument       is RTEMS.Unsigned32;
98   type Task_Argument_PTR      is access all Task_Argument;
99
100   -- XXXX fix this
101   subtype TCB                 is RTEMS.Unsigned32;
102   type    TCB_Pointer         is access all RTEMS.TCB;
103
104   subtype Task_States         is RTEMS.Unsigned32;
105
106   type Task_Entry is access procedure (
107      Argument : RTEMS.Unsigned32
108   );
109
110   --
111   --  Clock and Time of Day Types
112   --
113
114   type Time_Of_Day is
115      record
116         Year    : RTEMS.Unsigned32; -- year, A.D.
117         Month   : RTEMS.Unsigned32; -- month, 1 .. 12
118         Day     : RTEMS.Unsigned32; -- day, 1 .. 31
119         Hour    : RTEMS.Unsigned32; -- hour, 0 .. 23
120         Minute  : RTEMS.Unsigned32; -- minute, 0 .. 59
121         Second  : RTEMS.Unsigned32; -- second, 0 .. 59
122         Ticks   : RTEMS.Unsigned32; -- elapsed ticks between seconds
123      end record;
124
125   type Clock_Time_Value is
126      record
127         Seconds      : RTEMS.Unsigned32;
128         Microseconds : RTEMS.Unsigned32;
129      end record;
130
131   type Clock_Get_Options is (
132      Clock_Get_TOD,
133      Clock_Get_Seconds_Since_Epoch,
134      Clock_Get_Ticks_Since_Boot,
135      Clock_Get_Ticks_Per_Seconds,
136      Clock_Get_Time_Value
137   );
138
139   --
140   --  Device Driver Entry Prototype
141   --
142
143   type Device_Driver_Entry is access function (
144      Major    : in     RTEMS.Device_Major_Number;
145      Minor    : in     RTEMS.Device_Major_Number;
146      Argument : in     RTEMS.Unsigned32;
147      ID       : in     RTEMS.Unsigned32
148   ) return RTEMS.Unsigned32;
149
150   type Driver_Address_Table_Entry is
151      record
152         Initialization : RTEMS.Device_Driver_Entry;
153         Open           : RTEMS.Device_Driver_Entry;
154         Close          : RTEMS.Device_Driver_Entry;
155         Read           : RTEMS.Device_Driver_Entry;
156         Write          : RTEMS.Device_Driver_Entry;
157         Control        : RTEMS.Device_Driver_Entry;
158      end record;
159
160   type Driver_Address_Table is array ( RTEMS.Unsigned32
161     range 1 .. RTEMS.Unsigned32'Last ) of RTEMS.Driver_Address_Table_Entry;
162
163   type Driver_Address_Table_Pointer is access all Driver_Address_Table;
164
165   type Driver_Name_t is
166      record
167         Device_Name        : RTEMS.Address;
168         Device_Name_Length : RTEMS.Unsigned32;
169         Major              : RTEMS.Device_Major_Number;
170         Minor              : RTEMS.Device_Minor_Number;
[d766b7fd]171
[f3f06f79]172      end record;
173
174   --
175   --  Ident Options
176   --
177
178   Search_All_Nodes : constant RTEMS.Node := 0;
179
180   --
181   --  Options
182   --
183
184   Default_Options    : constant RTEMS.Option    := 16#0000#;
185
186   Wait      : constant RTEMS.Option := 16#0000#;
187   No_Wait   : constant RTEMS.Option := 16#0001#;
188
189   Event_All : constant RTEMS.Option := 16#0000#;
190   Event_Any : constant RTEMS.Option := 16#0002#;
191
192   --
193   --  Mode constants
194   --
195
196   Default_Modes      : constant RTEMS.Mode      := 16#0000#;
197
[d766b7fd]198   All_Mode_Masks     : constant RTEMS.Mode := 16#0000_ffff#;
199   Current_Mode       : constant RTEMS.Mode := 16#0000_0000#;
200   Preempt_Mask       : constant RTEMS.Mode := 16#0000_0100#;
201   Timeslice_Mask     : constant RTEMS.Mode := 16#0000_0200#;
202   ASR_Mask           : constant RTEMS.Mode := 16#0000_0400#;
[7e3dcbc]203   Interrupt_Mask     : RTEMS.Mode;
[d766b7fd]204   Preempt            : constant RTEMS.Mode := 16#0000_0000#;
205   No_Preempt         : constant RTEMS.Mode := 16#0000_0100#;
206   No_Timeslice       : constant RTEMS.Mode := 16#0000_0000#;
207   Timeslice          : constant RTEMS.Mode := 16#0000_0200#;
208   ASR                : constant RTEMS.Mode := 16#0000_0000#;
209   No_ASR             : constant RTEMS.Mode := 16#0000_0400#;
210
[7e3dcbc]211   pragma Import (C, Interrupt_Mask, "rtems_interrupt_mask");
212
[f3f06f79]213   --
214   --  Attribute constants
215   --
216
[a6b44a8a]217   Default_Attributes  : constant RTEMS.Attribute := 16#00000000#;
218   No_Floating_Point   : constant RTEMS.Attribute := 16#00000000#;
219   Floating_Point      : constant RTEMS.Attribute := 16#00000001#;
220   Local               : constant RTEMS.Attribute := 16#00000000#;
221   Global              : constant RTEMS.Attribute := 16#00000002#;
222   FIFO                : constant RTEMS.Attribute := 16#00000000#;
223   Priority            : constant RTEMS.Attribute := 16#00000004#;
224   Counting_Semaphore  : constant RTEMS.Attribute := 16#00000000#;
225   Binary_Semaphore    : constant RTEMS.Attribute := 16#00000010#;
226   No_Inherit_Priority : constant RTEMS.Attribute := 16#00000000#;
227   Inherit_Priority    : constant RTEMS.Attribute := 16#00000020#;
228   No_Priority_Ceiling : constant RTEMS.Attribute := 16#00000000#;
229   Priority_Ceiling    : constant RTEMS.Attribute := 16#00000040#;
[f3f06f79]230
231   function Interrupt_Level (
232      Level : in     RTEMS.Unsigned32
233   ) return RTEMS.Attribute;
[7e3dcbc]234   pragma Import (C, Interrupt_Level, "rtems_interrupt_level_attribute");
235   
[d766b7fd]236
237   Minimum_Stack_Size : RTEMS.Unsigned32;
238   pragma Import (C, Minimum_Stack_Size, "rtems_minimum_stack_size");
239
240
[f3f06f79]241   --
242   --  Notepad index constants
243   --
244
245   Notepad_0  : constant RTEMS.Unsigned32 := 0;
246   Notepad_1  : constant RTEMS.Unsigned32 := 1;
247   Notepad_2  : constant RTEMS.Unsigned32 := 2;
248   Notepad_3  : constant RTEMS.Unsigned32 := 3;
249   Notepad_4  : constant RTEMS.Unsigned32 := 4;
250   Notepad_5  : constant RTEMS.Unsigned32 := 5;
251   Notepad_6  : constant RTEMS.Unsigned32 := 6;
252   Notepad_7  : constant RTEMS.Unsigned32 := 7;
253   Notepad_8  : constant RTEMS.Unsigned32 := 8;
254   Notepad_9  : constant RTEMS.Unsigned32 := 9;
255   Notepad_10 : constant RTEMS.Unsigned32 := 10;
256   Notepad_11 : constant RTEMS.Unsigned32 := 11;
257   Notepad_12 : constant RTEMS.Unsigned32 := 12;
258   Notepad_13 : constant RTEMS.Unsigned32 := 13;
259   Notepad_14 : constant RTEMS.Unsigned32 := 14;
260   Notepad_15 : constant RTEMS.Unsigned32 := 15;
261
262   --
263   --  Miscellaneous
264   --
265
266   No_Timeout       : constant RTEMS.Interval := 0;
267   Self             : constant RTEMS.ID       := 0;
268   Period_Status    : constant RTEMS.Interval := 0;
269   Yield_Processor  : constant RTEMS.Interval := 0;
270   Current_Priority : constant RTEMS.Task_Priority := 0;
[d348ad96]271   No_Priority      : constant RTEMS.Task_Priority := 0;
[f3f06f79]272
273
274   --
275   --  Extension Callouts and Table
276   --
277
278   type Thread_Create_Extension is access procedure (
279      Current_Task : in     RTEMS.TCB_Pointer;
280      New_Task     : in     RTEMS.TCB_Pointer
281   );
282
283   type Thread_Start_Extension is access procedure (
284      Current_Task : in     RTEMS.TCB_Pointer;
285      Started_Task : in     RTEMS.TCB_Pointer
286   );
287
288   type Thread_Restart_Extension is access procedure (
289      Current_Task   : in     RTEMS.TCB_Pointer;
290      Restarted_Task : in     RTEMS.TCB_Pointer
291   );
292
293   type Thread_Delete_Extension is access procedure (
294      Current_Task : in     RTEMS.TCB_Pointer;
295      Deleted_Task : in     RTEMS.TCB_Pointer
296   );
297
298   type Thread_Switch_Extension is access procedure (
299      Current_Task : in     RTEMS.TCB_Pointer;
300      Heir_Task    : in     RTEMS.TCB_Pointer
301   );
302
303   type Thread_Post_Switch_Extension is access procedure (
304      Current_Task : in     RTEMS.TCB_Pointer
305   );
306
307   type Thread_Begin_Extension is access procedure (
308      Current_Task : in     RTEMS.TCB_Pointer
309   );
310
311   type Thread_Exitted_Extension is access procedure (
312      Current_Task : in     RTEMS.TCB_Pointer
313   );
314
315   type Fatal_Error_Extension is access procedure (
316      Error : in     RTEMS.Unsigned32
317   );
318
[7e3dcbc]319   type Extensions_Table is
[f3f06f79]320      record
321         Thread_Create      : RTEMS.Thread_Create_Extension;
322         Thread_Start       : RTEMS.Thread_Start_Extension;
323         Thread_Restart     : RTEMS.Thread_Restart_Extension;
324         Thread_Delete      : RTEMS.Thread_Delete_Extension;
325         Thread_Switch      : RTEMS.Thread_Switch_Extension;
326         Thread_Post_Switch : RTEMS.Thread_Post_Switch_Extension;
327         Thread_Begin       : RTEMS.Thread_Begin_Extension;
328         Thread_Exitted     : RTEMS.Thread_Exitted_Extension;
329         Fatal              : RTEMS.Fatal_Error_Extension;
330      end record;
331
332   type Extensions_Table_Pointer is access all Extensions_Table;
333
334   --
335   --  The following type define a pointer to a watchdog/timer service routine.
336   --
337
338   type Timer_Service_Routine is access procedure (
339      ID          : in     RTEMS.ID;
340      User_Data   : in     RTEMS.Address
341   );
342
343   --
344   --  The following type define a pointer to a signal service routine.
345   --
346
347   type ASR_Handler is access procedure (
348      Signals : in     RTEMS.Signal_Set
349   );
350
351   --
352   --  The following type defines the status information returned
353   --  about a period.
354   --
355
356   type Rate_Monotonic_Period_States is (
357     Inactive,               -- off chain, never initialized
358     Owner_Is_Blocking,      -- on chain, owner is blocking on it
359     Active,                 -- on chain, running continuously
360     Expired_While_Blocking, -- on chain, expired while owner was was blocking
361     Expired                 -- off chain, will be reset by next
362                             --   rtems_rate_monotonic_period
363   );
364
365   for Rate_Monotonic_Period_States'Size use 32;
366
367   for Rate_Monotonic_Period_States use (
368     Inactive                => 0,
369     Owner_Is_Blocking       => 1,
370     Active                  => 2,
371     Expired_While_Blocking  => 3,
372     Expired                 => 4
373   );
[d766b7fd]374
[f3f06f79]375   type Rate_Monotonic_Period_Status is
376      record
377         State                            : RTEMS.Rate_Monotonic_Period_States;
378         Ticks_Since_Last_Period          : RTEMS.Unsigned32;
379         Ticks_Executed_Since_Last_Period : RTEMS.Unsigned32;
380      end record;
381
382   --
383   --  Method Completions Status Codes
384   --
385
386   type Status_Codes is (
387      Successful,               -- successful completion
388      Task_Exitted,             -- returned from a task
389      MP_Not_Configured,        -- multiprocessing not configured
390      Invalid_Name,             -- invalid object name
391      Invalid_ID,               -- invalid object id
392      Too_Many,                 -- too many
393      Timeout,                  -- timed out waiting
394      Object_Was_Deleted,       -- object deleted while waiting
395      Invalid_Size,             -- specified size was invalid
396      Invalid_Address,          -- address specified is invalid
397      Invalid_Number,           -- number was invalid
398      Not_Defined,              -- item has not been initialized
399      Resource_In_Use,          -- resources still outstanding
400      Unsatisfied,              -- request not satisfied
401      Incorrect_State,          -- task is in wrong state
402      Already_Suspended,        -- task already in state
403      Illegal_On_Self,          -- illegal on calling task
404      Illegal_On_Remote_Object, -- illegal for remote object
405      Called_From_ISR,          -- called from wrong environment
406      Invalid_Priority,         -- invalid task priority
407      Invalid_Clock,            -- invalid date/time
408      Invalid_Node,             -- invalid node id
409      Not_Configured,           -- directive not configured
410      Not_Owner_Of_Resource,    -- not owner of resource
411      Not_Implemented,          -- directive not implemented
412      Internal_Error,           -- RTEMS inconsistency detected
413      Proxy_Blocking,           -- internal multiprocessing only
414      No_Memory                 -- no memory left in heap
415   );
416
417   for Status_Codes'Size use 32;
418
419   for Status_Codes use (
420      Successful                  =>  0,
421      Task_Exitted                =>  1,
422      MP_Not_Configured           =>  2,
423      Invalid_Name                =>  3,
424      Invalid_ID                  =>  4,
425      Too_Many                    =>  5,
426      Timeout                     =>  6,
427      Object_Was_Deleted          =>  7,
428      Invalid_Size                =>  8,
429      Invalid_Address             =>  9,
430      Invalid_NumbeR              => 10,
431      Not_Defined                 => 11,
432      Resource_In_Use             => 12,
433      Unsatisfied                 => 13,
434      Incorrect_State             => 14,
435      Already_Suspended           => 15,
436      Illegal_On_Self             => 16,
437      Illegal_On_Remote_Object    => 17,
438      Called_From_ISR             => 18,
439      Invalid_Priority            => 19,
440      Invalid_Clock               => 20,
441      Invalid_Node                => 21,
442      Not_Configured              => 22,
443      Not_Owner_Of_Resource       => 23,
444      Not_ImplementeD             => 24,
445      Internal_Error              => 25,
446      Proxy_Blocking              => 26,
447      No_Memory                   => 27
448   );
449
450   --
451   --  RTEMS Events
452   --
453
[4c3340c]454   Pending_Events : constant RTEMS.Event_Set := 16#0000_0000#;
455   All_Events     : constant RTEMS.Event_Set := 16#FFFF_FFFF#;
456   Event_0        : constant RTEMS.Event_Set := 16#0000_0001#;
457   Event_1        : constant RTEMS.Event_Set := 16#0000_0002#;
458   Event_2        : constant RTEMS.Event_Set := 16#0000_0004#;
459   Event_3        : constant RTEMS.Event_Set := 16#0000_0008#;
460   Event_4        : constant RTEMS.Event_Set := 16#0000_0010#;
461   Event_5        : constant RTEMS.Event_Set := 16#0000_0020#;
462   Event_6        : constant RTEMS.Event_Set := 16#0000_0040#;
463   Event_7        : constant RTEMS.Event_Set := 16#0000_0080#;
464   Event_8        : constant RTEMS.Event_Set := 16#0000_0100#;
465   Event_9        : constant RTEMS.Event_Set := 16#0000_0200#;
466   Event_10       : constant RTEMS.Event_Set := 16#0000_0400#;
467   Event_11       : constant RTEMS.Event_Set := 16#0000_0800#;
468   Event_12       : constant RTEMS.Event_Set := 16#0000_1000#;
469   Event_13       : constant RTEMS.Event_Set := 16#0000_2000#;
470   Event_14       : constant RTEMS.Event_Set := 16#0000_4000#;
471   Event_15       : constant RTEMS.Event_Set := 16#0000_8000#;
472   Event_16       : constant RTEMS.Event_Set := 16#0001_0000#;
473   Event_17       : constant RTEMS.Event_Set := 16#0002_0000#;
474   Event_18       : constant RTEMS.Event_Set := 16#0004_0000#;
475   Event_19       : constant RTEMS.Event_Set := 16#0008_0000#;
476   Event_20       : constant RTEMS.Event_Set := 16#0010_0000#;
477   Event_21       : constant RTEMS.Event_Set := 16#0020_0000#;
478   Event_22       : constant RTEMS.Event_Set := 16#0040_0000#;
479   Event_23       : constant RTEMS.Event_Set := 16#0080_0000#;
480   Event_24       : constant RTEMS.Event_Set := 16#0100_0000#;
481   Event_25       : constant RTEMS.Event_Set := 16#0200_0000#;
482   Event_26       : constant RTEMS.Event_Set := 16#0400_0000#;
483   Event_27       : constant RTEMS.Event_Set := 16#0800_0000#;
484   Event_28       : constant RTEMS.Event_Set := 16#1000_0000#;
485   Event_29       : constant RTEMS.Event_Set := 16#2000_0000#;
486   Event_30       : constant RTEMS.Event_Set := 16#4000_0000#;
487   Event_31       : constant RTEMS.Event_Set := 16#8000_0000#;
[f3f06f79]488
[a6b44a8a]489   --
490   --  RTEMS Signals
491   --
492
493   All_Signals : constant RTEMS.Signal_Set := 16#7FFFFFFF#;
494   Signal_0    : constant RTEMS.Signal_Set := 16#00000001#;
495   Signal_1    : constant RTEMS.Signal_Set := 16#00000002#;
496   Signal_2    : constant RTEMS.Signal_Set := 16#00000004#;
497   Signal_3    : constant RTEMS.Signal_Set := 16#00000008#;
498   Signal_4    : constant RTEMS.Signal_Set := 16#00000010#;
499   Signal_5    : constant RTEMS.Signal_Set := 16#00000020#;
500   Signal_6    : constant RTEMS.Signal_Set := 16#00000040#;
501   Signal_7    : constant RTEMS.Signal_Set := 16#00000080#;
502   Signal_8    : constant RTEMS.Signal_Set := 16#00000100#;
503   Signal_9    : constant RTEMS.Signal_Set := 16#00000200#;
504   Signal_10   : constant RTEMS.Signal_Set := 16#00000400#;
505   Signal_11   : constant RTEMS.Signal_Set := 16#00000800#;
506   Signal_12   : constant RTEMS.Signal_Set := 16#00001000#;
507   Signal_13   : constant RTEMS.Signal_Set := 16#00002000#;
508   Signal_14   : constant RTEMS.Signal_Set := 16#00004000#;
509   Signal_15   : constant RTEMS.Signal_Set := 16#00008000#;
510   Signal_16   : constant RTEMS.Signal_Set := 16#00010000#;
511   Signal_17   : constant RTEMS.Signal_Set := 16#00020000#;
512   Signal_18   : constant RTEMS.Signal_Set := 16#00040000#;
513   Signal_19   : constant RTEMS.Signal_Set := 16#00080000#;
514   Signal_20   : constant RTEMS.Signal_Set := 16#00100000#;
515   Signal_21   : constant RTEMS.Signal_Set := 16#00200000#;
516   Signal_22   : constant RTEMS.Signal_Set := 16#00400000#;
517   Signal_23   : constant RTEMS.Signal_Set := 16#00800000#;
518   Signal_24   : constant RTEMS.Signal_Set := 16#01000000#;
519   Signal_25   : constant RTEMS.Signal_Set := 16#02000000#;
520   Signal_26   : constant RTEMS.Signal_Set := 16#04000000#;
521   Signal_27   : constant RTEMS.Signal_Set := 16#08000000#;
522   Signal_28   : constant RTEMS.Signal_Set := 16#10000000#;
523   Signal_29   : constant RTEMS.Signal_Set := 16#20000000#;
524   Signal_30   : constant RTEMS.Signal_Set := 16#40000000#;
525   Signal_31   : constant RTEMS.Signal_Set := 16#80000000#;
526
[f3f06f79]527   --
528   --  RTEMS API Configuration Information
529   --
530
531   type Initialization_Tasks_Table_Entry is
532      record
533         Name             : RTEMS.Name;          -- task name
534         Stack_Size       : RTEMS.Unsigned32;    -- task stack size
535         Initial_Priority : RTEMS.Task_priority; -- task priority
536         Attribute_Set    : RTEMS.Attribute;     -- task attributes
537         Entry_Point      : RTEMS.Task_Entry;    -- task entry point
538         Mode_Set         : RTEMS.Mode;          -- task initial mode
539         Argument         : RTEMS.Unsigned32;    -- task argument
540      end record;
541
542   type Initialization_Tasks_Table is array ( RTEMS.Unsigned32 range <> ) of
543     RTEMS.Initialization_Tasks_Table_Entry;
544
545   type Initialization_Tasks_Table_Pointer is access all
546        Initialization_Tasks_Table;
547
548   type API_Configuration_Table is
549      record
550         Maximum_Tasks                   : RTEMS.Unsigned32;
551         Maximum_Timers                  : RTEMS.Unsigned32;
552         Maximum_Semaphores              : RTEMS.Unsigned32;
553         Maximum_Message_queues          : RTEMS.Unsigned32;
554         Maximum_Partitions              : RTEMS.Unsigned32;
555         Maximum_Regions                 : RTEMS.Unsigned32;
556         Maximum_Ports                   : RTEMS.Unsigned32;
557         Maximum_Periods                 : RTEMS.Unsigned32;
558         Number_Of_Initialization_Tasks  : RTEMS.Unsigned32;
559         User_Initialization_Tasks_Table :
560                                   RTEMS.Initialization_Tasks_Table_Pointer;
561      end record;
562
563   type API_Configuration_Table_Pointer is access all API_Configuration_Table;
564
565   --
566   --  RTEMS POSIX API Configuration Information
567   --
568
569   type POSIX_Thread_Entry is access procedure (
570      Argument : in     RTEMS.Address
571   );
572
573   type POSIX_Initialization_Threads_Table_Entry is
574   record
575      Thread_Entry : RTEMS.POSIX_Thread_Entry;
576   end record;
577
578   type POSIX_Initialization_Threads_Table is array
579       ( RTEMS.Unsigned32 range <> ) of
580       RTEMS.POSIX_Initialization_Threads_Table_Entry;
581
582   type POSIX_Initialization_Threads_Table_Pointer is access all
583       POSIX_Initialization_Threads_Table;
[d766b7fd]584
[f3f06f79]585   type POSIX_API_Configuration_Table_Entry is
586      record
587         Maximum_Threads                 : Interfaces.C.Int;
588         Maximum_Mutexes                 : Interfaces.C.Int;
589         Maximum_Condition_Variables     : Interfaces.C.Int;
590         Maximum_Keys                    : Interfaces.C.Int;
591         Maximum_Queued_Signals          : Interfaces.C.Int;
592         Number_Of_Initialization_Tasks  : Interfaces.C.Int;
[d766b7fd]593         User_Initialization_Tasks_Table :
[f3f06f79]594            RTEMS.POSIX_Initialization_Threads_Table_Pointer;
595      end record;
596
597   type POSIX_API_Configuration_Table is array ( RTEMS.Unsigned32 range <> ) of
598      RTEMS.POSIX_API_Configuration_Table_Entry;
599
600   type POSIX_API_Configuration_Table_Pointer is access all
601          RTEMS.POSIX_API_Configuration_Table;
602
603   --
604   --  MPCI Information include MPCI Configuration
605   --
606
607   type Configuration_Table_Pointer;
608
609   type MP_Packet_Classes is (
610      MP_PACKET_MPCI_INTERNAL,
611      MP_PACKET_TASKS,
612      MP_PACKET_MESSAGE_QUEUE,
613      MP_PACKET_SEMAPHORE,
614      MP_PACKET_PARTITION,
615      MP_PACKET_REGION,
616      MP_PACKET_EVENT,
617      MP_PACKET_SIGNAL
618   );
619
620   for MP_Packet_Classes use (
621      MP_PACKET_MPCI_INTERNAL    => 0,
622      MP_PACKET_TASKS            => 1,
623      MP_PACKET_MESSAGE_QUEUE    => 2,
624      MP_PACKET_SEMAPHORE        => 3,
625      MP_PACKET_PARTITION        => 4,
626      MP_PACKET_REGION           => 5,
627      MP_PACKET_EVENT            => 6,
628      MP_PACKET_SIGNAL           => 7
629   );
630
631   type Packet_Prefix is
632      record
633         The_Class       : RTEMS.MP_Packet_Classes;
634         ID              : RTEMS.ID;
635         Source_TID      : RTEMS.ID;
636         Source_Priority : RTEMS.Task_Priority;
637         Return_Code     : RTEMS.Unsigned32;
638         Length          : RTEMS.Unsigned32;
639         To_Convert      : RTEMS.Unsigned32;
640         Timeout         : RTEMS.Interval;
641      end record;
642
643   type Packet_Prefix_Pointer is access all Packet_Prefix;
644
645   type MPCI_Initialization_Entry is access procedure (
646      Configuration : in     RTEMS.Configuration_Table_Pointer
647   );
648
649   type MPCI_Get_Packet_Entry is access procedure (
650      Packet : access RTEMS.Packet_Prefix_Pointer
651   );
652
653   type MPCI_Return_Packet_Entry is access procedure (
654      Packet : in     RTEMS.Packet_Prefix_Pointer
655   );
656
657   type MPCI_Send_Entry is access procedure (
658      Packet : in     RTEMS.Packet_Prefix_Pointer
659   );
660
661   type MPCI_Receive_Entry is access procedure (
662      Packet : access RTEMS.Packet_Prefix_Pointer
663   );
664
665   type MPCI_Table is
666      record
667         Default_Timeout     : RTEMS.Unsigned32; -- in ticks
668         Maximum_Packet_Size : RTEMS.Unsigned32;
669         Initialization      : RTEMS.MPCI_Initialization_Entry;
670         Get_Packet          : RTEMS.MPCI_Get_Packet_Entry;
671         Return_Packet       : RTEMS.MPCI_Return_Packet_Entry;
672         Send                : RTEMS.MPCI_Send_Entry;
673         Receive             : RTEMS.MPCI_Receive_Entry;
674      end record;
675
676   type MPCI_Table_Pointer is access all MPCI_Table;
677
678   --
679   --  Configuration Information
680   --
681
682   type Multiprocessing_Table is
683      record
684         Node                   : RTEMS.Unsigned32;
685         Maximum_Nodes          : RTEMS.Unsigned32;
686         Maximum_Global_Objects : RTEMS.Unsigned32;
687         Maximum_Proxies        : RTEMS.Unsigned32;
688         User_MPCI_Table        : RTEMS.MPCI_Table_Pointer;
689      end record;
690
691   type Multiprocessing_Table_Pointer is access all Multiprocessing_Table;
692
693   type Configuration_Table is
694      record
695          Work_Space_Start           : RTEMS.Address;
696          Work_Space_Size            : RTEMS.Unsigned32;
697          Maximum_Extensions         : RTEMS.Unsigned32;
698          Microseconds_Per_Tick      : RTEMS.Unsigned32;
699          Ticks_Per_Timeslice        : RTEMS.Unsigned32;
700          Maximum_Devices            : RTEMS.Unsigned32;
701          Number_Of_Device_Drivers   : RTEMS.Unsigned32;
702          Device_Driver_Table        : RTEMS.Driver_Address_Table_Pointer;
703          User_Extension_Table       : RTEMS.Extensions_Table_Pointer;
704          User_Multiprocessing_Table : RTEMS.Multiprocessing_Table_Pointer;
705          RTEMS_API_Configuration    : RTEMS.API_Configuration_Table_Pointer;
706          POSIX_API_Configuration    : RTEMS.POSIX_API_Configuration_Table_Pointer;
707      end record;
708
709   type Configuration_Table_Pointer is access all Configuration_Table;
710
711   --
712   --  For now, do not provide access to the CPU Table from Ada.
713   --  When this type is provided, a CPU dependent file must
714   --  define it.
715   --
716
717   subtype CPU_Table is RTEMS.Address;
718   type CPU_Table_Pointer is access all CPU_Table;
719
720   --
721   --  Utility Functions
722   --
723
724   function From_Ada_Boolean (
725      Ada_Boolean : Standard.Boolean
726   ) return RTEMS.Boolean;
727
728   function To_Ada_Boolean (
729      RTEMS_Boolean : RTEMS.Boolean
730   ) return Standard.Boolean;
731
732   function Milliseconds_To_Microseconds (
733      Milliseconds : RTEMS.Unsigned32
734   ) return RTEMS.Unsigned32;
735
736   function Milliseconds_To_Ticks (
737      Milliseconds : RTEMS.Unsigned32
738   ) return RTEMS.Interval;
739
740   function Microseconds_To_Ticks (
741      Microseconds : RTEMS.Unsigned32
742   ) return RTEMS.Interval;
743
744   function Build_Name (
745      C1 : in     Character;
746      C2 : in     Character;
747      C3 : in     Character;
748      C4 : in     Character
749   ) return RTEMS.Name;
750
751   procedure Name_To_Characters (
752      Name : in     RTEMS.Name;
753      C1   :    out Character;
754      C2   :    out Character;
755      C3   :    out Character;
756      C4   :    out Character
757   );
758
759   function Get_Node (
760      ID : in     RTEMS.ID
761   ) return RTEMS.Unsigned32;
762
763   function Get_Index (
764      ID : in     RTEMS.ID
765   ) return RTEMS.Unsigned32;
766
767   function Are_Statuses_Equal (
768      Status  : in     RTEMS.Status_Codes;
769      Desired : in     RTEMS.Status_Codes
770   ) return Standard.Boolean;
771
[a6b44a8a]772   function Is_Status_Successful (
773      Status  : in     RTEMS.Status_Codes
774   ) return Standard.Boolean;
775
[d348ad96]776   function Subtract (
777      Left   : in     RTEMS.Address;
778      Right  : in     RTEMS.Address
779   ) return RTEMS.Unsigned32;
780
[f3f06f79]781   --
782   --  RTEMS API
783   --
784
785   --
786   --  Initialization Manager
787   --
788
789   procedure Initialize_Executive (
790      Configuration_Table   : in     RTEMS.Configuration_Table_Pointer;
791      CPU_Table             : in     RTEMS.CPU_Table_Pointer
792   );
793
794   procedure Initialize_Executive_Early (
795      Configuration_Table : in     RTEMS.Configuration_Table_Pointer;
796      CPU_Table           : in     RTEMS.CPU_Table_Pointer;
797      Level               :    out RTEMS.ISR_Level
798   );
799
800   procedure Initialize_Executive_Late (
801      BSP_Level : in    RTEMS.ISR_Level
802   );
803
804   procedure Shutdown_Executive (
805      Result : in     RTEMS.Unsigned32
806   );
807
808   --
809   --  Task Manager
810   --
811
812   procedure Task_Create (
813      Name             : in     RTEMS.Name;
814      Initial_Priority : in     RTEMS.Task_Priority;
815      Stack_Size       : in     Unsigned32;
816      Initial_Modes    : in     RTEMS.Mode;
817      Attribute_Set    : in     RTEMS.Attribute;
818      ID               :    out RTEMS.ID;
819      Result           :    out RTEMS.Status_Codes
820   );
821
822   procedure Task_Ident (
823      Name   : in     RTEMS.Name;
824      Node   : in     RTEMS.Node;
825      ID     :    out RTEMS.ID;
826      Result :    out RTEMS.Status_Codes
827   );
828
829   procedure Task_Start (
830      ID          : in     RTEMS.ID;
831      Entry_Point : in     RTEMS.Task_Entry;
832      Argument    : in     RTEMS.Task_Argument;
833      Result      :    out RTEMS.Status_Codes
834   );
835
836   procedure Task_Restart (
837      ID       : in     RTEMS.ID;
838      Argument : in     RTEMS.Task_Argument;
839      Result   :    out RTEMS.Status_Codes
840   );
841
842   procedure Task_Delete (
843      ID     : in     RTEMS.ID;
844      Result :    out RTEMS.Status_Codes
845   );
846
847   procedure Task_Suspend (
848      ID     : in     RTEMS.ID;
849      Result :    out RTEMS.Status_Codes
850   );
851
852   procedure Task_Resume (
853      ID     : in     RTEMS.ID;
854      Result :    out RTEMS.Status_Codes
855   );
856
857   procedure Task_Set_Priority (
858      ID           : in     RTEMS.ID;
859      New_Priority : in     RTEMS.Task_Priority;
860      Old_Priority :    out RTEMS.Task_Priority;
861      Result       :    out RTEMS.Status_Codes
862   );
863
864   procedure Task_Mode (
865      Mode_Set          : in     RTEMS.Mode;
866      Mask              : in     RTEMS.Mode;
867      Previous_Mode_Set :    out RTEMS.Mode;
868      Result            :    out RTEMS.Status_Codes
869   );
870
871   procedure Task_Get_Note (
872      ID      : in     RTEMS.ID;
873      Notepad : in     RTEMS.Notepad_Index;
874      Note    :    out RTEMS.Unsigned32;
875      Result  :    out RTEMS.Status_Codes
876   );
877
878   procedure Task_Set_Note (
879      ID      : in     RTEMS.ID;
880      Notepad : in     RTEMS.Notepad_Index;
881      Note    : in     RTEMS.Unsigned32;
882      Result  :    out RTEMS.Status_Codes
883   );
884
885   procedure Task_Wake_When (
886      Time_Buffer : in     RTEMS.Time_Of_Day;
887      Result      :    out RTEMS.Status_Codes
888   );
889
890   procedure Task_Wake_After (
891      Ticks  : in     RTEMS.Interval;
892      Result :    out RTEMS.Status_Codes
893   );
894
895   --
896   --  Interrupt Manager
897   --
898
899   procedure Interrupt_Catch (
900      New_ISR_Handler : in     RTEMS.Address;
901      Vector          : in     RTEMS.Vector_Number;
902      Old_ISR_Handler :    out RTEMS.Address;
903      Result          :    out RTEMS.Status_Codes
904   );
905
906   function Interrupt_Disable
907   return RTEMS.ISR_Level;
908
909   procedure Interrupt_Enable (
910      Level : in     RTEMS.ISR_Level
911   );
912
913   procedure Interrupt_Flash (
914      Level : in     RTEMS.ISR_Level
915   );
916
917   function Interrupt_Is_In_Progress
918   return RTEMS.Boolean;
919
920   --
921   --  Clock Manager
922   --
923
924   procedure Clock_Get (
925      Option      : in     RTEMS.Clock_Get_Options;
926      Time_Buffer : in     RTEMS.Address;
927      Result      :    out RTEMS.Status_Codes
928   );
929
930   procedure Clock_Set (
931      Time_Buffer : in     RTEMS.Time_Of_Day;
932      Result      :    out RTEMS.Status_Codes
933   );
934
935   procedure Clock_Tick (
936      Result :    out RTEMS.Status_Codes
937   );
938
939   --
940   --  Extension Manager
941   --
942
943   procedure Extension_Create (
944      Name   : in     RTEMS.Name;
945      Table  : in     RTEMS.Extensions_Table_Pointer;
946      ID     :    out RTEMS.ID;
947      Result :    out RTEMS.Status_Codes
948   );
949
950   procedure Extension_Ident (
951      Name   : in     RTEMS.Name;
952      ID     :    out RTEMS.ID;
953      Result :    out RTEMS.Status_Codes
954   );
955
956   procedure Extension_Delete (
957      ID     : in     RTEMS.ID;
958      Result :    out RTEMS.Status_Codes
959   );
960
961
962   --
963   --  Timer Manager
964   --
965
966   procedure Timer_Create (
967      Name   : in     RTEMS.Name;
968      ID     :    out RTEMS.ID;
969      Result :    out RTEMS.Status_Codes
970   );
971
972   procedure Timer_Ident (
973      Name   : in     RTEMS.Name;
974      ID     :    out RTEMS.ID;
975      Result :    out RTEMS.Status_Codes
976   );
977
978   procedure Timer_Delete (
979      ID     : in     RTEMS.ID;
980      Result :    out RTEMS.Status_Codes
981   );
982
983   procedure Timer_Fire_After (
984      ID        : in     RTEMS.ID;
985      Ticks     : in     RTEMS.Interval;
986      Routine   : in     RTEMS.Timer_Service_Routine;
987      User_Data : in     RTEMS.Address;
988      Result    :    out RTEMS.Status_Codes
989   );
990
991   procedure Timer_Fire_When (
992      ID        : in     RTEMS.ID;
993      Wall_Time : in     RTEMS.Time_Of_Day;
994      Routine   : in     RTEMS.Timer_Service_Routine;
995      User_Data : in     RTEMS.Address;
996      Result    :    out RTEMS.Status_Codes
997   );
998
999   procedure Timer_Reset (
1000      ID     : in     RTEMS.ID;
1001      Result :    out RTEMS.Status_Codes
1002   );
1003
1004   procedure Timer_Cancel (
1005      ID     : in     RTEMS.ID;
1006      Result :    out RTEMS.Status_Codes
1007   );
1008
1009   --
1010   --  Semaphore Manager
1011   --
1012
1013   procedure Semaphore_Create (
[d348ad96]1014      Name             : in     RTEMS.Name;
1015      Count            : in     RTEMS.Unsigned32;
1016      Attribute_Set    : in     RTEMS.Attribute;
1017      Priority_Ceiling : in     RTEMS.Task_Priority;
1018      ID               :    out RTEMS.ID;
1019      Result           :    out RTEMS.Status_Codes
[f3f06f79]1020   );
1021
1022   procedure Semaphore_Delete (
1023      ID     : in     RTEMS.ID;
1024      Result :    out RTEMS.Status_Codes
1025   );
1026
1027   procedure Semaphore_Ident (
1028      Name   : in     RTEMS.Name;
1029      Node   : in     RTEMS.Unsigned32;
1030      ID     :    out RTEMS.ID;
1031      Result :    out RTEMS.Status_Codes
1032   );
1033
1034   procedure Semaphore_Obtain (
1035      ID         : in     RTEMS.ID;
1036      Option_Set : in     RTEMS.Option;
1037      Timeout    : in     RTEMS.Interval;
1038      Result     :    out RTEMS.Status_Codes
1039   );
1040
1041   procedure Semaphore_Release (
1042      ID     : in     RTEMS.ID;
1043      Result :    out RTEMS.Status_Codes
1044   );
1045
1046
1047   --
1048   --  Message Queue Manager
1049   --
1050
1051   procedure Message_Queue_Create (
1052      Name             : in     RTEMS.Name;
1053      Count            : in     RTEMS.Unsigned32;
1054      Max_Message_Size : in     RTEMS.Unsigned32;
1055      Attribute_Set    : in     RTEMS.Attribute;
1056      ID               :    out RTEMS.ID;
1057      Result           :    out RTEMS.Status_Codes
1058   );
1059
1060   procedure Message_Queue_Ident (
1061      Name   : in     RTEMS.Name;
1062      Node   : in     RTEMS.Unsigned32;
1063      ID     :    out RTEMS.ID;
1064      Result :    out RTEMS.Status_Codes
1065   );
1066
1067   procedure Message_Queue_Delete (
1068      ID     : in     RTEMS.ID;
1069      Result :    out RTEMS.Status_Codes
1070   );
1071
1072   procedure Message_Queue_Send (
1073      ID     : in     RTEMS.ID;
1074      Buffer : in     RTEMS.Address;
1075      Size   : in     RTEMS.Unsigned32;
1076      Result :    out RTEMS.Status_Codes
1077   );
1078
1079   procedure Message_Queue_Urgent (
1080      ID     : in     RTEMS.ID;
1081      Buffer : in     RTEMS.Address;
1082      Size   : in     RTEMS.Unsigned32;
1083      Result :    out RTEMS.Status_Codes
1084   );
1085
1086   procedure Message_Queue_Broadcast (
1087      ID     : in     RTEMS.ID;
1088      Buffer : in     RTEMS.Address;
1089      Size   : in     RTEMS.Unsigned32;
1090      Count  :    out RTEMS.Unsigned32;
1091      Result :    out RTEMS.Status_Codes
1092   );
1093
1094   procedure Message_Queue_Receive (
1095      ID         : in     RTEMS.ID;
1096      Buffer     : in     RTEMS.Address;
1097      Option_Set : in     RTEMS.Option;
1098      Timeout    : in     RTEMS.Interval;
1099      Size       :    out RTEMS.Unsigned32;
1100      Result     :    out RTEMS.Status_Codes
1101   );
1102
1103   procedure Message_Queue_Flush (
1104      ID     : in     RTEMS.ID;
1105      Count  :    out RTEMS.Unsigned32;
1106      Result :    out RTEMS.Status_Codes
1107   );
1108
1109
1110   --
1111   --  Event Manager
1112   --
1113
1114   procedure Event_Send (
1115      ID       : in     RTEMS.ID;
1116      Event_In : in     RTEMS.Event_Set;
1117      Result   :    out RTEMS.Status_Codes
1118   );
1119
1120   procedure Event_Receive (
1121      Event_In   : in     RTEMS.Event_Set;
1122      Option_Set : in     RTEMS.Option;
1123      Ticks      : in     RTEMS.Interval;
1124      Event_Out  :    out RTEMS.Event_Set;
1125      Result     :    out RTEMS.Status_Codes
1126   );
1127
1128   --
1129   --  Signal Manager
1130   --
1131
1132   procedure Signal_Catch (
1133      ASR_Handler : in     RTEMS.ASR_Handler;
1134      Mode_Set    : in     RTEMS.Mode;
1135      Result      :    out RTEMS.Status_Codes
1136   );
1137
1138   procedure Signal_Send (
1139      ID         : in     RTEMS.ID;
1140      Signal_Set : in     RTEMS.Signal_Set;
1141      Result     :    out RTEMS.Status_Codes
1142   );
1143
1144
1145   --
1146   --  Partition Manager
1147   --
1148
1149   procedure Partition_Create (
1150      Name             : in     RTEMS.Name;
1151      Starting_Address : in     RTEMS.Address;
1152      Length           : in     RTEMS.Unsigned32;
1153      Buffer_Size      : in     RTEMS.Unsigned32;
1154      Attribute_Set    : in     RTEMS.Attribute;
1155      ID               :    out RTEMS.ID;
1156      Result           :    out RTEMS.Status_Codes
1157   );
1158
1159   procedure Partition_Ident (
1160      Name   : in     RTEMS.Name;
1161      Node   : in     RTEMS.Unsigned32;
1162      ID     :    out RTEMS.ID;
1163      Result :    out RTEMS.Status_Codes
1164   );
1165
1166   procedure Partition_Delete (
1167      ID     : in     RTEMS.ID;
1168      Result :    out RTEMS.Status_Codes
1169   );
1170
1171   procedure Partition_Get_Buffer (
1172      ID     : in     RTEMS.ID;
1173      Buffer :    out RTEMS.Address;
1174      Result :    out RTEMS.Status_Codes
1175   );
1176
1177   procedure Partition_Return_Buffer (
1178      ID     : in     RTEMS.ID;
1179      Buffer : in     RTEMS.Address;
1180      Result :    out RTEMS.Status_Codes
1181   );
1182
1183
1184   --
1185   --  Region Manager
1186   --
1187
1188   procedure Region_Create (
1189      Name             : in     RTEMS.Name;
1190      Starting_Address : in     RTEMS.Address;
1191      Length           : in     RTEMS.Unsigned32;
1192      Page_Size        : in     RTEMS.Unsigned32;
1193      Attribute_Set    : in     RTEMS.Attribute;
1194      ID               :    out RTEMS.ID;
1195      Result           :    out RTEMS.Status_Codes
1196   );
1197
1198   procedure Region_Ident (
1199      Name   : in     RTEMS.Name;
1200      ID     :    out RTEMS.ID;
1201      Result :    out RTEMS.Status_Codes
1202   );
1203
1204   procedure Region_Delete (
1205      ID     : in     RTEMS.ID;
1206      Result :    out RTEMS.Status_Codes
1207   );
1208
1209   procedure Region_Extend (
1210      ID               : in     RTEMS.ID;
1211      Starting_Address : in     RTEMS.Address;
1212      Length           : in     RTEMS.Unsigned32;
1213      Result           :    out RTEMS.Status_Codes
1214   );
1215
1216   procedure Region_Get_Segment (
1217      ID         : in     RTEMS.ID;
1218      Size       : in     RTEMS.Unsigned32;
1219      Option_Set : in     RTEMS.Option;
1220      Timeout    : in     RTEMS.Interval;
1221      Segment    :    out RTEMS.Address;
1222      Result     :    out RTEMS.Status_Codes
1223   );
1224
1225   procedure Region_Get_Segment_Size (
1226      ID         : in     RTEMS.ID;
1227      Segment    : in     RTEMS.Address;
1228      Size       :    out RTEMS.Unsigned32;
1229      Result     :    out RTEMS.Status_Codes
1230   );
1231
1232   procedure Region_Return_Segment (
1233      ID      : in     RTEMS.ID;
1234      Segment : in     RTEMS.Address;
1235      Result  :    out RTEMS.Status_Codes
1236   );
1237
1238
1239   --
1240   --  Dual Ported Memory Manager
1241   --
1242
1243   procedure Port_Create (
1244      Name           : in     RTEMS.Name;
1245      Internal_Start : in     RTEMS.Address;
1246      External_Start : in     RTEMS.Address;
1247      Length         : in     RTEMS.Unsigned32;
1248      ID             :    out RTEMS.ID;
1249      Result         :    out RTEMS.Status_Codes
1250   );
1251
1252   procedure Port_Ident (
1253      Name   : in     RTEMS.Name;
1254      ID     :    out RTEMS.ID;
1255      Result :    out RTEMS.Status_Codes
1256   );
1257
1258   procedure Port_Delete (
1259      ID     : in     RTEMS.ID;
1260      Result :    out RTEMS.Status_Codes
1261   );
1262
1263   procedure Port_External_To_Internal (
1264      ID       : in     RTEMS.ID;
1265      External : in     RTEMS.Address;
1266      Internal :    out RTEMS.Address;
1267      Result   :    out RTEMS.Status_Codes
1268   );
1269
1270   procedure Port_Internal_To_External (
1271      ID       : in     RTEMS.ID;
1272      Internal : in     RTEMS.Address;
1273      External :    out RTEMS.Address;
1274      Result   :    out RTEMS.Status_Codes
1275   );
1276
1277   --
1278   --  Input/Output Manager
1279   --
1280
1281   procedure IO_Initialize (
1282      Major        : in     RTEMS.Device_Major_Number;
1283      Minor        : in     RTEMS.Device_Minor_Number;
1284      Argument     : in     RTEMS.Address;
1285      Return_Value :    out RTEMS.Unsigned32;
1286      Result       :    out RTEMS.Status_Codes
1287   );
1288
1289   procedure IO_Register_Name (
1290      Name   : in     String;
1291      Major  : in     RTEMS.Device_Major_Number;
1292      Minor  : in     RTEMS.Device_Minor_Number;
1293      Result :    out RTEMS.Status_Codes
1294   );
1295
1296   procedure IO_Lookup_Name (
1297      Name         : in     String;
1298      Device_Info  :    out RTEMS.Driver_Name_t;
1299      Result       :    out RTEMS.Status_Codes
1300   );
1301
1302   procedure IO_Open (
1303      Major        : in     RTEMS.Device_Major_Number;
1304      Minor        : in     RTEMS.Device_Minor_Number;
1305      Argument     : in     RTEMS.Address;
1306      Return_Value :    out RTEMS.Unsigned32;
1307      Result       :    out RTEMS.Status_Codes
1308   );
1309
1310   procedure IO_Close (
1311      Major        : in     RTEMS.Device_Major_Number;
1312      Minor        : in     RTEMS.Device_Minor_Number;
1313      Argument     : in     RTEMS.Address;
1314      Return_Value :    out RTEMS.Unsigned32;
1315      Result       :    out RTEMS.Status_Codes
1316   );
1317
1318   procedure IO_Read (
1319      Major        : in     RTEMS.Device_Major_Number;
1320      Minor        : in     RTEMS.Device_Minor_Number;
1321      Argument     : in     RTEMS.Address;
1322      Return_Value :    out RTEMS.Unsigned32;
1323      Result       :    out RTEMS.Status_Codes
1324   );
1325
1326   procedure IO_Write (
1327      Major        : in     RTEMS.Device_Major_Number;
1328      Minor        : in     RTEMS.Device_Minor_Number;
1329      Argument     : in     RTEMS.Address;
1330      Return_Value :    out RTEMS.Unsigned32;
1331      Result       :    out RTEMS.Status_Codes
1332   );
1333
1334   procedure IO_Control (
1335      Major        : in     RTEMS.Device_Major_Number;
1336      Minor        : in     RTEMS.Device_Minor_Number;
1337      Argument     : in     RTEMS.Address;
1338      Return_Value :    out RTEMS.Unsigned32;
1339      Result       :    out RTEMS.Status_Codes
1340   );
1341
1342
1343   --
1344   --  Fatal Error Manager
1345   --
1346
1347   procedure Fatal_Error_Occurred (
1348      The_Error : in     RTEMS.Unsigned32
1349   );
1350
1351
1352   --
1353   --  Rate Monotonic Manager
1354   --
1355
1356   procedure Rate_Monotonic_Create (
1357      Name   : in     RTEMS.Name;
1358      ID     :    out RTEMS.ID;
1359      Result :    out RTEMS.Status_Codes
1360   );
1361
1362   procedure Rate_Monotonic_Ident (
1363      Name   : in     RTEMS.Name;
1364      ID     :    out RTEMS.ID;
1365      Result :    out RTEMS.Status_Codes
1366   );
1367
1368   procedure Rate_Monotonic_Delete (
1369      ID     : in     RTEMS.ID;
1370      Result :    out RTEMS.Status_Codes
1371   );
1372
1373   procedure Rate_Monotonic_Cancel (
1374      ID     : in     RTEMS.ID;
1375      Result :    out RTEMS.Status_Codes
1376   );
1377
1378   procedure Rate_Monotonic_Period (
1379      ID      : in     RTEMS.ID;
1380      Length  : in     RTEMS.Interval;
1381      Result  :    out RTEMS.Status_Codes
1382   );
1383
1384   procedure Rate_Monotonic_Get_Status (
1385      ID      : in     RTEMS.ID;
1386      Status  :    out RTEMS.Rate_Monotonic_Period_Status;
1387      Result  :    out RTEMS.Status_Codes
1388   );
1389
1390   --
1391   --  Multiprocessing Manager
1392   --
1393
1394   procedure Multiprocessing_Announce;
1395
1396
1397   --
1398   --  Debug Manager
1399   --
1400
[d348ad96]1401   Debug_All_Mask : constant RTEMS.Debug_Set := 16#ffffffff#;
1402   Debug_Region   : constant RTEMS.Debug_Set := 16#00000001#;
1403
[f3f06f79]1404   procedure Debug_Enable (
1405      To_Be_Enabled : in     RTEMS.Debug_Set
1406   );
1407
1408   procedure Debug_Disable (
1409      To_Be_Disabled : in     RTEMS.Debug_Set
1410   );
1411
1412   function Debug_Is_Enabled (
1413      Level : in     RTEMS.Debug_Set
1414   ) return RTEMS.Boolean;
1415
1416  --
1417  --  Some Useful Data Items
1418  --
1419
1420  Configuration : RTEMS.Configuration_Table_Pointer;
1421  pragma Import (C, Configuration, "_Configuration_Table");
1422
[d766b7fd]1423
[f3f06f79]1424private
1425end RTEMS;
Note: See TracBrowser for help on using the repository browser.