source: trunk/libs/newlib/src/newlib/libc/sys/rtems/include/limits.h

Last change on this file was 444, checked in by satin@…, 6 years ago

add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc

File size: 6.2 KB
Line 
1/*
2 *  This file lists the minimums for the limits set by each of
3 *  the POSIX features subsets.
4 *
5 *  XXX: Careful attention needs to be paid to section 2.8 in 1003.1b-1993
6 *       to segregrate the variables below based on their "class" according
7 *       to our implementation.  We also need to set the Run-Time Invariant
8 *       and other related values.
9 *
10 *  $Id$
11 */
12
13#ifndef _GCC_LIMITS_H_  /* if we have not seen gcc's limits.h yet */
14#include_next <limits.h>
15#endif
16
17#include <sys/syslimits.h>
18
19#ifndef __POSIX_LIMITS_h
20#define __POSIX_LIMITS_h
21
22/****************************************************************************
23 ****************************************************************************
24 *                                                                          *
25 *         P1003.1b-1993 defines the constants below this comment.          *
26 *                                                                          *
27 ****************************************************************************
28 ****************************************************************************/
29
30#define _POSIX_AIO_LISTIO_MAX   2
31#define _POSIX_AIO_MAX          1
32#define _POSIX_ARG_MAX          4096
33#define _POSIX_CHILD_MAX        6
34#define _POSIX_DELAYTIMER_MAX   32
35#define _POSIX_HOST_NAME_MAX    255
36#define _POSIX_LINK_MAX         8
37#define _POSIX_MAX_CANON        255
38#define _POSIX_MAX_INPUT        255
39#define _POSIX_MQ_OPEN_MAX      8
40#define _POSIX_MQ_PRIO_MAX      32
41#define _POSIX_NAME_MAX         255
42#define _POSIX_NGROUPS_MAX      0
43#define _POSIX_OPEN_MAX         16
44#define _POSIX_PATH_MAX         255
45#define _POSIX_PIPE_BUF         512
46/* The maximum number of repeated occurrences of a regular expression
47 *  *    permitted when using the interval notation `\{M,N\}'.  */
48#define _POSIX2_RE_DUP_MAX              255
49#define _POSIX_RTSIG_MAX        8
50#define _POSIX_SEM_NSEMS_MAX    256
51#define _POSIX_SEM_VALUE_MAX    32767
52#define _POSIX_SIGQUEUE_MAX     32
53#define _POSIX_SSIZE_MAX        32767
54#define _POSIX_STREAM_MAX       8
55#define _POSIX_TIMER_MAX        32
56#define _POSIX_TZNAME_MAX       3
57
58/*
59 *  Definitions of the following may be omitted if the value is >= stated
60 *  minimum but is indeterminate.
61 */
62
63#define AIO_LISTIO_MAX          2
64#define AIO_MAX                 1
65#define AIO_PRIO_DELTA_MAX      0
66#define DELAYTIMER_MAX          32
67#define MQ_OPEN_MAX             8
68#define MQ_PRIO_MAX             32
69#define PAGESIZE                (1<<12)
70#define RTSIG_MAX               8
71#define SEM_NSEMS_MAX           256
72#define SEM_VALUE_MAX           INT_MAX
73#define SIGQUEUE_MAX            32
74#define STREAM_MAX              8
75#define TIMER_MAX               32
76#define TZNAME_MAX              3
77
78/*
79 *  Invariant values
80 */
81
82#ifdef __SIZE_MAX__
83#define SSIZE_MAX               (__SIZE_MAX__ >> 1)
84#elif defined(__SIZEOF_SIZE_T__) && defined(__CHAR_BIT__)
85#define SSIZE_MAX               ((1UL << (__SIZEOF_SIZE_T__ * __CHAR_BIT__ - 1)) - 1)
86#else /* historic fallback, wrong in most cases */
87#define SSIZE_MAX               32767
88#endif
89
90/*
91 *  Maximum Values
92 */
93
94#define _POSIX_CLOCKRES_MIN      0   /* in nanoseconds */
95
96/****************************************************************************
97 ****************************************************************************
98 *                                                                          *
99 *         P1003.1c/D10 defines the constants below this comment.           *
100 *
101 *  XXX: doc seems to have printing problems in this table :(
102 *                                                                          *
103 ****************************************************************************
104 ****************************************************************************/
105
106#define _POSIX_LOGIN_NAME_MAX                9
107#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS  4
108#define _POSIX_THREAD_KEYS_MAX               28
109#define _POSIX_THREAD_THREADS_MAX            64
110#define _POSIX_TTY_NAME_MAX                  9
111
112/*
113 *  Definitions of the following may be omitted if the value is >= stated
114 *  minimum but is indeterminate.
115 *
116 *  NOTE:  LOGIN_NAME_MAX is named LOGNAME_MAX under Solaris 2.x.  Perhaps
117 *         the draft specification will be changing.  jrs 05/24/96
118 */
119
120#define LOGIN_NAME_MAX                      _POSIX_LOGIN_NAME_MAX
121#define TTY_NAME_MAX                        _POSIX_TTY_NAME_MAX
122#define PTHREAD_DESTRUCTOR_ITERATIONS       _POSIX_THREAD_DESTRUCTOR_ITERATIONS
123
124/*
125 *  RTEMS is smart enough to give us the minimum stack size if we ask
126 *  for too little.  Because the real RTEMS limit for this is cpu dependent
127 *  AND rtems header files are not installed yet, we cannot use the cpu
128 *  dependent constant CPU_STACK_MINIMUM_SIZE.  Moreover, we do not want
129 *  to duplicate that information here so we will just let RTEMS magically
130 *  give us its minimum stack size.
131 *
132 *  NOTE:  The other alternative is to have this be a macro for a
133 *         routine in RTEMS which returns the constant.
134 */
135
136#define PTHREAD_STACK_MIN                   0
137
138/*
139 *  The maximum number of keys (PTHREAD_KEYS_MAX) and threads
140 *  (PTHREAD_THREADS_MAX) are configurable and may exceed the minimum.
141 *
142#define PTHREAD_KEYS_MAX                    _POSIX_THREAD_KEYS_MAX
143#define PTHREAD_THREADS_MAX                 _POSIX_THREAD_THREADS_MAX
144*/
145
146
147/****************************************************************************
148 ****************************************************************************
149 *                                                                          *
150 *         P1003.4b/D8 defines the constants below this comment.            *
151 *                                                                          *
152 ****************************************************************************
153 ****************************************************************************/
154
155#define _POSIX_INTERRUPT_OVERRUN_MAX        32
156
157/*
158 *  Definitions of the following may be omitted if the value is >= stated
159 *  minimum but is indeterminate.
160 */
161
162#define INTERRUPT_OVERRUN_MAX               32
163
164/*
165 *  Pathname Variables
166 */
167
168#define MIN_ALLOC_SIZE     
169#define REC_MIN_XFER_SIZE   
170#define REC_MAX_XFER_SIZE   
171#define REC_INCR_XFER_SIZE 
172#define REC_XFER_ALIGN     
173#define MAX_ATOMIC_SIZE     
174
175#endif
176/* end of include file */
Note: See TracBrowser for help on using the repository browser.