source: rtems/c/src/ada/rtems.ads @ df25c998

4.104.114.84.95
Last change on this file since df25c998 was 8f2cf931, checked in by Joel Sherrill <joel.sherrill@…>, on 10/21/99 at 14:49:24

Added Semaphore_Flush.

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