source: rtems/c/src/ada-tests/samples/base_mp/mptest.ads @ e7f86ef

4.104.114.84.95
Last change on this file since e7f86ef was d0f426a1, checked in by Joel Sherrill <joel.sherrill@…>, on 06/03/97 at 00:34:04

* empty log message *

  • Property mode set to 100644
File size: 4.9 KB
Line 
1--
2--  MPTEST / SPECIFICATION
3--
4--  DESCRIPTION:
5--
6--  This package is the specification for Test 1 of the RTEMS
7--  Multiprocessor Test Suite.
8--
9--  DEPENDENCIES:
10--
11-- 
12--
13--  COPYRIGHT (c) 1989-1997.
14--  On-Line Applications Research Corporation (OAR).
15--  Copyright assigned to U.S. Government, 1994.
16--
17--  The license and distribution terms for this file may in
18--  the file LICENSE in this distribution or at
19--  http://www.OARcorp.com/rtems/license.html.
20--
21--  $Id$
22--
23
24with BSP_MPCI;
25with RTEMS;
26
27package MPTEST is
28
29--
30--  These arrays contain the IDs and NAMEs of all RTEMS tasks created
31--  by this test.
32--
33
34   TASK_ID   : array ( RTEMS.UNSIGNED32 range 1 .. 3 ) of RTEMS.ID;
35   TASK_NAME : array ( RTEMS.UNSIGNED32 range 1 .. 3 ) of RTEMS.NAME;
36
37--
38--  INIT
39--
40--  DESCRIPTION:
41--
42--  This RTEMS task initializes the application.
43--
44
45   procedure INIT (
46      ARGUMENT : in     RTEMS.TASK_ARGUMENT
47   );
48
49--
50--  APPLICATION_TASK
51--
52--  DESCRIPTION:
53--
54--  This routine is as an example of an application task which
55--  prints a message including its RTEMS task id.  This task
56--  then invokes exit to return to the monitor.
57--
58
59   procedure APPLICATION_TASK (
60      ARGUMENT : in     RTEMS.TASK_ARGUMENT
61   );
62
63--
64--  This is the Driver Address Table for this test.
65--
66
67   DEVICE_DRIVERS : aliased RTEMS.DRIVER_ADDRESS_TABLE( 1 .. 1 ) :=
68   (1=>
69      (
70        CLOCK_DRIVER.INITIALIZE'ACCESS,              -- Initialization
71        RTEMS.NO_DRIVER_ENTRY,                       -- Open
72        RTEMS.NO_DRIVER_ENTRY,                       -- Close
73        RTEMS.NO_DRIVER_ENTRY,                       -- Read
74        RTEMS.NO_DRIVER_ENTRY,                       -- Write
75        RTEMS.NO_DRIVER_ENTRY                        -- Control
76      )
77   );
78
79--
80--  This is the Initialization Tasks Table for this test.
81--
82
83   INITIALIZATION_TASKS : aliased RTEMS.INITIALIZATION_TASKS_TABLE( 1 .. 1 ) :=
84   (1=>
85     (
86       RTEMS.BUILD_NAME( 'U', 'I', '1', ' ' ),        -- task name
87       2048,                                          -- stack size
88       1,                                             -- priority
89       RTEMS.GLOBAL,                                  -- attributes
90       MPTEST.INIT'ACCESS,                            -- entry point
91       RTEMS.NO_PREEMPT,                              -- initial mode
92       0                                              -- argument list
93     )
94   );
95
96----------------------------------------------------------------------------
97----------------------------------------------------------------------------
98--                             BEGIN SUBPACKAGE                           --
99----------------------------------------------------------------------------
100----------------------------------------------------------------------------
101
102   --
103   --  MPTEST.PER_NODE_CONFIGURATION / SPECIFICATION
104   --
105   --  DESCRIPTION:
106   --
107   --  This package is the specification for the subpackage
108   --  which will define the per node configuration parameters.
109   --
110   
111   package PER_NODE_CONFIGURATION is
112
113   --
114   --  LOCAL_NODE_NUMBER
115   --
116   --  DESCRIPTION:
117   --
118   --  This function returns the node number for this node.
119   --
120
121      function LOCAL_NODE_NUMBER
122      return RTEMS.UNSIGNED32;
123 
124      pragma INLINE ( LOCAL_NODE_NUMBER );
125
126   end PER_NODE_CONFIGURATION;
127 
128----------------------------------------------------------------------------
129----------------------------------------------------------------------------
130--                              END SUBPACKAGE                            --
131----------------------------------------------------------------------------
132----------------------------------------------------------------------------
133
134--
135--  This is the Multiprocessor Configuration Table for this test.
136--
137
138   MULTIPROCESSING_CONFIGURATION : aliased RTEMS.MULTIPROCESSING_TABLE := (
139      MPTEST.PER_NODE_CONFIGURATION.LOCAL_NODE_NUMBER,
140      2,                         -- maximum # nodes in system
141      33,                        -- maximum # global objects
142      33                         -- maximum # proxies
143    );
144
145--
146--  This is the Configuration Table for this test.
147--
148
149   CONFIGURATION : aliased RTEMS.CONFIGURATION_TABLE := (
150      RTEMS.NULL_ADDRESS,        -- will be replaced by BSP
151      64 * 1024,                 -- executive RAM size
152      10,                        -- maximum # tasks
153      0,                         -- maximum # timers
154      0,                         -- maximum # semaphores
155      0,                         -- maximum # message queues
156      0,                         -- maximum # messages
157      0,                         -- maximum # partitions
158      0,                         -- maximum # regions
159      0,                         -- maximum # dp memory areas
160      0,                         -- maximum # periods
161      0,                         -- maximum # user extensions
162      RTEMS.MILLISECONDS_TO_MICROSECONDS(10), -- # us in a tick
163      50                         -- # ticks in a timeslice
164  );
165
166end MPTEST;
Note: See TracBrowser for help on using the repository browser.