source: rtems/cpukit/sapi/include/confdefs.h @ d3d2afdf

4.104.114.84.95
Last change on this file since d3d2afdf was d3d2afdf, checked in by Joel Sherrill <joel.sherrill@…>, on Oct 25, 2005 at 11:17:35 AM

2005-10-25 Joel Sherrill <joel@…>

  • sapi/include/confdefs.h, telnetd/pty.c, telnetd/pty.h: Attempt to fix MAX_PTYS and provide a real configuration entry. This should make telnetd some suitable for inclusion in cpukit.
  • Property mode set to 100644
File size: 31.4 KB
Line 
1/**
2 * @file rtems/confdefs.h
3 *
4 *  This include file contains the configuration table template that will
5 *  be instantiated by an application based on the setting of a number
6 *  of macros.  The macros are documented in the Configuring a System
7 *  chapter of the Classic API User's Guide
8 *
9 *  The model is to estimate the memory required for each configured item
10 *  and sum those estimates.  The estimate can be too high or too low for
11 *  a variety of reasons:
12 *
13 *  Reasons estimate is too high:
14 *    + FP contexts (not all tasks are FP)
15 *
16 *  Reasons estimate is too low:
17 *    + stacks greater than minimum size
18 *    + messages
19 *    + application must account for device driver resources
20 *    + application must account for add-on library resource requirements
21 *
22 *  NOTE:  Eventually this may be able to take into account some of
23 *         the above.  This procedure has evolved from just enough to
24 *         support the RTEMS Test Suites into something that can be
25 *         used remarkably reliably by most applications.
26 */
27 
28/*
29 *  COPYRIGHT (c) 1989-2002.
30 *  On-Line Applications Research Corporation (OAR).
31 *
32 *  The license and distribution terms for this file may be
33 *  found in the file LICENSE in this distribution or at
34 *  http://www.rtems.com/license/LICENSE.
35 *
36 *  $Id$
37 */
38
39#ifndef __CONFIGURATION_TEMPLATE_h
40#define __CONFIGURATION_TEMPLATE_h
41
42#ifdef __cplusplus
43extern "C" {
44#endif
45
46/*
47 * Include the executive's configuration
48 */
49#include <rtems/score/cpuopts.h>
50#include <rtems/score/apimutex.h>
51
52extern rtems_initialization_tasks_table Initialization_tasks[];
53extern rtems_driver_address_table       Device_drivers[];
54extern rtems_configuration_table        Configuration;
55extern rtems_multiprocessing_table      Multiprocessing_configuration;
56#ifdef RTEMS_POSIX_API
57extern posix_api_configuration_table    Configuration_POSIX_API;
58#endif
59#ifdef RTEMS_ITRON_API
60extern itron_api_configuration_table    Configuration_ITRON_API;
61#endif
62
63/*
64 *  RTEMS C Library and Newlib support
65 */
66
67#ifdef RTEMS_NEWLIB
68#define CONFIGURE_NEWLIB_EXTENSION 1
69#else
70#define CONFIGURE_NEWLIB_EXTENSION 0
71#endif
72
73#define CONFIGURE_MALLOC_REGION 1
74
75/*
76 *  File descriptors managed by libio
77 */
78
79#ifndef CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS
80#define CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS 3
81#endif
82
83#define CONFIGURE_LIBIO_SEMAPHORES \
84  (CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS + 1)
85
86#ifdef CONFIGURE_INIT
87uint32_t   rtems_libio_number_iops = CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS;
88#endif
89
90/*
91 *  Termios resources
92 */
93
94#ifdef CONFIGURE_TERMIOS_DISABLED
95#define CONFIGURE_TERMIOS_SEMAPHORES 0
96#else
97
98#ifndef CONFIGURE_NUMBER_OF_TERMIOS_PORTS
99#define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 1
100#endif
101
102#define CONFIGURE_TERMIOS_SEMAPHORES \
103  ((CONFIGURE_NUMBER_OF_TERMIOS_PORTS * 4) + 1)
104#endif
105
106/*
107 *  PTYs
108 */
109
110#ifndef CONFIGURE_MAXIMUM_PTYS
111#define CONFIGURE_MAXIMUM_PTYS 0
112#endif
113
114#ifdef CONFIGURE_INIT
115int rtems_telnetd_maximum_ptys = CONFIGURE_MAXIMUM_PTYS;
116#else
117extern int rtems_telnetd_maximum_ptys;
118#endif
119
120/*
121 *  Mount Table Configuration
122 */
123
124#include <rtems/imfs.h>
125
126#ifdef CONFIGURE_INIT
127
128#ifndef CONFIGURE_HAS_OWN_MOUNT_TABLE
129rtems_filesystem_mount_table_t configuration_mount_table = {
130#ifdef CONFIGURE_USE_IMFS_AS_BASE_FILESYSTEM
131  &IMFS_ops,
132#else  /* using miniIMFS as base filesystem */
133  &miniIMFS_ops,
134#endif
135  RTEMS_FILESYSTEM_READ_WRITE,
136  NULL,
137  NULL
138};
139
140rtems_filesystem_mount_table_t
141    *rtems_filesystem_mount_table = &configuration_mount_table;
142int rtems_filesystem_mount_table_size = 1;
143#endif
144
145#endif
146
147
148/*
149 *  Stack Checker Requirements
150 *
151 *  NOTE: This does not automatically enable reporting at program exit.
152 */
153
154#ifdef STACK_CHECKER_ON
155#define CONFIGURE_STACK_CHECKER_EXTENSION 1
156#else
157#define CONFIGURE_STACK_CHECKER_EXTENSION 0
158#endif
159
160/*
161 *  Interrupt Stack Space
162 *
163 *  NOTE: There is currently no way for the application to override
164 *        the interrupt stack size set by the BSP.
165 */
166
167#if (CPU_ALLOCATE_INTERRUPT_STACK == 0)
168#undef CONFIGURE_INTERRUPT_STACK_MEMORY
169#define CONFIGURE_INTERRUPT_STACK_MEMORY 0
170#else
171  #ifndef CONFIGURE_INTERRUPT_STACK_MEMORY
172  #define CONFIGURE_INTERRUPT_STACK_MEMORY RTEMS_MINIMUM_STACK_SIZE
173  #endif
174#endif
175
176/*
177 *  Default User Initialization Task Table.  This table guarantees that
178 *  one user initialization table is defined.
179 */
180
181#ifdef CONFIGURE_RTEMS_INIT_TASKS_TABLE
182
183#ifdef CONFIGURE_HAS_OWN_INIT_TASK_TABLE
184
185/*
186 *  The user is defining their own table information and setting the
187 *  appropriate variables.
188 */
189
190#else
191
192#ifndef CONFIGURE_INIT_TASK_NAME
193#define CONFIGURE_INIT_TASK_NAME          rtems_build_name( 'U', 'I', '1', ' ' )
194#endif
195
196#ifndef CONFIGURE_INIT_TASK_STACK_SIZE
197#define CONFIGURE_INIT_TASK_STACK_SIZE    RTEMS_MINIMUM_STACK_SIZE
198#endif
199
200#ifndef CONFIGURE_INIT_TASK_PRIORITY
201#define CONFIGURE_INIT_TASK_PRIORITY      1
202#endif
203
204#ifndef CONFIGURE_INIT_TASK_ATTRIBUTES
205#define CONFIGURE_INIT_TASK_ATTRIBUTES    RTEMS_DEFAULT_ATTRIBUTES
206#endif
207
208#ifndef CONFIGURE_INIT_TASK_ENTRY_POINT
209#define CONFIGURE_INIT_TASK_ENTRY_POINT   Init
210#endif
211
212#ifndef CONFIGURE_INIT_TASK_INITIAL_MODES
213#define CONFIGURE_INIT_TASK_INITIAL_MODES RTEMS_NO_PREEMPT
214#endif
215
216#ifndef CONFIGURE_INIT_TASK_ARGUMENTS
217#define CONFIGURE_INIT_TASK_ARGUMENTS     0
218#endif
219
220#ifdef CONFIGURE_INIT
221rtems_initialization_tasks_table Initialization_tasks[] = {
222  { CONFIGURE_INIT_TASK_NAME,
223    CONFIGURE_INIT_TASK_STACK_SIZE,
224    CONFIGURE_INIT_TASK_PRIORITY,
225    CONFIGURE_INIT_TASK_ATTRIBUTES,
226    CONFIGURE_INIT_TASK_ENTRY_POINT,
227    CONFIGURE_INIT_TASK_INITIAL_MODES,
228    CONFIGURE_INIT_TASK_ARGUMENTS
229  }
230};
231#endif
232
233#define CONFIGURE_INIT_TASK_TABLE Initialization_tasks
234
235#define CONFIGURE_INIT_TASK_TABLE_SIZE \
236  sizeof(CONFIGURE_INIT_TASK_TABLE) / sizeof(rtems_initialization_tasks_table)
237
238#endif    /* CONFIGURE_HAS_OWN_INIT_TASK_TABLE */
239
240#else     /* CONFIGURE_RTEMS_INIT_TASKS_TABLE */
241
242#define CONFIGURE_INIT_TASK_TABLE      NULL
243#define CONFIGURE_INIT_TASK_TABLE_SIZE 0
244#define CONFIGURE_INIT_TASK_STACK_SIZE 0
245
246#endif
247
248/*
249 *  Map obsolete names to current ones
250 *
251 *  NOTE: These should be obsoleted in a future release.
252 */
253
254#ifdef CONFIGURE_TEST_NEEDS_TIMER_DRIVER
255#define CONFIGURE_APPLICATION_NEEDS_TIMER_DRIVER
256#endif
257#ifdef CONFIGURE_TEST_NEEDS_CONSOLE_DRIVER
258#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
259#endif
260#ifdef CONFIGURE_TEST_NEEDS_CLOCK_DRIVER
261#define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER
262#endif
263#ifdef CONFIGURE_TEST_NEEDS_RTC_DRIVER
264#define CONFIGURE_APPLICATION_NEEDS_RTC_DRIVER
265#endif
266#ifdef CONFIGURE_TEST_NEEDS_STUB_DRIVER
267#define CONFIGURE_APPLICATION_NEEDS_STUB_DRIVER
268#endif
269
270
271/*
272 *  Default Device Driver Table.  Each driver needed by the test is explicitly
273 *  choosen by that test.  There is always a null driver entry.
274 */
275
276#define NULL_DRIVER_TABLE_ENTRY \
277 { NULL, NULL, NULL, NULL, NULL, NULL }
278
279#ifdef CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
280#include <rtems/console.h>
281#endif
282
283#ifdef CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER
284#include <rtems/clockdrv.h>
285#endif
286
287#ifdef CONFIGURE_APPLICATION_NEEDS_TIMER_DRIVER
288#include <rtems/timerdrv.h>
289#endif
290
291#ifdef CONFIGURE_APPLICATION_NEEDS_RTC_DRIVER
292#include <rtems/rtc.h>
293#endif
294
295#ifdef CONFIGURE_APPLICATION_NEEDS_STUB_DRIVER
296#include <rtems/devnull.h>
297#endif
298
299#ifndef CONFIGURE_HAS_OWN_DEVICE_DRIVER_TABLE
300
301#ifdef CONFIGURE_INIT
302rtems_driver_address_table Device_drivers[] = {
303#ifdef CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
304  CONSOLE_DRIVER_TABLE_ENTRY,
305#endif
306#ifdef CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER
307  CLOCK_DRIVER_TABLE_ENTRY,
308#endif
309#ifdef CONFIGURE_APPLICATION_NEEDS_RTC_DRIVER
310  RTC_DRIVER_TABLE_ENTRY,
311#endif
312#ifdef CONFIGURE_APPLICATION_NEEDS_STUB_DRIVER
313  DEVNULL_DRIVER_TABLE_ENTRY,
314#endif
315#ifdef CONFIGURE_APPLICATION_NEEDS_NULL_DRIVER
316  NULL_DRIVER_TABLE_ENTRY
317#elif !defined(CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER) && \
318    !defined(CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER) && \
319    !defined(CONFIGURE_APPLICATION_NEEDS_RTC_DRIVER) && \
320    !defined(CONFIGURE_APPLICATION_NEEDS_STUB_DRIVER)
321  NULL_DRIVER_TABLE_ENTRY
322#endif
323};
324#endif
325
326#endif  /* CONFIGURE_HAS_OWN_DEVICE_DRIVER_TABLE */
327
328/*
329 *  Default the number of drivers per node.  This value may be
330 *  overridden by the user.
331 */
332
333#define CONFIGURE_NUMBER_OF_DRIVERS \
334  ((sizeof(Device_drivers) / sizeof(rtems_driver_address_table)))
335
336#ifndef CONFIGURE_MAXIMUM_DRIVERS
337#define CONFIGURE_MAXIMUM_DRIVERS CONFIGURE_NUMBER_OF_DRIVERS
338#endif
339
340/*
341 *  Default the number of devices per device driver.  This value may be
342 *  overridden by the user.
343 */
344
345#ifndef CONFIGURE_MAXIMUM_DEVICES
346#define CONFIGURE_MAXIMUM_DEVICES   20
347#endif
348
349/*
350 *  Default Multiprocessing Configuration Table.  The defaults are
351 *  appropriate for most of the RTEMS Multiprocessor Test Suite.  Each
352 *  value may be overridden within each test to customize the environment.
353 */
354
355#ifdef CONFIGURE_MP_APPLICATION
356#ifndef CONFIGURE_HAS_OWN_MULTIPROCESING_TABLE
357
358#ifndef CONFIGURE_MP_NODE_NUMBER
359#define CONFIGURE_MP_NODE_NUMBER                NODE_NUMBER
360#endif
361
362#ifndef CONFIGURE_MP_MAXIMUM_NODES
363#define CONFIGURE_MP_MAXIMUM_NODES              2
364#endif
365
366#ifndef CONFIGURE_MP_MAXIMUM_GLOBAL_OBJECTS
367#define CONFIGURE_MP_MAXIMUM_GLOBAL_OBJECTS     32
368#endif
369
370#ifndef CONFIGURE_MP_MAXIMUM_PROXIES
371#define CONFIGURE_MP_MAXIMUM_PROXIES            32
372#endif
373
374#ifndef CONFIGURE_MP_MPCI_TABLE_POINTER
375#include <mpci.h>
376#define CONFIGURE_MP_MPCI_TABLE_POINTER         &MPCI_table
377#endif
378
379#ifdef CONFIGURE_INIT
380rtems_multiprocessing_table Multiprocessing_configuration = {
381  CONFIGURE_MP_NODE_NUMBER,              /* local node number */
382  CONFIGURE_MP_MAXIMUM_NODES,            /* maximum # nodes in system */
383  CONFIGURE_MP_MAXIMUM_GLOBAL_OBJECTS,   /* maximum # global objects */
384  CONFIGURE_MP_MAXIMUM_PROXIES,          /* maximum # proxies */
385  CONFIGURE_MP_MPCI_TABLE_POINTER        /* pointer to MPCI config table */
386};
387#endif
388
389#define CONFIGURE_MULTIPROCESSING_TABLE    &Multiprocessing_configuration
390
391#endif /* CONFIGURE_HAS_OWN_MULTIPROCESING_TABLE */
392
393#else
394
395#define CONFIGURE_MULTIPROCESSING_TABLE    NULL
396
397#endif /* CONFIGURE_MP_APPLICATION */
398
399/*
400 *  Default Configuration Table.
401 */
402
403#ifndef CONFIGURE_HAS_OWN_CONFIGURATION_TABLE
404
405#ifndef CONFIGURE_EXECUTIVE_RAM_WORK_AREA
406#define CONFIGURE_EXECUTIVE_RAM_WORK_AREA     NULL
407#endif
408
409#ifndef CONFIGURE_MAXIMUM_TASKS
410#define CONFIGURE_MAXIMUM_TASKS               0
411#endif
412
413#ifndef CONFIGURE_MAXIMUM_TIMERS
414#define CONFIGURE_MAXIMUM_TIMERS              0
415#endif
416
417#ifndef CONFIGURE_MAXIMUM_SEMAPHORES
418#define CONFIGURE_MAXIMUM_SEMAPHORES          0
419#endif
420
421#ifndef CONFIGURE_MAXIMUM_MESSAGE_QUEUES
422#define CONFIGURE_MAXIMUM_MESSAGE_QUEUES      0
423#endif
424
425#ifndef CONFIGURE_MAXIMUM_PARTITIONS
426#define CONFIGURE_MAXIMUM_PARTITIONS          0
427#endif
428
429#ifndef CONFIGURE_MAXIMUM_REGIONS
430#define CONFIGURE_MAXIMUM_REGIONS             0
431#endif
432
433#ifndef CONFIGURE_MAXIMUM_PORTS
434#define CONFIGURE_MAXIMUM_PORTS               0
435#endif
436
437#ifndef CONFIGURE_MAXIMUM_PERIODS
438#define CONFIGURE_MAXIMUM_PERIODS             0
439#endif
440
441#ifndef CONFIGURE_MAXIMUM_USER_EXTENSIONS
442#define CONFIGURE_MAXIMUM_USER_EXTENSIONS     0
443#endif
444
445#ifndef CONFIGURE_MICROSECONDS_PER_TICK
446#define CONFIGURE_MICROSECONDS_PER_TICK RTEMS_MILLISECONDS_TO_MICROSECONDS(10)
447#endif
448
449#ifndef CONFIGURE_TICKS_PER_TIMESLICE
450#define CONFIGURE_TICKS_PER_TIMESLICE        50
451#endif
452
453/*
454 *  Initial Extension Set
455 */
456
457#ifdef CONFIGURE_INIT
458#ifdef STACK_CHECKER_ON
459#include <rtems/stackchk.h>
460#endif
461
462#if defined(CONFIGURE_INITIAL_EXTENSIONS) || \
463    defined(STACK_CHECKER_ON)
464rtems_extensions_table Configuration_Initial_Extensions[] = {
465#ifdef CONFIGURE_INITIAL_EXTENSIONS
466    CONFIGURE_INITIAL_EXTENSIONS,
467#endif
468#ifdef STACK_CHECKER_ON
469    STACK_CHECKER_EXTENSION,
470#endif
471};
472
473#define CONFIGURE_INITIAL_EXTENSION_TABLE Configuration_Initial_Extensions
474#define CONFIGURE_NUMBER_OF_INITIAL_EXTENSIONS \
475  ((sizeof(Configuration_Initial_Extensions) / \
476    sizeof(rtems_extensions_table)))
477#else
478#define CONFIGURE_INITIAL_EXTENSION_TABLE NULL
479#define CONFIGURE_NUMBER_OF_INITIAL_EXTENSIONS 0
480#endif
481
482
483#endif
484
485/*
486 *  POSIX API Configuration Parameters
487 */
488
489#ifdef RTEMS_POSIX_API
490
491#include <sys/types.h>
492#include <signal.h>
493#include <limits.h>
494#include <mqueue.h>
495#include <rtems/posix/cond.h>
496#include <rtems/posix/mqueue.h>
497#include <rtems/posix/mutex.h>
498#include <rtems/posix/key.h>
499#include <rtems/posix/psignal.h>
500#include <rtems/posix/semaphore.h>
501#include <rtems/posix/threadsup.h>
502#include <rtems/posix/timer.h>
503
504#ifndef CONFIGURE_MAXIMUM_POSIX_THREADS
505#define CONFIGURE_MAXIMUM_POSIX_THREADS      0
506#endif
507
508#ifndef CONFIGURE_MAXIMUM_POSIX_MUTEXES
509#define CONFIGURE_MAXIMUM_POSIX_MUTEXES      0
510#endif
511
512#ifndef CONFIGURE_MAXIMUM_POSIX_CONDITION_VARIABLES
513#define CONFIGURE_MAXIMUM_POSIX_CONDITION_VARIABLES  0
514#endif
515
516#ifndef CONFIGURE_MAXIMUM_POSIX_KEYS
517#define CONFIGURE_MAXIMUM_POSIX_KEYS         0
518#endif
519
520#ifndef CONFIGURE_MAXIMUM_POSIX_TIMERS
521#define CONFIGURE_MAXIMUM_POSIX_TIMERS 0
522#endif
523
524#ifndef CONFIGURE_MAXIMUM_POSIX_QUEUED_SIGNALS
525#define CONFIGURE_MAXIMUM_POSIX_QUEUED_SIGNALS 0
526#endif
527
528#ifndef CONFIGURE_MAXIMUM_POSIX_MESSAGE_QUEUES
529#define CONFIGURE_MAXIMUM_POSIX_MESSAGE_QUEUES 0
530#endif
531
532#ifndef CONFIGURE_MAXIMUM_POSIX_SEMAPHORES
533#define CONFIGURE_MAXIMUM_POSIX_SEMAPHORES 0
534#endif
535
536#ifdef CONFIGURE_POSIX_INIT_THREAD_TABLE
537
538#ifdef CONFIGURE_POSIX_HAS_OWN_INIT_THREAD_TABLE
539
540/*
541 *  The user is defining their own table information and setting the
542 *  appropriate variables for the POSIX Initialization Thread Table.
543 */
544
545#else
546
547#ifndef CONFIGURE_POSIX_INIT_THREAD_ENTRY_POINT
548#define CONFIGURE_POSIX_INIT_THREAD_ENTRY_POINT   POSIX_Init
549#endif
550
551#ifndef CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE
552#define CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE    (RTEMS_MINIMUM_STACK_SIZE * 2)
553#endif
554
555#ifdef CONFIGURE_INIT
556posix_initialization_threads_table POSIX_Initialization_threads[] = {
557  { CONFIGURE_POSIX_INIT_THREAD_ENTRY_POINT, \
558      CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE }
559};
560#endif
561
562#define CONFIGURE_POSIX_INIT_THREAD_TABLE_NAME POSIX_Initialization_threads
563
564#define CONFIGURE_POSIX_INIT_THREAD_TABLE_SIZE \
565  sizeof(CONFIGURE_POSIX_INIT_THREAD_TABLE_NAME) / \
566      sizeof(posix_initialization_threads_table)
567
568#endif    /* CONFIGURE_POSIX_HAS_OWN_INIT_TASK_TABLE */
569
570#else     /* CONFIGURE_POSIX_INIT_THREAD_TABLE */
571
572#define CONFIGURE_POSIX_INIT_THREAD_TABLE_NAME NULL
573#define CONFIGURE_POSIX_INIT_THREAD_TABLE_SIZE 0
574
575#endif
576
577#define CONFIGURE_MEMORY_PER_TASK_FOR_POSIX_API \
578  ( \
579    sizeof (POSIX_API_Control) + \
580   (sizeof (void *) * (CONFIGURE_GNAT_KEYS + CONFIGURE_MAXIMUM_POSIX_KEYS)) \
581  )
582
583#define CONFIGURE_MEMORY_FOR_POSIX_MUTEXES(_mutexes) \
584  ((_mutexes) * \
585   ( sizeof(POSIX_Mutex_Control) + CONFIGURE_OBJECT_TABLE_STUFF + \
586     NAME_MAX ) )
587
588#define CONFIGURE_MEMORY_FOR_POSIX_CONDITION_VARIABLES(_condition_variables) \
589  ((_condition_variables) * \
590   ( sizeof(POSIX_Condition_variables_Control) + \
591        CONFIGURE_OBJECT_TABLE_STUFF ) )
592
593#define CONFIGURE_MEMORY_FOR_POSIX_KEYS(_keys) \
594  ((_keys) * \
595   ( sizeof(POSIX_Keys_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
596
597#define CONFIGURE_MEMORY_FOR_POSIX_TIMERS(_timers) \
598   ((_timers) * (sizeof(POSIX_Timer_Control) + CONFIGURE_OBJECT_TABLE_STUFF))
599
600#define CONFIGURE_MEMORY_FOR_POSIX_QUEUED_SIGNALS(_queued_signals) \
601  ((_queued_signals) * \
602   ( sizeof(POSIX_signals_Siginfo_node) + CONFIGURE_OBJECT_TABLE_STUFF ) )
603
604#define CONFIGURE_MEMORY_FOR_POSIX_MESSAGE_QUEUES(_message_queues) \
605  ((_message_queues) * \
606   ( sizeof( POSIX_Message_queue_Control) + \
607    CONFIGURE_OBJECT_TABLE_STUFF + \
608    NAME_MAX ) )
609#define CONFIGURE_MEMORY_FOR_POSIX_SEMAPHORES(_semaphores) \
610  ((_semaphores) * \
611   ( sizeof( POSIX_Semaphore_Control) + \
612    CONFIGURE_OBJECT_TABLE_STUFF + \
613    NAME_MAX ) )
614
615#define CONFIGURE_MEMORY_FOR_POSIX \
616  ( \
617    CONFIGURE_MEMORY_FOR_POSIX_MUTEXES( CONFIGURE_MAXIMUM_POSIX_MUTEXES ) + \
618    CONFIGURE_MEMORY_FOR_POSIX_CONDITION_VARIABLES( \
619        CONFIGURE_MAXIMUM_POSIX_CONDITION_VARIABLES ) + \
620    CONFIGURE_MEMORY_FOR_POSIX_KEYS( CONFIGURE_MAXIMUM_POSIX_KEYS ) + \
621    CONFIGURE_MEMORY_FOR_POSIX_QUEUED_SIGNALS( \
622        CONFIGURE_MAXIMUM_POSIX_QUEUED_SIGNALS ) + \
623    CONFIGURE_MEMORY_FOR_POSIX_MESSAGE_QUEUES( \
624        CONFIGURE_MAXIMUM_POSIX_MESSAGE_QUEUES ) + \
625    CONFIGURE_MEMORY_FOR_POSIX_SEMAPHORES( \
626        CONFIGURE_MAXIMUM_POSIX_SEMAPHORES ) + \
627    CONFIGURE_MEMORY_FOR_POSIX_TIMERS( CONFIGURE_MAXIMUM_POSIX_TIMERS ) + \
628    (CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE) \
629   )
630
631
632#else
633
634#define CONFIGURE_MAXIMUM_POSIX_THREADS         0
635#define CONFIGURE_MEMORY_PER_TASK_FOR_POSIX_API 0
636#define CONFIGURE_MEMORY_FOR_POSIX              0
637
638
639#endif    /* RTEMS_POSIX_API */
640
641#ifndef CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE
642#define CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE    0
643#endif
644
645/*
646 *  ITRON API Configuration Parameters
647 */
648
649#ifdef RTEMS_ITRON_API
650
651#include <rtems/itron.h>
652#include <rtems/itron/config.h>
653#include <rtems/itron/eventflags.h>
654#include <rtems/itron/fmempool.h>
655#include <rtems/itron/mbox.h>
656#include <rtems/itron/msgbuffer.h>
657#include <rtems/itron/port.h>
658#include <rtems/itron/semaphore.h>
659#include <rtems/itron/task.h>
660#include <rtems/itron/vmempool.h>
661
662#ifndef CONFIGURE_MAXIMUM_ITRON_TASKS
663#define CONFIGURE_MAXIMUM_ITRON_TASKS      0
664#endif
665
666#ifndef CONFIGURE_MAXIMUM_ITRON_SEMAPHORES
667#define CONFIGURE_MAXIMUM_ITRON_SEMAPHORES   0
668#endif
669
670#ifndef CONFIGURE_MAXIMUM_ITRON_EVENTFLAGS
671#define CONFIGURE_MAXIMUM_ITRON_EVENTFLAGS   0
672#endif
673
674#ifndef CONFIGURE_MAXIMUM_ITRON_MAILBOXES
675#define CONFIGURE_MAXIMUM_ITRON_MAILBOXES   0
676#endif
677
678#ifndef CONFIGURE_MAXIMUM_ITRON_MESSAGE_BUFFERS
679#define CONFIGURE_MAXIMUM_ITRON_MESSAGE_BUFFERS   0
680#endif
681
682#ifndef CONFIGURE_MAXIMUM_ITRON_PORTS
683#define CONFIGURE_MAXIMUM_ITRON_PORTS   0
684#endif
685
686#ifndef CONFIGURE_MAXIMUM_ITRON_MEMORY_POOLS
687#define CONFIGURE_MAXIMUM_ITRON_MEMORY_POOLS   0
688#endif
689
690#ifndef CONFIGURE_MAXIMUM_ITRON_FIXED_MEMORY_POOLS
691#define CONFIGURE_MAXIMUM_ITRON_FIXED_MEMORY_POOLS   0
692#endif
693
694#ifdef CONFIGURE_ITRON_INIT_TASK_TABLE
695
696#ifdef CONFIGURE_ITRON_HAS_OWN_INIT_TASK_TABLE
697
698/*
699 *  The user is defining their own table information and setting the
700 *  appropriate variables for the ITRON Initialization Task Table.
701 */
702
703#else
704
705#ifndef CONFIGURE_ITRON_INIT_TASK_ENTRY_POINT
706#define CONFIGURE_ITRON_INIT_TASK_ENTRY_POINT   ITRON_Init
707#endif
708
709#ifndef CONFIGURE_ITRON_INIT_TASK_ATTRIBUTES
710#define CONFIGURE_ITRON_INIT_TASK_ATTRIBUTES    TA_HLNG
711#endif
712
713#ifndef CONFIGURE_ITRON_INIT_TASK_PRIORITY
714#define CONFIGURE_ITRON_INIT_TASK_PRIORITY      1
715#endif
716
717#ifndef CONFIGURE_ITRON_INIT_TASK_STACK_SIZE
718#define CONFIGURE_ITRON_INIT_TASK_STACK_SIZE    RTEMS_MINIMUM_STACK_SIZE
719#endif
720
721#ifdef CONFIGURE_INIT
722itron_initialization_tasks_table ITRON_Initialization_tasks[] = {
723  { 1,                                    /* ID */
724    { (VP) 0,                                /* exinfo */
725      CONFIGURE_ITRON_INIT_TASK_ATTRIBUTES,  /* task attributes */
726      CONFIGURE_ITRON_INIT_TASK_ENTRY_POINT, /* task start address */
727      CONFIGURE_ITRON_INIT_TASK_PRIORITY,    /* initial task priority */
728      CONFIGURE_ITRON_INIT_TASK_STACK_SIZE   /* stack size */
729    }
730  }
731};
732#endif
733
734#define CONFIGURE_ITRON_INIT_TASK_TABLE_NAME ITRON_Initialization_tasks
735
736#define CONFIGURE_ITRON_INIT_TASK_TABLE_SIZE \
737  sizeof(CONFIGURE_ITRON_INIT_TASK_TABLE_NAME) / \
738      sizeof(itron_initialization_tasks_table)
739
740#endif    /* CONFIGURE_ITRON_HAS_OWN_INIT_TASK_TABLE */
741
742#else     /* CONFIGURE_ITRON_INIT_TASK_TABLE */
743
744#define CONFIGURE_ITRON_INIT_TASK_TABLE_NAME NULL
745#define CONFIGURE_ITRON_INIT_TASK_TABLE_SIZE 0
746
747#endif
748
749#define CONFIGURE_MEMORY_PER_TASK_FOR_ITRON_API \
750  ( \
751    sizeof (ITRON_API_Control) \
752  )
753
754#define CONFIGURE_MEMORY_FOR_ITRON_SEMAPHORES(_semaphores) \
755  ((_semaphores) * \
756   ( sizeof(ITRON_Semaphore_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
757
758#define CONFIGURE_MEMORY_FOR_ITRON_EVENTFLAGS(_eventflags) \
759  ((_eventflags) * \
760   ( sizeof(ITRON_Eventflags_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
761
762#define CONFIGURE_MEMORY_FOR_ITRON_MAILBOXES(_mailboxes) \
763  ((_mailboxes) * \
764   ( sizeof(ITRON_Mailbox_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
765
766#define CONFIGURE_MEMORY_FOR_ITRON_MESSAGE_BUFFERS(_message_buffers) \
767  ((_message_buffers) * \
768   ( sizeof(ITRON_Message_buffer_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
769
770#define CONFIGURE_MEMORY_FOR_ITRON_PORTS(_ports) \
771  ((_ports) * \
772   ( sizeof(ITRON_Port_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
773
774#define CONFIGURE_MEMORY_FOR_ITRON_MEMORY_POOLS(_memory_pools) \
775  ((_memory_pools) * \
776   (sizeof(ITRON_Variable_memory_pool_Control) + CONFIGURE_OBJECT_TABLE_STUFF))
777
778#define CONFIGURE_MEMORY_FOR_ITRON_FIXED_MEMORY_POOLS(_fixed_memory_pools) \
779  ((_fixed_memory_pools) * \
780   ( sizeof(ITRON_Fixed_memory_pool_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
781
782#ifndef CONFIGURE_ITRON_INIT_TASK_STACK_SIZE
783#define CONFIGURE_ITRON_INIT_TASK_STACK_SIZE (RTEMS_MINIMUM_STACK_SIZE * 2)
784#endif
785
786
787#define CONFIGURE_MEMORY_FOR_ITRON \
788  ( \
789    CONFIGURE_MEMORY_FOR_ITRON_SEMAPHORES( \
790        CONFIGURE_MAXIMUM_ITRON_SEMAPHORES ) + \
791    CONFIGURE_MEMORY_FOR_ITRON_EVENTFLAGS( \
792        CONFIGURE_MAXIMUM_ITRON_EVENTFLAGS ) + \
793    CONFIGURE_MEMORY_FOR_ITRON_MAILBOXES( \
794        CONFIGURE_MAXIMUM_ITRON_MAILBOXES ) + \
795    CONFIGURE_MEMORY_FOR_ITRON_MESSAGE_BUFFERS( \
796        CONFIGURE_MAXIMUM_ITRON_MESSAGE_BUFFERS ) + \
797    CONFIGURE_MEMORY_FOR_ITRON_PORTS( \
798        CONFIGURE_MAXIMUM_ITRON_PORTS ) + \
799    CONFIGURE_MEMORY_FOR_ITRON_MEMORY_POOLS( \
800        CONFIGURE_MAXIMUM_ITRON_MEMORY_POOLS ) + \
801    CONFIGURE_MEMORY_FOR_ITRON_FIXED_MEMORY_POOLS( \
802        CONFIGURE_MAXIMUM_ITRON_FIXED_MEMORY_POOLS ) + \
803    CONFIGURE_ITRON_INIT_TASK_STACK_SIZE \
804   )
805
806
807#else
808
809#define CONFIGURE_MAXIMUM_ITRON_TASKS               0
810#define CONFIGURE_MAXIMUM_ITRON_SEMAPHORES          0
811#define CONFIGURE_MAXIMUM_ITRON_EVENTFLAGS          0
812#define CONFIGURE_MAXIMUM_ITRON_MAILBOXES           0
813#define CONFIGURE_MAXIMUM_ITRON_MESSAGE_BUFFERS     0
814#define CONFIGURE_MAXIMUM_ITRON_PORTS               0
815#define CONFIGURE_MAXIMUM_ITRON_MEMORY_POOLS        0
816#define CONFIGURE_MAXIMUM_ITRON_FIXED_MEMORY_POOLS  0
817#define CONFIGURE_MEMORY_PER_TASK_FOR_ITRON_API     0
818#define CONFIGURE_MEMORY_FOR_ITRON                  0
819
820#endif    /* RTEMS_ITRON_API */
821
822
823/*
824 *  Calculate the RAM size based on the maximum number of objects configured.
825 */
826
827#ifndef CONFIGURE_EXECUTIVE_RAM_SIZE
828
829#define CONFIGURE_OBJECT_TABLE_STUFF \
830  ( sizeof(Objects_Control *) + sizeof(rtems_name *) + sizeof(rtems_name) )
831
832#if defined(RTEMS_NEWLIB)
833#include <reent.h>
834
835#define CONFIGURE_MEMORY_PER_TASK_FOR_LIBC_REENTRANCY sizeof(struct _reent)
836#else
837#define CONFIGURE_MEMORY_PER_TASK_FOR_LIBC_REENTRANCY 0
838#endif
839
840#define CONFIGURE_MEMORY_FOR_TASKS(_tasks) \
841  (((_tasks) + 1 ) * \
842   ((sizeof(Thread_Control) + CONTEXT_FP_SIZE + \
843      STACK_MINIMUM_SIZE + sizeof( RTEMS_API_Control ) + \
844      CONFIGURE_MEMORY_PER_TASK_FOR_POSIX_API + \
845      CONFIGURE_MEMORY_PER_TASK_FOR_ITRON_API + \
846      CONFIGURE_MEMORY_PER_TASK_FOR_LIBC_REENTRANCY + \
847      CONFIGURE_OBJECT_TABLE_STUFF)) \
848  )
849
850#define CONFIGURE_MEMORY_FOR_TIMERS(_timers) \
851  ((_timers) * ( sizeof(Timer_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
852
853#define CONFIGURE_MEMORY_FOR_SEMAPHORES(_semaphores) \
854  ((_semaphores) * \
855   ( sizeof(Semaphore_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
856
857#define CONFIGURE_MEMORY_FOR_MESSAGE_QUEUES(_queues) \
858  ( (_queues) * \
859    ( sizeof(Message_queue_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
860
861#define CONFIGURE_MEMORY_FOR_PARTITIONS(_partitions) \
862  ( (_partitions) * \
863    ( sizeof(Partition_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
864
865#define CONFIGURE_MEMORY_FOR_REGIONS(_regions) \
866  ( (_regions) * \
867    ( sizeof(Region_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
868
869#define CONFIGURE_MEMORY_FOR_PORTS(_ports) \
870  ( (_ports) * \
871    ( sizeof(Dual_ported_memory_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
872
873#define CONFIGURE_MEMORY_FOR_PERIODS(_periods) \
874  ( (_periods) * \
875    ( sizeof(Rate_monotonic_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
876
877#define CONFIGURE_MEMORY_FOR_USER_EXTENSIONS(_extensions) \
878  ( (_extensions) * \
879    ( sizeof(Extension_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) )
880
881#define CONFIGURE_MEMORY_FOR_DEVICES(_devices) \
882  (((_devices) + 1) * ( sizeof(rtems_driver_name_t) ) )
883
884#ifdef CONFIGURE_MP_APPLICATION
885
886#ifndef CONFIGURE_HAS_OWN_MULTIPROCESING_TABLE
887
888#define CONFIGURE_MEMORY_FOR_PROXIES(_proxies) \
889  ( ((_proxies) + 1) * ( sizeof(Thread_Proxy_control) )  )
890
891#define CONFIGURE_MEMORY_FOR_GLOBAL_OBJECTS(_global_objects) \
892  ((_global_objects)  * ( sizeof(Objects_MP_Control) )  )
893
894#define CONFIGURE_MEMORY_FOR_MP \
895  ( CONFIGURE_MEMORY_FOR_PROXIES(CONFIGURE_MP_MAXIMUM_PROXIES) + \
896    CONFIGURE_MEMORY_FOR_GLOBAL_OBJECTS(CONFIGURE_MP_MAXIMUM_GLOBAL_OBJECTS) + \
897    CONFIGURE_MEMORY_FOR_TASKS(1) \
898  )
899
900#endif  /* CONFIGURE_HAS_OWN_MULTIPROCESING_TABLE */
901
902#else
903
904#define CONFIGURE_MEMORY_FOR_MP  0
905
906#endif
907
908#ifndef CONFIGURE_MEMORY_OVERHEAD
909#define CONFIGURE_MEMORY_OVERHEAD 0
910#endif
911
912#ifndef CONFIGURE_EXTRA_TASK_STACKS
913#define CONFIGURE_EXTRA_TASK_STACKS 0
914#endif
915
916#define CONFIGURE_API_MUTEX_MEMORY \
917  ( (1) * \
918    ( sizeof(API_Mutex_Control) + CONFIGURE_OBJECT_TABLE_STUFF ) \
919  )
920
921#define CONFIGURE_MEMORY_FOR_SYSTEM_OVERHEAD \
922  ( CONFIGURE_MEMORY_FOR_TASKS(1) +    /* IDLE */ \
923    (256 * 12) +                       /* Ready chains */ \
924    256        +                       /* name/ptr table overhead */ \
925    CONFIGURE_INTERRUPT_STACK_MEMORY + /* interrupt stack */ \
926    CONFIGURE_API_MUTEX_MEMORY         /* allocation mutex */ \
927  )
928
929/*
930 *  Now account for any extra memory that initialization tasks or threads
931 *  may have requested.
932 */
933
934#ifdef RTEMS_POSIX_API
935#define CONFIGURE_INITIALIZATION_THREADS_STACKS_POSIX_PART \
936    (CONFIGURE_POSIX_INIT_THREAD_STACK_SIZE - RTEMS_MINIMUM_STACK_SIZE)
937#else
938#define CONFIGURE_INITIALIZATION_THREADS_STACKS_POSIX_PART 0
939#endif
940#ifdef RTEMS_ITRON_API
941#define CONFIGURE_INITIALIZATION_THREADS_STACKS_ITRON_PART \
942    (CONFIGURE_ITRON_INIT_TASK_STACK_SIZE - RTEMS_MINIMUM_STACK_SIZE)
943#else
944#define CONFIGURE_INITIALIZATION_THREADS_STACKS_ITRON_PART 0
945#endif
946
947#define CONFIGURE_INITIALIZATION_THREADS_STACKS \
948   ((CONFIGURE_INIT_TASK_STACK_SIZE - RTEMS_MINIMUM_STACK_SIZE) + \
949    CONFIGURE_INITIALIZATION_THREADS_STACKS_POSIX_PART + \
950    CONFIGURE_INITIALIZATION_THREADS_STACKS_ITRON_PART)
951
952#define CONFIGURE_EXECUTIVE_RAM_SIZE \
953(( CONFIGURE_MEMORY_FOR_POSIX + \
954   CONFIGURE_MEMORY_FOR_ITRON + \
955   CONFIGURE_MEMORY_FOR_TASKS(CONFIGURE_MAXIMUM_TASKS + \
956      CONFIGURE_MAXIMUM_POSIX_THREADS + CONFIGURE_MAXIMUM_ADA_TASKS + \
957      CONFIGURE_MAXIMUM_ITRON_TASKS ) + \
958   CONFIGURE_INITIALIZATION_THREADS_STACKS + \
959   CONFIGURE_MEMORY_FOR_TIMERS(CONFIGURE_MAXIMUM_TIMERS) + \
960   CONFIGURE_MEMORY_FOR_SEMAPHORES(CONFIGURE_MAXIMUM_SEMAPHORES + \
961     CONFIGURE_LIBIO_SEMAPHORES + CONFIGURE_TERMIOS_SEMAPHORES) + \
962   CONFIGURE_MEMORY_FOR_MESSAGE_QUEUES(CONFIGURE_MAXIMUM_MESSAGE_QUEUES) + \
963   CONFIGURE_MEMORY_FOR_PARTITIONS(CONFIGURE_MAXIMUM_PARTITIONS) + \
964   CONFIGURE_MEMORY_FOR_REGIONS( \
965      CONFIGURE_MAXIMUM_REGIONS + CONFIGURE_MALLOC_REGION ) + \
966   CONFIGURE_MEMORY_FOR_PORTS(CONFIGURE_MAXIMUM_PORTS) + \
967   CONFIGURE_MEMORY_FOR_PERIODS(CONFIGURE_MAXIMUM_PERIODS) + \
968   CONFIGURE_MEMORY_FOR_USER_EXTENSIONS( \
969      CONFIGURE_MAXIMUM_USER_EXTENSIONS + CONFIGURE_NEWLIB_EXTENSION + \
970      CONFIGURE_STACK_CHECKER_EXTENSION ) + \
971   CONFIGURE_MEMORY_FOR_DEVICES(CONFIGURE_MAXIMUM_DEVICES) + \
972   CONFIGURE_MEMORY_FOR_MP + \
973   CONFIGURE_MEMORY_FOR_SYSTEM_OVERHEAD + \
974   (((CONFIGURE_MEMORY_OVERHEAD)+1) * 1024) + \
975   (CONFIGURE_EXTRA_TASK_STACKS) + (CONFIGURE_ADA_TASKS_STACK) \
976) & 0xfffffc00)
977#endif
978
979#ifdef CONFIGURE_GNAT_RTEMS
980#define CONFIGURE_GNAT_MUTEXES 10
981#define CONFIGURE_GNAT_KEYS    1
982
983/* 20 are required to run all tests in the ACVC */
984#ifndef CONFIGURE_MAXIMUM_ADA_TASKS
985#define CONFIGURE_MAXIMUM_ADA_TASKS  20
986#endif
987
988/* This is the number of non-Ada tasks which invoked Ada code. */
989#ifndef CONFIGURE_MAXIMUM_FAKE_ADA_TASKS
990#define CONFIGURE_MAXIMUM_FAKE_ADA_TASKS 0
991#endif
992
993/* Ada tasks are allocated twice the minimum stack space */
994#define CONFIGURE_ADA_TASKS_STACK \
995  (CONFIGURE_MAXIMUM_ADA_TASKS * (RTEMS_MINIMUM_STACK_SIZE + (6 * 1024)))
996
997#else
998#define CONFIGURE_GNAT_MUTEXES           0
999#define CONFIGURE_GNAT_KEYS              0
1000#define CONFIGURE_MAXIMUM_ADA_TASKS      0
1001#define CONFIGURE_MAXIMUM_FAKE_ADA_TASKS 0
1002#define CONFIGURE_ADA_TASKS_STACK        0
1003#endif
1004
1005
1006#ifdef CONFIGURE_INIT
1007
1008rtems_api_configuration_table Configuration_RTEMS_API = {
1009  CONFIGURE_MAXIMUM_TASKS,
1010  CONFIGURE_MAXIMUM_TIMERS,
1011  CONFIGURE_MAXIMUM_SEMAPHORES + CONFIGURE_LIBIO_SEMAPHORES +
1012    CONFIGURE_TERMIOS_SEMAPHORES,
1013  CONFIGURE_MAXIMUM_MESSAGE_QUEUES,
1014  CONFIGURE_MAXIMUM_PARTITIONS,
1015  CONFIGURE_MAXIMUM_REGIONS + CONFIGURE_MALLOC_REGION,
1016  CONFIGURE_MAXIMUM_PORTS,
1017  CONFIGURE_MAXIMUM_PERIODS,
1018  CONFIGURE_INIT_TASK_TABLE_SIZE,
1019  CONFIGURE_INIT_TASK_TABLE
1020};
1021
1022#ifdef RTEMS_POSIX_API
1023posix_api_configuration_table Configuration_POSIX_API = {
1024  CONFIGURE_MAXIMUM_POSIX_THREADS + CONFIGURE_MAXIMUM_ADA_TASKS,
1025  CONFIGURE_MAXIMUM_POSIX_MUTEXES + CONFIGURE_GNAT_MUTEXES +
1026    CONFIGURE_MAXIMUM_ADA_TASKS + CONFIGURE_MAXIMUM_FAKE_ADA_TASKS,
1027  CONFIGURE_MAXIMUM_POSIX_CONDITION_VARIABLES +
1028    CONFIGURE_MAXIMUM_ADA_TASKS + CONFIGURE_MAXIMUM_FAKE_ADA_TASKS,
1029  CONFIGURE_MAXIMUM_POSIX_KEYS + CONFIGURE_GNAT_KEYS,
1030  CONFIGURE_MAXIMUM_POSIX_TIMERS,
1031  CONFIGURE_MAXIMUM_POSIX_QUEUED_SIGNALS,
1032  CONFIGURE_MAXIMUM_POSIX_MESSAGE_QUEUES,
1033  CONFIGURE_MAXIMUM_POSIX_SEMAPHORES,
1034  CONFIGURE_POSIX_INIT_THREAD_TABLE_SIZE,
1035  CONFIGURE_POSIX_INIT_THREAD_TABLE_NAME
1036};
1037#endif
1038
1039#ifdef RTEMS_ITRON_API
1040itron_api_configuration_table Configuration_ITRON_API = {
1041  CONFIGURE_MAXIMUM_ITRON_TASKS,
1042  CONFIGURE_MAXIMUM_ITRON_SEMAPHORES,
1043  CONFIGURE_MAXIMUM_ITRON_EVENTFLAGS,
1044  CONFIGURE_MAXIMUM_ITRON_MAILBOXES,
1045  CONFIGURE_MAXIMUM_ITRON_MESSAGE_BUFFERS,
1046  CONFIGURE_MAXIMUM_ITRON_PORTS,
1047  CONFIGURE_MAXIMUM_ITRON_MEMORY_POOLS,
1048  CONFIGURE_MAXIMUM_ITRON_FIXED_MEMORY_POOLS,
1049  CONFIGURE_ITRON_INIT_TASK_TABLE_SIZE,
1050  CONFIGURE_ITRON_INIT_TASK_TABLE_NAME
1051};
1052#endif
1053
1054rtems_configuration_table Configuration = {
1055  CONFIGURE_EXECUTIVE_RAM_WORK_AREA,
1056  CONFIGURE_EXECUTIVE_RAM_SIZE,
1057  CONFIGURE_MAXIMUM_USER_EXTENSIONS + CONFIGURE_NEWLIB_EXTENSION +
1058      CONFIGURE_STACK_CHECKER_EXTENSION,
1059  CONFIGURE_MICROSECONDS_PER_TICK,
1060  CONFIGURE_TICKS_PER_TIMESLICE,
1061  CONFIGURE_MAXIMUM_DEVICES,
1062  CONFIGURE_MAXIMUM_DRIVERS,
1063  CONFIGURE_NUMBER_OF_DRIVERS,               /* number of device drivers */
1064  Device_drivers,                            /* pointer to driver table */
1065  CONFIGURE_NUMBER_OF_INITIAL_EXTENSIONS,    /* number of initial extensions */
1066  CONFIGURE_INITIAL_EXTENSION_TABLE,         /* pointer to initial extensions */
1067  CONFIGURE_MULTIPROCESSING_TABLE,           /* pointer to MP config table */
1068  &Configuration_RTEMS_API,                  /* pointer to RTEMS API config */
1069#ifdef RTEMS_POSIX_API
1070  &Configuration_POSIX_API,                  /* pointer to POSIX API config */
1071#else
1072  NULL,                                      /* pointer to POSIX API config */
1073#endif
1074#ifdef RTEMS_ITRON_API
1075  &Configuration_ITRON_API                   /* pointer to ITRON API config */
1076#else
1077  NULL                                       /* pointer to ITRON API config */
1078#endif
1079};
1080#endif
1081
1082#endif /* CONFIGURE_HAS_OWN_CONFIGURATION_TABLE */
1083
1084#ifdef __cplusplus
1085}
1086#endif
1087
1088/*
1089 *  Some warnings and error checking
1090 */
1091
1092/*
1093 *  Make sure a task/thread of some sort is configured
1094 */
1095
1096#if (CONFIGURE_MAXIMUM_TASKS == 0) && \
1097    (CONFIGURE_MAXIMUM_POSIX_THREADS == 0) && \
1098    (CONFIGURE_MAXIMUM_ADA_TASKS == 0) &&  \
1099    (CONFIGURE_MAXIMUM_ITRON_TASKS == 0)
1100#error "CONFIGURATION ERROR: No tasks or threads configured!!"
1101#endif
1102
1103/*
1104 *  Make sure at least one of the initialization task/thread
1105 *  tables was defined.
1106 */
1107
1108#if !defined(CONFIGURE_RTEMS_INIT_TASKS_TABLE) && \
1109    !defined(CONFIGURE_POSIX_INIT_THREAD_TABLE) && \
1110    !defined(CONFIGURE_ITRON_INIT_TASK_TABLE)
1111#error "CONFIGURATION ERROR: No initialization tasks or threads configured!!"
1112#endif
1113
1114#endif
1115/* end of include file */
Note: See TracBrowser for help on using the repository browser.