OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [rtems/] [c/] [src/] [tests/] [samples/] [unlimited/] [system.h] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 158 chris
/*  system.h
2
 *
3
 *  This include file contains information that is included in every
4
 *  function in the test set.
5
 *
6
 *  COPYRIGHT (c) 1989-1997.
7
 *  On-Line Applications Research Corporation (OAR).
8
 *  Copyright assigned to U.S. Government, 1994.
9
 *
10
 *  The license and distribution terms for this file may in
11
 *  the file LICENSE in this distribution or at
12
 *  http://www.OARcorp.com/rtems/license.html.
13
 *
14 208 chris
 *  $Id: system.h,v 1.2 2001-09-27 12:02:29 chris Exp $
15 158 chris
 */
16
 
17
#include <rtems.h>
18
 
19
/* functions */
20
 
21
rtems_task Init(
22
  rtems_task_argument argument
23
);
24
 
25
rtems_task test_task(
26
  rtems_task_argument my_number
27
);
28
 
29
void
30
destory_all_tasks(
31
  const char *who
32
);
33
 
34
boolean status_code_bad(
35
  rtems_status_code status_code
36
);
37
 
38
void test1();
39
void test2();
40
void test3();
41
 
42
/* configuration information */
43
 
44
#include <bsp.h> /* for device driver prototypes */
45
 
46
#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
47
 
48
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
49
 
50
#define TASK_ALLOCATION_SIZE     (5)
51
#define CONFIGURE_MAXIMUM_TASKS  rtems_resource_unlimited(TASK_ALLOCATION_SIZE)
52
#define CONFIGURE_EXTRA_TASK_STACKS (62 * RTEMS_MINIMUM_STACK_SIZE)
53
 
54
 
55
#include <confdefs.h>
56
 
57
/*
58
 * Keep track of the task id's created, use a large array.
59
 */
60
 
61
#define MAX_TASKS         (1000)
62
#define TASK_INDEX_OFFSET (1)
63
 
64
extern rtems_id task_id[MAX_TASKS];
65
 
66
/*
67
 * Increment the task name.
68
 */
69
 
70
#define NEXT_TASK_NAME(c1, c2, c3, c4)  \
71
                 if (c4 == '9') {       \
72
                   if (c3 == '9') {     \
73
                     if (c2 == 'z') {   \
74
                       if (c1 == 'z') { \
75
                         printf("not enough task letters for names !!!\n"); \
76
                         exit( 1 );     \
77
                       } else           \
78
                         c1++;          \
79
                       c2 = 'a';        \
80
                     } else             \
81
                      c2++;             \
82
                     c3 = '0';          \
83
                   } else               \
84
                     c3++;              \
85
                   c4 = '0';            \
86
                 }                      \
87
                 else                   \
88
                   c4++                 \
89
 
90
 
91
/* end of include file */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.