about summary refs log tree commit diff
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* fcntl.h: add AT_RECURSIVE from linux v5.2Szabolcs Nagy2019-09-111-0/+1
| | | | | | | apply open_tree with OPEN_TREE_CLONE call to the entire subtree, see linux commit a07b20004793d8926f78d63eb5980559f7813404 vfs: syscall: Add open_tree(2) to reference or clone a mount
* fcntl.h: add AT_STATX_ statx sync flag definitionsSzabolcs Nagy2019-09-111-0/+4
| | | | | | | | | | see linux commit a528d35e8bfcc521d7cb70aaf03e1bd296c8493f statx: Add a system call to make enhanced file info available these are linux specific and not reserved names for fcntl.h so they are under _BSD_SOURCE|_GNU_SOURCE.
* sched.h: add CLONE_PIDFD from linux v5.2Szabolcs Nagy2019-09-111-0/+1
| | | | | | | when set a pidfd is stored in parent_tidptr, see linux commit b3e5838252665ee4cfa76b82bdf1198dca81e5be clone: add CLONE_PIDFD
* netinet/if_ether.h: add ETH_P_DSA_8021Q from linux v5.2Szabolcs Nagy2019-09-111-0/+1
| | | | | | | ethertype for fake VLAN header for DSA, see linux commit bf5bc3ce8a8f32a0d45b6820ede8f9fc3e9c23df ether: Add dedicated Ethertype for pseudo-802.1Q DSA tagging
* add public declaration for optreset under appropriate feature profilesRich Felker2019-08-301-0/+1
| | | | | | | | commit 030e52639248ac8417a4934298caa78c21a228d1 added optreset, a BSD extension to getopt duplicating the functionality (also an extension) of setting optind to 0, but failed to provide a public declaration for it. according to the BSD documentation and headers, the application is not supposed to need to provide its own declaration.
* add posix_spawn [f]chdir file actionsRich Felker2019-08-301-0/+5
| | | | | | | these are presently extensions, thus named with _np to match glibc and other implementations that provide them; however they are likely to be standardized in the future without the _np suffix as a result of Austin Group issue 1208. if so, both names will be kept as aliases.
* add copy_file_range system call wrapperÁrni Dagur2019-08-231-0/+1
|
* remove sporadic server members from struct sched_paramRich Felker2019-08-141-4/+6
| | | | | | | | these members are associated with an unsupported option group. with time_t changing size on 32-bit archs, all interfaces taking struct sched_param arguments would need redirection and compat shims in order to be able to continue offering these members, for no benefit. just convert them to reserved space instead.
* add secure_getenv functionPetr Vaněk2019-08-081-0/+1
| | | | This function is a GNU extension introduced in glibc 2.17.
* glob: implement GLOB_TILDE and GLOB_TILDE_CHECKIsmael Luceno2019-08-061-0/+3
|
* move IPC_STAT definition to a new bits/ipcstat.h fileRich Felker2019-08-021-3/+1
| | | | | | | | | | | | | | | otherwise, 32-bit archs that could otherwise share the generic bits/ipc.h would need to duplicate the struct ipc_perm definition, obscuring the fact that it's the same. sysvipc is not widely used and these headers are not commonly included, so there is no performance gain to be had by limiting the number of indirectly included files here. files with the existing time32 definition of IPC_STAT are added to all current 32-bit archs now, so that when it's changed the change will show up as a change rather than addition of a new file where it's less obvious that the value is changing vs the generic one that was used before.
* allow archs to define IPC_STAT, propagate time64 bit to other macrosRich Felker2019-08-024-6/+8
| | | | | | | | to make use of {sem,shm,msg}ctl IPC_STAT functionality to provide 64-bit time_t on 32-bit archs, IPC_STAT and related macros must be defined with bit 8 (0x100) set. allow archs to define IPC_STAT in bits/ipc.h, and define the other macros in terms of it so that they all get the same value of the time64 bit.
* elf.h: add NT_ARM_PAC{A,G}_KEYS from linux v5.1Szabolcs Nagy2019-07-011-0/+2
| | | | | | | to request or change pointer auth keys for criu via ptrace, new in linux commit d0a060be573bfbf8753a15dca35497db5e968bb0 arm64: add ptrace regsets for ptrauth key management
* netinet/in.h: add INADDR_ALLSNOOPERS_GROUP from linux v5.1Szabolcs Nagy2019-07-011-0/+1
| | | | | | | | RFC 4286: "The IPv4 multicast address for All-Snoopers is 224.0.0.106." from linux commit 4effd28c1245303dce7fd290c501ac2c11052114 bridge: join all-snoopers multicast address
* sys/socket.h: add SO_BINDTOIFINDEX from linux v5.1Szabolcs Nagy2019-07-011-0/+1
| | | | | | | | | SO_BINDTOIFINDEX behaves similar to SO_BINDTODEVICE, but takes a network interface index as argument, rather than the network interface name. see linux commit f5dd3d0c9638a9d9a02b5964c4ad636f06cf7e2c net: introduce SO_BINDTOIFINDEX sockopt
* netinet/in.h: add IPV6_ROUTER_ALERT_ISOLATE from linux v5.1Szabolcs Nagy2019-07-011-0/+1
| | | | | | | | restricts router alert packets received by the socket to the socket's namespace only. see linux commit 9036b2fe092a107856edd1a3bad48b83f2b45000 net: ipv6: add socket option IPV6_ROUTER_ALERT_ISOLATE
* sys/prctl.h: add PR_SPEC_DISABLE_NOEXEC from linux v5.1Szabolcs Nagy2019-07-011-0/+1
| | | | | | | | allows specifying that the speculative store bypass disable bit should be cleared on exec. see linux commit 71368af9027f18fe5d1c6f372cfdff7e4bde8b48 x86/speculation: Add PR_SPEC_DISABLE_NOEXEC
* fcntl.h: add F_SEAL_FUTURE_WRITE from linux v5.1Szabolcs Nagy2019-07-011-0/+1
| | | | | | | | | needed for android so it can migrate from its ashmem to memfd. allows making the memfd readonly for future users while keeping a writable mmap of it. see linux commit ab3948f58ff841e51feb845720624665ef5b7ef3 mm/memfd: add an F_SEAL_FUTURE_WRITE seal to memfd
* sys/fanotify.h: update for linux v5.1Szabolcs Nagy2019-07-011-1/+33
| | | | | | | | | | | | | | | | | includes changes from linux v5.1 linux commit 235328d1fa4251c6dcb32351219bb553a58838d2 fanotify: add support for create/attrib/move/delete events linux commit 5e469c830fdb5a1ebaa69b375b87f583326fd296 fanotify: copy event fid info to user linux commit e9e0c8903009477b630e37a8b6364b26a00720da fanotify: encode file identifier for FAN_REPORT_FID as well as earlier changes that were missed. sys/statfs.h is included for fsid_t.
* remove implicit include of sys/sysmacros.h from sys/types.hRich Felker2019-06-211-1/+0
| | | | | | | | | | this reverts commit f552c792c7ce5a560f214e1104d93ee5b0833967, which exposed the sysmacros.h macros (device major/minor calculations) for BSD and GNU profiles to mimic an unintentional glibc behavior some code depended on. glibc has deprecated and since removed them as the resolution to bug #19239, so it makes no sense for us to keep this behavior. affected code should all have been fixed by now, and if it's not yet fixed it needs to be for use with modern glibc anyway.
* add riscv64 architecture supportRich Felker2019-06-141-0/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Author: Alex Suykov <alex.suykov@gmail.com> Author: Aric Belsito <lluixhi@gmail.com> Author: Drew DeVault <sir@cmpwn.com> Author: Michael Clark <mjc@sifive.com> Author: Michael Forney <mforney@mforney.org> Author: Stefan O'Rear <sorear2@gmail.com> This port has involved the work of many people over several years. I have tried to ensure that everyone with substantial contributions has been credited above; if any omissions are found they will be noted later in an update to the authors/contributors list in the COPYRIGHT file. The version committed here comes from the riscv/riscv-musl repo's commit 3fe7e2c75df78eef42dcdc352a55757729f451e2, with minor changes by me for issues found during final review: - a_ll/a_sc atomics are removed (according to the ISA spec, lr/sc are not safe to use in separate inline asm fragments) - a_cas[_p] is fixed to be a memory barrier - the call from the _start assembly into the C part of crt1/ldso is changed to allow for the possibility that the linker does not place them nearby each other. - DTP_OFFSET is defined correctly so that local-dynamic TLS works - reloc.h LDSO_ARCH logic is simplified and made explicit. - unused, non-functional crti/n asm files are removed. - an empty .sdata section is added to crt1 so that the __global_pointer reference is resolvable. - indentation style errors in some asm files are fixed.
* define FP_FAST_FMA* when fma* can be inlinedSzabolcs Nagy2019-04-171-0/+12
| | | | | | | | | | | | | | | | | | | FP_FAST_FMA can be defined if "the fma function generally executes about as fast as, or faster than, a multiply and an add of double operands", which can only be true if the fma call is inlined as an instruction. gcc sets __FP_FAST_FMA if __builtin_fma is inlined as an instruction, but that does not mean an fma call will be inlined (e.g. it is defined with -fno-builtin-fma), other compilers (clang) don't even have such macro, but this is the closest we can get. (even if the libc fma implementation is a single instruction, the extern call overhead is already too big when the macro is used to decide between x*y+z and fma(x,y,z) so it cannot be based on libc only, defining the macro unconditionally on targets which have fma in the base isa is also incorrect: the compiler might not inline fma anyway.) this solution works with gcc unless fma inlining is explicitly turned off.
* fcntl.h: define O_TTY_INIT to 0A. Wilcox2019-04-101-2/+3
| | | | | | | | | | POSIX: "[If] either O_TTY_INIT is set in oflag or O_TTY_INIT has the value zero, open() shall set any non-standard termios structure terminal parameters to a state that provides conforming behavior." The Linux kernel tty drivers always perform initialisation on their devices to set known good termios values during the open(2) call. This means that setting O_TTY_INIT to zero is conforming.
* fix signature of function accepted by makecontextBobby Bingham2019-04-051-1/+1
| | | | | | | | This parameter was incorrectly declared to be a pointer to a function accepting zero parameters. The intent of makecontext is that it is possible to pass integer parameters to the function, so this should have been a pointer to a function accepting an unspecified set of parameters.
* sys/prctl.h: add PR_PAC_RESET_KEYS from linux v5.0Szabolcs Nagy2019-03-131-0/+7
| | | | | | aarch64 pointer authentication code related prctl that allows reinitializing the key for the thread, added in linux commit ba830885656414101b2f8ca88786524d4bb5e8c1
* elf.h: add NT_ definitions from linux v5.0Szabolcs Nagy2019-03-131-0/+2
| | | | | | | NT_MIPS_MSA for ptrace access to mips simd arch reg set, added in linux commit 3cd640832894b85b5929d5bda74505452c800421 NT_ARM_PAC_MASK for ptrace access to pointer auth code mask, added in commit ec6e822d1a22d0eef1d1fa260dff751dba9a4258
* elf.h: update with C-SKY definitionsSzabolcs Nagy2019-03-131-1/+57
| | | | | | | C-SKY support was added to binutils 2.32 in commit b8891f8d622a31306062065813fc278d8a94fe21 the elf.h change was added to glibc 2.29 in commit 4975f0c3d0131fdf697be0b1631c265e5fd39088
* netinet/tcp.h: add TCP_NLA_SRTT from linux v5.0Szabolcs Nagy2019-03-131-0/+1
| | | | | smoothed RTT for SCM_TIMESTAMPING_OPT_STATS control messages. added in linux commit e8bd8fca6773ef49390269bd467bf940a0841ccf
* netinet/udp.h: add UDP_GRO from linux v5.0Szabolcs Nagy2019-03-131-0/+1
| | | | | sockopt to enable gro for udp. added in linux commit e20cf8d3f1f763ad28a9cb3b41305b8a8a42653e
* sys/prctl.h: add PR_SPEC_INDIRECT_BRANCH from linux v4.20Szabolcs Nagy2019-03-131-0/+1
| | | | | | prctls to allow per task control of indirect branch speculation on x86. added in linux commit 9137bb27e60e554dab694eafa4cca241fa3a694f
* netinet/in.h add IPV6_MULTICAST_ALL from linux v4.20Szabolcs Nagy2019-03-131-0/+1
| | | | | | ipv6 analogue of IP_MULTICAST_ALL sockopt. added in linux commit 15033f0457dca569b284bef0c8d3ad55fb37eacb
* add PACKET_IGNORE_OUTGOING sockopt from linux v4.20Szabolcs Nagy2019-03-131-0/+1
| | | | new in linux commit fa788d986a3aac5069378ed04697bd06f83d3488
* sys/mman.h: add new hugetlb mmap flags from linux v4.19Szabolcs Nagy2019-03-132-0/+4
| | | | | aarch64 supports 32MB and 512MB hugetlb page sizes too. added in linux commit 20916d4636a9b3c1bf562b305f91d126771edaf9
* elf.h: add new mips core dump note values from linux v4.19Szabolcs Nagy2019-03-131-0/+2
| | | | | | | | NT_MIPS_FP_MODE is new in linux commit 1ae22a0e35636efceab83728ba30b013df761592 NT_MIPS_DSP is new in linux commit 44109c60176ae73924a42a6bef64ef151aba9095
* netinet/udp.h: add UDP_ENCAP_RXRPC from linux v4.19Szabolcs Nagy2019-03-131-0/+1
| | | | | used for optimizing the rxrpc protocol added in linux commit 5271953cad31b97dea80f848c16e96ad66401199
* netinet/tcp.h: add tcp_info fields from linux v4.19Szabolcs Nagy2019-03-131-0/+8
| | | | | | | | | | | | new fields for RFC 4898 tcp stats in linux tcpi_bytes_sent added in commit ba113c3aa79a7f941ac162d05a3620bdc985c58d tcpi_bytes_retrans added in commit fb31c9b9f6c85b1bad569ecedbde78d9e37cd87b tcpi_dsack_dups added in commit 7e10b6554ff2ce7f86d5d3eec3af5db8db482caa tcpi_reord_seen added in commit 7ec65372ca534217b53fd208500cf7aac223a383 The new fields change the size of a public struct and thus an ABI break, but this is how the getsockopt TCP_INFO api is designed: the tcp_info type must only be used with a length parameter in extern interfaces.
* sys/inotify.h: add IN_MASK_CREATE from linux v4.19Szabolcs Nagy2019-03-131-0/+1
| | | | | | inotify_add_watch flag to prevent modifying existing watch descriptors, when used on an already watched inode it fails with EEXIST. added in linux commit 4d97f7d53da7dc830dbf416a3d2a6778d267ae68
* sys/socket.h: add SO_TXTIME from linux v4.19Szabolcs Nagy2019-03-131-0/+2
| | | | added in linux commit 80b14dee2bea128928537d61c333f24cb8cbb62f
* fix POSIX_FADV_DONTNEED/_NOREUSE on s390xJonathan Neuschäfer2019-03-131-0/+2
| | | | | | | | | On s390x, POSIX_FADV_DONTNEED and POSIX_FADV_NOREUSE have different values than on all other architectures that Linux supports. Handle this difference by wrapping their definitions in include/fcntl.h in #ifdef, so that arch/s390x/bits/fcntl.h can override them.
* expose TSVTX unconditionally in tar.hRich Felker2019-03-131-4/+0
| | | | | | | | | | as noted in Austin Group issue #1236, the XSI shading for TSVTX is misplaced in the html version of the standard; it was only supposed to be on the description text. the intent was that the definition always be visible, which is reflected in the pdf version of the standard. this reverts commits d93c0740d86aaf7043e79b942a6c0b3f576af4c8 and 729fef0a9358e2f6f1cd8c75a1a0f7ee48b08c95.
* make FILE a complete type for pre-C11 standard profilesRich Felker2019-03-123-0/+9
| | | | | | | | | | | | | | | | | | | | C11 removed the requirement that FILE be a complete type, which was deemed erroneous, as part of the changes introduced by N1439 regarding completeness of types (see footnote 6 for specific mention of FILE). however the current version of POSIX is still based on C99 and incorporates the old requirement that FILE be a complete type. expose an arbitrary, useless complete type definition because the actual object used to represent FILE streams cannot be public/ABI. thanks to commit 13d1afa46f8098df290008c681816c9eb89ffbdb, we now have a framework for suppressing the public complete-type definition of FILE when stdio.h is included internally, so that a different internal definition can be provided. this is perfectly well-defined, since the same struct tag can refer to different types in different translation units. it would be a problem if the implementation were accessing the application's FILE objects or vice versa, but either would be undefined behavior.
* add membarrier syscall wrapper, refactor dynamic tls install to use itRich Felker2019-02-221-0/+17
| | | | | | | | | | the motivation for this change is twofold. first, it gets the fallback logic out of the dynamic linker, improving code readability and organization. second, it provides application code that wants to use the membarrier syscall, which depends on preregistration of intent before the process becomes multithreaded unless unbounded latency is acceptable, with a symbol that, when linked, ensures that this registration happens.
* update line discipline constantsBobby Bingham2019-02-071-0/+12
|
* move arch-invariant definitions out of bits/ioctl.hBobby Bingham2019-02-071-0/+98
|
* add NT_VMCOREDD to elf.h from linux v4.18Szabolcs Nagy2018-12-091-0/+1
| | | | | used for device driver dump in /proc/vmcore new in linux commit 2724273e8fd00b512596a77ee063f49b25f36507
* add AT_MINSIGSTKSZ to elf.h from linux v4.18Szabolcs Nagy2018-12-091-0/+1
| | | | | | new in linux commit 94b07c1f8c39c6d839df35fa28ffd1785d385897 currently only supported on aarch64
* add TRAP_UNK si_code to signal.h from linux v4.18Szabolcs Nagy2018-12-091-0/+1
| | | | | used for undiagnosed trap exceptions where linux previously set si_code to 0. new in linux commit db78e6a0a6f9f7d7277965600eeb1a5b3a6f55a8
* add SIGSYS support to sys/signalfd.h from linux v4.18Szabolcs Nagy2018-12-091-1/+5
| | | | | | | new in linux commit 76b7f670730e87974f71df9f6129811e2769666e in struct signalfd_siginfo the pad member is changed to __pad to keep the namespace clean, it's not part of the public api.
* add AF_XDP to sys/socket.h from linux v4.18Szabolcs Nagy2018-12-091-1/+4
| | | | | new address family and related macros were added in linux commit 68e8b849b221b37a78a110a0307717d45e3593a0
* update netinet/udp.h for linux v4.18Szabolcs Nagy2018-12-091-0/+3
| | | | | | | add UDP_NO_CHECK6_* to restrict zero UDP6 checksums, new in linux commit 1c19448c9ba6545b80ded18488a64a7f3d8e6998 (pre-v4.18 change, was missed) add UDP_SEGMENT to support generic segmentation offload for udp datagrams, bec1f6f697362c5bc635dacd7ac8499d0a10a4e7 (new in v4.18)