]> git.ipfire.org Git - thirdparty/glibc.git/blob - sysdeps/unix/sysv/linux/bits/local_lim.h
Merge glibc-ports into ports/ directory.
[thirdparty/glibc.git] / sysdeps / unix / sysv / linux / bits / local_lim.h
1 /* Minimum guaranteed maximum values for system limits. Linux version.
2 Copyright (C) 1993-1998,2000,2003,2004,2008 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <http://www.gnu.org/licenses/>. */
18
19 /* The kernel header pollutes the namespace with the NR_OPEN symbol
20 and defines LINK_MAX although filesystems have different maxima. A
21 similar thing is true for OPEN_MAX: the limit can be changed at
22 runtime and therefore the macro must not be defined. Remove this
23 after including the header if necessary. */
24 #ifndef NR_OPEN
25 # define __undef_NR_OPEN
26 #endif
27 #ifndef LINK_MAX
28 # define __undef_LINK_MAX
29 #endif
30 #ifndef OPEN_MAX
31 # define __undef_OPEN_MAX
32 #endif
33 #ifndef ARG_MAX
34 # define __undef_ARG_MAX
35 #endif
36
37 /* The kernel sources contain a file with all the needed information. */
38 #include <linux/limits.h>
39
40 /* Have to remove NR_OPEN? */
41 #ifdef __undef_NR_OPEN
42 # undef NR_OPEN
43 # undef __undef_NR_OPEN
44 #endif
45 /* Have to remove LINK_MAX? */
46 #ifdef __undef_LINK_MAX
47 # undef LINK_MAX
48 # undef __undef_LINK_MAX
49 #endif
50 /* Have to remove OPEN_MAX? */
51 #ifdef __undef_OPEN_MAX
52 # undef OPEN_MAX
53 # undef __undef_OPEN_MAX
54 #endif
55 /* Have to remove ARG_MAX? */
56 #ifdef __undef_ARG_MAX
57 # undef ARG_MAX
58 # undef __undef_ARG_MAX
59 #endif
60
61 /* Maximum amount by which a process can descrease its asynchronous I/O
62 priority level. */
63 #define AIO_PRIO_DELTA_MAX 20
64
65 /* Maximum tty name length. */
66 #define TTY_NAME_MAX 32
67
68 /* Maximum login name length. This is arbitrary. */
69 #define LOGIN_NAME_MAX 256
70
71 /* Maximum host name length. */
72 #define HOST_NAME_MAX 64
73
74 /* Maximum message queue priority level. */
75 #define MQ_PRIO_MAX 32768