]> git.ipfire.org Git - thirdparty/glibc.git/blame - sysdeps/unix/sysv/linux/alpha/kernel-features.h
Fix unbound stack use in NIS NSS module
[thirdparty/glibc.git] / sysdeps / unix / sysv / linux / alpha / kernel-features.h
CommitLineData
b14e8cb2
MT
1/* Set flags signalling availability of kernel features based on given
2 kernel version number.
d4697bc9 3 Copyright (C) 2010-2014 Free Software Foundation, Inc.
b14e8cb2
MT
4 This file is part of the GNU C Library.
5
6 The GNU C Library is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Lesser General Public
8 License as published by the Free Software Foundation; either
9 version 2.1 of the License, or (at your option) any later version.
10
11 The GNU C Library is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Lesser General Public License for more details.
15
16 You should have received a copy of the GNU Lesser General Public
ab84e3ff
PE
17 License along with the GNU C Library. If not, see
18 <http://www.gnu.org/licenses/>. */
b14e8cb2 19
fe7b738e
RH
20#ifndef _KERNEL_FEATURES_H
21#define _KERNEL_FEATURES_H 1
22
b14e8cb2
MT
23#define __ASSUME_UTIMES 1
24
742c00d3
MT
25/* Support for the O_CLOEXEC flag was added for alpha in 2.6.23. */
26#if __LINUX_KERNEL_VERSION >= 0x020617
27# define __ASSUME_O_CLOEXEC 1
28#endif
29
30/* Support for various CLOEXEC and NONBLOCK flags was added for alpha after
31 2.6.33-rc1. */
32#if __LINUX_KERNEL_VERSION >= 0x020621
33# define __ASSUME_SOCK_CLOEXEC 1
34# define __ASSUME_IN_NONBLOCK 1
35#endif
36
5556231d 37/* Support for the pipe2, eventfd2, signalfd4 syscalls was added for alpha
742c00d3
MT
38 after 2.6.33-rc1. */
39#if __LINUX_KERNEL_VERSION >= 0x020621
40# define __ASSUME_PIPE2 1
41# define __ASSUME_EVENTFD2 1
42# define __ASSUME_SIGNALFD4 1
43#endif
44
0e31b18c
JM
45/* Support for recvmmsg was added for alpha in 2.6.33. */
46#if __LINUX_KERNEL_VERSION >= 0x020621
47# define __ASSUME_RECVMMSG_SYSCALL 1
48#endif
49
bc688c10 50/* Support for accept4 and sendmmsg was added for alpha in 3.2. */
dd481ccf
JM
51#if __LINUX_KERNEL_VERSION >= 0x030200
52# define __ASSUME_ACCEPT4_SYSCALL 1
bc688c10 53# define __ASSUME_SENDMMSG_SYSCALL 1
742c00d3
MT
54#endif
55
b14e8cb2
MT
56#include_next <kernel-features.h>
57
58#undef __ASSUME_ST_INO_64_BIT
59
60/* pselect/ppoll were introduced on alpha just after 2.6.22-rc1. */
61#if __LINUX_KERNEL_VERSION < 0x020617
62# undef __ASSUME_PSELECT
63# undef __ASSUME_PPOLL
64#endif
65
66/* The *at syscalls were introduced on alpha just after 2.6.22-rc1. */
67#if __LINUX_KERNEL_VERSION < 0x020617
68# undef __ASSUME_ATFCTS
69#endif
70
71/* Support for inter-process robust mutexes was added on alpha just
72 after 2.6.22-rc1. */
73#if __LINUX_KERNEL_VERSION < 0x020617
74# undef __ASSUME_SET_ROBUST_LIST
75#endif
76
77/* Support for utimensat was added on alpha after 2.6.22-rc1. */
78#if __LINUX_KERNEL_VERSION < 0x020617
79# undef __ASSUME_UTIMENSAT
80#endif
81
742c00d3 82/* Support for fallocate was added for alpha after 2.6.33-rc1. */
b14e8cb2
MT
83#if __LINUX_KERNEL_VERSION < 0x020621
84# undef __ASSUME_FALLOCATE
85#endif
fe7b738e
RH
86
87/* There never has been support for fstat64. */
88#undef __ASSUME_STATFS64
89#define __ASSUME_STATFS64 0
90
563c8405
MF
91/* Support for fsyncdata was added for alpha after 2.6.21. */
92#if __LINUX_KERNEL_VERSION >= 0x020616
93# define __ASSUME_FDATASYNC 1
94#endif
95
b1115e91
JM
96/* Support for preadv and pwritev was added for alpha in 2.6.33. */
97#if __LINUX_KERNEL_VERSION < 0x020621
98# undef __ASSUME_PREADV
99# undef __ASSUME_PWRITEV
100#endif
101
fe7b738e 102#endif /* _KERNEL_FEATURES_H */