aboutsummaryrefslogtreecommitdiffstats
path: root/man2
AgeCommit message (Collapse)AuthorFilesLines
2016-10-31chroot.2, dup.2, nfsservctl.2, utimensat.2, malloc_get_state.3, ↵Michael Kerrisk4-8/+0
pthread_setaffinity_np.3, ddp.7, fifo.7, ip.7: Remove some out-of-date/obsolete/irrelevant FIXMEs Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-31sync_file_range.2: Fix description for ESPIPE errorMichael Kerrisk1-5/+2
A file descriptor can't refer to a symbolic link. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-31mbind.2: Memory policy is a per-thread attribute, not a per-process attributeMichael Kerrisk1-18/+18
Reviewed-by: Christoph Lameter <cl@linux.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-31readlink.2: tfixDr. Tobias Quathamer1-1/+1
2016-10-31perf_event_open.2: tfixJakub Wilk1-2/+2
Signed-off-by: Jakub Wilk <jwilk@jwilk.net>
2016-10-31futex.2: srcfix: Remove some more or less obsolete FIXMEsMichael Kerrisk1-10/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29sigaction.2: srcfix: FIXME tidy-upMichael Kerrisk1-2/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29memfd_create.2: srcfix: FIXME tidy-upMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29vmsplice.2: srcfix: FIXME tidy-upMichael Kerrisk1-2/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29tkill.2: srcfix: FIXME tidy-upMichael Kerrisk1-18/+20
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29timerfd_create.2: srcfix: FIXME tidy-upMichael Kerrisk1-4/+7
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29ptrace.2: srcfix: FIXME tidy-upMichael Kerrisk1-3/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29get_robust_list.2: srcfix: FIXME tidy-upMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29futex.2: srcfix: FIXME tidy-upMichael Kerrisk1-23/+23
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29adjtimex.2: srcfix: FIXME tidy-upMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29bpf.2: srcfix: FIXME tidy-upMichael Kerrisk1-5/+7
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29perf_event_open.2: srcfix: FIXME tidy-upMichael Kerrisk1-2/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29move_pages.2: srcfix: FIXME tidy-upMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29mount.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29mount.2: srcfix: Remove obsolete FIXMEMichael Kerrisk1-1/+0
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-29mbind.2: srcfix: FIXME tidy-upMichael Kerrisk1-3/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-24perf_event_open.2: Add PERF_SAMPLE_BRANCH_CALL branch sample typeVince Weaver1-4/+8
Linux 4.4 (c229bf9dc179d2023e185c0f705bdf68484c1e73) added the PERF_SAMPLE_BRANCH_CALL branch sample type, which confusingly is a direct-call only subset of what PERF_SAMPLE_BRANCH_ANY_CALL provides. Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-21perf_event_open.2: Update time_shift sample codeVince Weaver1-2/+2
Linux 4.3 (b20112edeadf0b8a1416de061caa4beb11539902) improved the accuracy of the clock/ns conversion routines. As a result the shift factor can now be 32. This value is directly exported in the perf_event_open() mmap page, and this potentially breaks the sample code that shifts 1 left by the shift value. Add a cast in the sample code so that a proper 64-bit value results from the shift. This is the same change that was made to the sample code in include/uapi/linux/perf_event.h in Linux 4.4 (b9511cd761faafca7a1acc059e792c1399f9d7c6). Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-20perf_event_open.2: srcfixMichael Kerrisk1-1/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-20perf_event_open.2: Add cycles field in LBR recordsVince Weaver1-4/+7
Linux 4.3 (71ef3c6b9d4665ee7afbbe4c208a98917dcfc32f) added a cycles field to the PERF_SAMPLE_BRANCH_STACK last branch records. The kernel commit was a bit vague on this, but you can find a few more details on this in the Intel Architectural Manual vol3B. The field indicates the number of core cycles elapsed since the previous update to the LBR stack. This feature is only found on Skylake and newer Intel chips, as well as Intel Atom Goldmont chips. I'm not sure if it's worth adding this info to the manpage, as it seems a bit specific and will probably get rapidly out of date. Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-20perf_event_open.2: tfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-19perf_event_open.2: Minor tweaks to Vince Weaver's patchMichael Kerrisk1-10/+12
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-19perf_event_open.2: PERF_RECORD_SWITCH supportVince Weaver1-5/+84
Linux 4.3 introduced two new record types for recording context switches: PERF_RECORD_SWITCH and PERF_RECORD_SWITCH_CPU_WIDE. The advantage over the existing tracepoint and software context switch events is primarily that full switch in/out data can be gathered even in the face of restrictive perf_event_paranoid settings. Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-18perf_event_open.2: Minor wording tweaks to Vince Weaver's patchMichael Kerrisk1-3/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-18perf_event_open.2: Document PERF_RECORD_MISC_PROC_MAP_PARSE_TIMEOUTVince Weaver1-0/+8
Linux 4.2 reserved a new bit from the misc field in the perf_event_open() mmap sample buffer: PERF_RECORD_MISC_PROC_MAP_PARSE_TIMEOUT Despite being reserved in the public include/uapi/linux/perf_event.h header file, this bit is never set by the kernel. Rather, it is used internally by the user-space "perf" utility to indicate that, when attempting to parse all of the /proc/xxx/maps files for the sample, it ended up taking too long so the scan was aborted. Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-18ioctl_ficlonerange.2, ioctl_fideduperange.2: Clarify the behavior of the ↵Darrick J. Wong2-5/+23
FIDEDUPERANGE ioctl Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
2016-10-18man2/fallocate.2: Document behavior with shared blocksDarrick J. Wong1-0/+10
Note that FALLOC_FL_UNSHARE may use CoW to unshare blocks to guarantee that a disk write won't fail with ENOSPC. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
2016-10-17pkey_alloc.2: tfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17mprotect.2: tfixMichael Kerrisk1-3/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17pkey_alloc.2: Add a pointer to example program in pkeys(7)Michael Kerrisk1-0/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17mprotect.2: Various tweaks to the textMichael Kerrisk1-10/+25
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17mprotect.2: VERSIONS: note kernel version for pkey_mprotect()Michael Kerrisk1-0/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17mprotect.2: CONFORMING TO: note that pkey_mprotect() is Linux-specificMichael Kerrisk1-0/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17pkey_alloc.2: Reorganize textMichael Kerrisk1-28/+29
No content changes. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17pkey_alloc.2: Various tweaks to the textMichael Kerrisk1-19/+23
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17pkey_mprotect.2: New link to mprotect(2)Michael Kerrisk1-0/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17pkey_free.2: New link to new pkey_alloc(2) pageMichael Kerrisk1-0/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17syscalls.2: Add pkey_alloc(), pkey_free(), and pkey_mprotect()Michael Kerrisk1-1/+4
New system calls in Linux 4.9. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17sigaction.2: Further documentation of SEGV_PKUERRDave Hansen1-1/+5
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17pkey_alloc.2: New page documenting pkey_alloc(2) and pkey_free(2)Dave Hansen1-0/+124
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
2016-10-17mprotect.2: Document pkey_mprotect() system callDave Hansen1-3/+41
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
2016-10-17perf_event_open.2: tfixMichael Kerrisk1-6/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: Clarify the use of signals for capturing overflow eventsMichael Kerrisk1-4/+7
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: Minor wording fixesMichael Kerrisk1-18/+23
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: tfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: ffixMichael Kerrisk1-61/+61
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-17perf_event_open.2: PERF_RECORD_LOST_SAMPLES record typeDave Hansen1-0/+19
Linux 4.2 added a new record type: PERF_RECORD_LOST_SAMPLES It is generated when hardware samples (currently only Intel PEBS) are lost. Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-15perf_event_open.2: PERF_SAMPLE_BRANCH_IND_JUMP branch_sample_typeVince Weaver1-0/+4
Linux 4.2 added a new branch_sample_type: PERF_SAMPLE_BRANCH_IND_JUMP Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-14perf_event_open.2: wfixMichael Kerrisk1-15/+13
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-14perf_event_open.2: ffixMichael Kerrisk1-11/+16
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-14perf_event_open.2: ffixMichael Kerrisk1-7/+0
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-14perf_event_open.2: Minor tweaks to Vince Weaver's patchMichael Kerrisk1-3/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-14perf_event_open.2: Document sample_max_stack and ↵Vince Weaver1-1/+28
/proc/sys/kernel/perf_event_max_stack Linux 4.8 added a new sample_max_stack parameter, as well as /proc/sys/kernel/perf_event_max_stack which limits it and a new EOVERFLOW error return. Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
2016-10-13clone.2: Minor wording fixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13clone.2: The CLONE_*_SETTID operations store TID before return to user spaceMichael Kerrisk1-0/+6
CLONE_PARENT_SETTID and CLONE_CHILD_SETTID store the new TID before clone() returns to user space Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13clone.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13get_mempolicy.2: Note that 'addr' must be NULL when 'flags' is 0Michael Kerrisk1-0/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13get_mempolicy.2: wfixMichael Kerrisk1-3/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13get_mempolicy.2: wfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13get_mempolicy.2: tfixMichael Kerrisk1-6/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2, set_mempolicy.2: tfixMichael Kerrisk2-4/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13set_mempolicy.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2: Reformat list of mode valuesMichael Kerrisk1-11/+13
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2, set_mempolicy.2: wfix: "ids" --> "IDs"Michael Kerrisk2-6/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2: ffixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2: wfixMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2, set_mempolicy.2: wfixMichael Kerrisk2-5/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13set_mempolicy.2: Reformat list of modesMichael Kerrisk1-10/+13
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13set_mempolicy.2: tfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2, set_mempolicy.2: Add kernel version for MPOL_LOCALMichael Kerrisk2-2/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13set_mempolicy.2: wfixMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2: Minor wording fixMichael Kerrisk1-3/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13open.2: ubifs supports O_TMPFILE starting with Linux 4.9Michael Kerrisk1-4/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-13mbind.2: srcfix: remove a FIXMEMichael Kerrisk1-9/+0
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-12killpg.2, crypt.3, mbsinit.3, printf.3, rpc.3, ulimit.3, wprintf.3, xdr.3, ↵Michael Kerrisk1-1/+1
fd.4, elf.5, group.5: tfix Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-12mbind.2, set_mempolicy.2: Minor tweaks to Piotr Kwapulinski's patchMichael Kerrisk2-10/+10
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-12mbind.2, set_mempolicy.2: srcfix: rewarp source linesMichael Kerrisk2-16/+19
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-12set_mempolicy.2,mbind.2: Add MPOL_LOCAL NUMA memory policy documentationPiotr Kwapulinski2-5/+42
The MPOL_LOCAL mode has been implemented by Peter Zijlstra <a.p.zijlstra@chello.nl> (commit: 479e2802d09f1e18a97262c4c6f8f17ae5884bd8). Add the documentation for this mode. Reviewed-by: Christoph Lameter <cl@linux.com> Signed-off-by: Piotr Kwapulinski <kwapulinski.piotr@gmail.com>
2016-10-12posix_fadvise.2: tfixMichael Kerrisk1-1/+1
Reported-by: Marcos Mello <marcosfrm@gmail.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-08clone.2: tfixMichael Kerrisk1-1/+1
Reported-by: Elliott Hughes <enh@google.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-08Removed trailing white space at end of linesMichael Kerrisk1-1/+1
2016-10-08memusage.1, memusagestat.1, pldd.1, accept.2, adjtimex.2, arch_prctl.2, ↵Michael Kerrisk70-70/+70
bdflush.2, bpf.2, close.2, epoll_ctl.2, epoll_wait.2, execve.2, execveat.2, fanotify_init.2, fanotify_mark.2, fcntl.2, fsync.2, get_kernel_syms.2, getdomainname.2, getgroups.2, gethostname.2, getrandom.2, getrlimit.2, getrusage.2, getsid.2, getunwind.2, io_getevents.2, ioctl_fat.2, kexec_load.2, killpg.2, listxattr.2, lseek.2, madvise.2, memfd_create.2, mknod.2, mlock.2, modify_ldt.2, msgctl.2, msgget.2, msgop.2, readlink.2, readv.2, reboot.2, recvmmsg.2, rename.2, request_key.2, restart_syscall.2, sched_setaffinity.2, sched_setattr.2, sched_setparam.2, seccomp.2, select_tut.2, semctl.2, semget.2, semop.2, set_thread_area.2, seteuid.2, setgid.2, setpgid.2, setresuid.2, setreuid.2, setsid.2, setuid.2, shmctl.2, shmget.2, shmop.2, sigaction.2, sigprocmask.2, stat.2, symlink.2, syscall.2, sysctl.2, unlink.2, bindresvport.3, byteorder.3, dlopen.3, endian.3, error.3, ffs.3, fmemopen.3, getcwd.3, getlogin.3, getnetent.3, getprotoent.3, getservent.3, getumask.3, getutent.3, glob.3, isalpha.3, lio_listio.3, login.3, mbsinit.3, mbstowcs.3, mbtowc.3, mkstemp.3, nextup.3, ntp_gettime.3, posix_fallocate.3, posix_spawn.3, pthread_join.3, pthread_rwlockattr_setkind_np.3, random.3, rcmd.3, realpath.3, resolver.3, setjmp.3, setnetgrent.3, sigvec.3, strerror.3, strverscmp.3, system.3, toupper.3, towlower.3, towupper.3, wcstombs.3, wordexp.3, cciss.4, loop.4, mouse.4, random.4, core.5, group.5, hosts.5, resolv.conf.5, ascii.7, environ.7, epoll.7, glob.7, ip.7, mq_overview.7, packet.7, pipe.7, raw.7, sched.7, signal.7, socket.7, symlink.7, ld.so.8, sln.8: tstamp Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-08keyctl.2: Revert "keyctl.2: updates regarding command usage, return values ↵Michael Kerrisk1-568/+51
and error codes" This reverts commit 8ec6a2110b8ae33211b8cd33670c28a953ada9f7. This patch was accidentally applied in master. The patch needs more work before it can be released.
2016-10-07getrusage.2, madvise.2, memfd_create.2, mlock.2, mount.2, getauxval.3, ↵Michael Kerrisk5-6/+6
core.5, capabilities.7, pid_namespaces.7, symlink.7, user_namespaces.7: Consistently use /proc/[pid] (not /proc/PID) Reported-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-07adjtimex.2: Fix kernel version referencesNikola Forró1-3/+3
ADJ_SETOFFSET mode was added in 2.6.39: $ git tag --contains 094aa1881fdc1b8889b442eb3511b31f3ec2b762 | head -n 1 v2.6.39 ADJ_MICRO and ADJ_NANO modes were added in 2.6.26: $ git tag --contains eea83d896e318bda54be2d2770d2c5d6668d11db | head -n 1 v2.6.26 Signed-off-by: Nikola Forró <nforro@redhat.com>
2016-10-07nanosleep.2: wfix: rework some text around historical behaviorMichael Kerrisk1-2/+1
Referring to "current" Linux 2.4 kernels is strange... Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-07nanosleep.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-07getunwind.2: Simplify text referring to vdso(7)Michael Kerrisk1-6/+2
The detail given here is redundant, since this info is also in vdso(7). Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-07semctl.2: wfix: CONFORMING TO: change a POSIX.1-2001 to POSIX.1-2008Bill Pemberton1-1/+1
The section had POSIX.1-2001 listed twice in a row instead of POSIX.1-2001 and POSIX.1-2008 Signed-off-by: Bill Pemberton <wfp5p@worldbroken.com>
2016-10-07open.2: F2FS support for O_TMPFILE was added in Linux 3.16Michael Kerrisk1-2/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-07keyctl.2: updates regarding command usage, return values and error codesEugene Syromyatnikov1-51/+568
Hello. I've drafted some updates to the keyctl.2 man page while preparing test for strace syscall decoder. It is focused mostly on description of argument format used in various commands and return values/error codes. Information is based on Documentation/security/keys.txt, include/uapi/linux/keyctl.h, and source code and comments in security/keys/ (mostly comments from security/keys/keyctl.c). Hope you find it useful.
2016-10-07clone.2: Document raw syscall interfaces on various other architecturesMichael Kerrisk1-14/+48
Reported-by: Josh Triplett <josh@joshtriplett.org> Reviewed-by: Josh Triplett <josh@joshtriplett.org> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-10-07clone.2: Change types for 'ptid' and 'ctid' in syscall prototypesMichael Kerrisk1-2/+2
These types changed from 'void *' to 'int *' back in Linux 3.8. The new types are closer to reality, so just update the page without discussing the history. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-25clone.2: Adjust syscall prototype and expand CLONE_SETTLS descriptionKeno Fischer1-6/+20
The prototype for the system call was added in kernel commit 81f10dad, but looking at the kernel's fork.c, I believe the relevant definition is SYSCALL_DEFINE5(clone, unsigned long, clone_flags, unsigned long, newsp, int __user *, parent_tidptr, int __user *, child_tidptr, unsigned long, tls) so the last argument is the tls argument, not a pt_regs argument. I stumbled upon this while trying to understand CLONE_SETTLS, so I expanded that description a little to cover other architectures. Reviewed-by: Josh Triplett <josh@joshtriplett.org>
2016-09-22execve.2: Note that real UID, real GID, and supplementary GIDs are unchangedMichael Kerrisk1-0/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-22fork.2: ffixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-22fork.2: PID of new process also does not match any existing session IDMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-22quotactl.2: wfixMichael Kerrisk1-8/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-22quotactl.2: ffixMichael Kerrisk1-92/+95
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-21quotactl.2: Tweaks to Eugene Syromyatnikov's patchesMichael Kerrisk1-91/+124
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-21quotactl.2: wfixEugene Syromyatnikov1-3/+3
2016-09-21quotactl.2: Updated information regarding XFS-specific quotactl subcommandsEugene Syromyatnikov1-22/+215
Added information regarding structure definitions used for XFS-specific subcommands, updated flag constants, added information regarding ignored syscall arguments, added notes on usage of kernel UAPI header.
2016-09-21quotactl.2: Updated information regarding disk quota flagsEugene Syromyatnikov1-2/+5
Added information regarding DQF_SYS_FILE flag; updated definition of V1_DQF_RSQUASH, which has been defined privately and defined publicly as DQF_ROOT_SQUASH.
2016-09-21quotactl.2: Additions regarding project quotasEugene Syromyatnikov1-4/+6
Added information regarding presence of project quotas.
2016-09-21prctl.2: Simplify list of cases where "dumpable" attribute is resetMichael Kerrisk1-28/+6
Simplify list of cases that cause dumpable attribute to reset to suid_dumpable: there were two lists that together in effect had many duplicates. Also some minor rewordings. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-21prctl.2: Refer to proc(5) for effects of dumpability on ownership of /proc/PID/*Michael Kerrisk1-0/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-21prctl.2: Minor fix: add a reference to ptrace(2) for PR_SET_DUMPABLEMichael Kerrisk1-1/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-20epoll_wait.2: Clarify that the timeout is measured against CLOCK_MONOTONICMike Crowe1-0/+3
The existing page left the choice of clock as ambiguous. My reading of the kernel implementation is that CLOCK_MONOTONIC is always used since ep_poll() calls schedule_hrtimeout_range(), which calls schedule_hrtimeout_range_clock() passing CLOCK_MONOTONIC. References: http://lxr.free-electrons.com/source/fs/eventpoll.c?v=4.7#L1614 http://lxr.free-electrons.com/source/kernel/time/hrtimer.c?v=4.7#L1785 The "measured against" terminology was borrowed from nanosleep.2. I've checked all the way back to Linux v2.6.12 where the calculation was done using jiffies so I think that this has effectively always been true. Signed-off-by: Mike Crowe <mac@mcrowe.com>
2016-09-16futex.2: srcfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-16bpf.2: srcfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-16clone.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-16execve.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-16prctl.2: ERRORS: Add EACCES error for PR_SET_SECCOMP-SECCOMP_MODE_FILTERMichael Kerrisk1-0/+16
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-15clone.2: EINVAL is generated by glibc wrapper for NULL 'fn' or 'child_stack'Michael Kerrisk1-3/+6
Clarify that this error is produced by the wrapper function, not the underlying system call. In particular, the point is that the raw system call can accommodate a NULL pointer for 'child_stack'. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12open.2: Clarify user namespace capability requirements for O_NOATIMEMichael Kerrisk1-2/+15
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12msgctl.2, msgget.2, msgop.2, semctl.2, semget.2, semop.2, shmctl.2, ↵Michael Kerrisk9-9/+9
shmget.2, shmop.2: Note the user namespace requirements for CAP_IPC_OWNER Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12chroot.2: Note user namespace requirements for CAP_SYS_CHROOTMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setuid.2: Note user namespace requirements for CAP_SETUIDMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setreuid.2: Note user namespace requirements for CAP_SETUID and CAP_SETGIDMichael Kerrisk1-4/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setresuid.2: Note user namespace requirements for CAP_SETUIDMichael Kerrisk1-2/+11
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setgid.2: Note user namespace requirements for CAP_SETGIDMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setgid.2: ffixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12seteuid.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12seteuid.2: Note user namespace requirements for CAP_SETUID and CAP_SETGIDMichael Kerrisk1-13/+16
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setuid.2: wfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setresuid.2: wfixMichael Kerrisk1-4/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setgid.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12kill.2: Minor wording fixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12kill.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12seccomp.2: CAP_SYS_ADMIN is required only in caller's user namespaceMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12getrlimit.2: Note user namespace semantics for CAP_SYS_RESOURCEMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12getgroups.2: Note user namespace requirements for CAP_SETGIDMichael Kerrisk1-5/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12getdomainname.2: Note user namespace requirements for CAP_SYS_ADMINMichael Kerrisk1-2/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12gethostname.2: Note user namespace requirements for CAP_SYS_ADMINMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12prctl.2: Note user namespace requirements for PR_CAPBSET_DROP CAP_SETPCAPMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12reboot.2: Note user namespace requirements around CAP_SYS_BOOTMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12sched_setaffinity.2: Note user namespace requirements for CAP_SYS_NICEMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12kill.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12kill.2: srcfixMichael Kerrisk1-3/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12kill.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12kill.2: Note the user namespace requirement for CAP_KILLMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12killpg.2: Refer reader to kill(2) for signal permission rulesMichael Kerrisk1-10/+4
Rather than repeating details here, refer the reader to kill(2) (so that the rules are in a canonical location, and need only be edited in one place for future changes--see next commit). Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12fcntl.2: Note an important detail of F_SETOWN permission rules for signalsMichael Kerrisk1-0/+7
F_SETOWN records the caller's credentials at the time of the fcntl() call, and it is these saved credentials that are used for subsequent permission checks. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12close.2: Add mention of the close-on-exec flagMichael Kerrisk1-0/+7
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12umask.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12open.2: Clarify the rules about how the group ID of a new file is determinedMichael Kerrisk1-5/+10
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12open.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12open.2: ffixMichael Kerrisk1-0/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12getsid.2: Rework description to be somewhat clearerMichael Kerrisk1-4/+12
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setsid.2: Refer to credentials(7) for details for details on controlling ↵Michael Kerrisk1-1/+4
terminal Refer to credentials(7) for details of how a session obtains a controlling terminal. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12getsid.2: wfixMichael Kerrisk1-2/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12getsid.2: Correct the definition of "session ID"Michael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setpgid.2: Minor wording fixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setsid.2: Minor wording fixesMichael Kerrisk1-3/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setpgid.2, setsid.2: Relocate some text on sessions and sessions leadersMichael Kerrisk2-10/+10
Some text that was in setpgid(2) is better placed in setsid(2). Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12setpgid.2: Add a reference to credentials(7)Michael Kerrisk1-0/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12execve.2: Mention use of 'environ' to access environment listMichael Kerrisk1-0/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12execve.2: Minor clarificationMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12execve.2: wfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12execve.2: Minor clarificationMichael Kerrisk1-3/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12execve.2: ffixMichael Kerrisk1-0/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12execve.2: Minor clarificationMichael Kerrisk1-2/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12fcntl.2: Make the description of the effect of close-on-exec a little clearerMichael Kerrisk1-3/+10
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12close.2: Clarify discussion noting that close() does not flush buffer cacheMichael Kerrisk1-4/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-12fcntl.2: Clarify that F_GETFD and F_GETFL return flags via the function resultMichael Kerrisk1-2/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-09clone.2: wfixMichael Kerrisk1-2/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-04readv.2: Clarify that RWF_DSYNC and RWF_SYNC apply only to data being writtenMichael Kerrisk1-2/+4
Reported-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-04readv.2: Document the pwritev2() RWF_SYNC and RWF_DSYNC flagsMichael Kerrisk1-0/+18
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-04rename.2: Minor wording fixMichael Kerrisk1-3/+1
The meaning of "when overwriting" is not clear. I believe what is meant is that when an existing 'newpath' is replaced. However, we can convey that meaning by eliding this text with the preceding paragraph, so this patch does that. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-04rename.2: Relocate some text textMichael Kerrisk1-7/+7
Relocate text noting that there may be a window when 'oldpath' and 'newpath' refer to the same file. Logically, this text appears to belong near the text noting that an existing 'newpath' will be atomically replaced. (In ancient versions of the page, these two pieces of text were closer together.) Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-09-04rename.2: Clarify that ERRORS may cause rename to fail (not to be nonatomic)Michael Kerrisk1-2/+4
The existing wording suggests that there are ERRORS that may cause the operation to be nonatomic. The point is of course that there are various restrictions on rename operations that may cause the operation to fail. Reported-by: Tim Savannah <kata198@gmail.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-31mlock.2: Minor tweaks to Sebastian Andrzej Siewior's patchMichael Kerrisk1-7/+7
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-31mlock.2: Document that fork() after mlock() may be a bad idea in a RT processSebastian Andrzej Siewior1-0/+14
fork() will remove the write PTE bit from the page table on each VMA which will be copied via COW. As such, the memory is available but marked read only in the page table and will fault on write access. This renders the previous mlock() operation almost useless because in a multithreaded application a realtime thread may block on mmap_sem while a thread with low priority is holding the mmap_sem (for instance because it is allocating memory which needs to be mapped in). There is actually nothing we can do to mitigate the outcome. We could add a warning to the kernel for people that are not yet aware of the updated documentation. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
2016-08-31stat.2: Tweak discussion of 'st_size' for /proc and /sys filesMichael Kerrisk1-1/+1
As Mats points out, there appear to be no (or almost no) files under /proc and /sys for which 'st_size' is meaningful. (mtk: verified via some scripting over these directories.) Reported-by: Mats Wichmann <mats@wichmann.us> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-29stat.2: Improve discussion of 'st_size' for /proc and /sys filesMichael Kerrisk1-5/+13
Reported-by: Ursache Vladimir <f35f22fan@gmail.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-29epoll_ctl.2: tfixRuben Kerkhof1-1/+1
2016-08-29epoll_ctl.2: tfixRuben Kerkhof1-1/+1
2016-08-28sigprocmask.2: Minor fixes to Keno Fischer's patchMichael Kerrisk1-5/+5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-28sigprocmask.2: Expand/clarify libc/kernel sigset_t differenceKeno Fischer1-10/+39
Expand and clarify libc/kernel sigset_t differences. Also move up the signature for rt_sigprocmask, similar to the way this is done in clone.2. Due to the history of sigprocmask, there are various notions of what sigset_t refers to. This attempts to clarify the man page, by giving the major instances different names: - sigset_t is the glibc sigset_t (1024 bits) - kernel_sigset_t is the kernel's sigset_t (64 bits) - old_kernel_sigset_t is the pre-rt kernel's sigset_t (32 bits) and explaining their difference in the NOTES. Even though the sources do not refer to the various sigset_t's by these names, I think it is important to be explicit, esp since sizeof(sigset_t) would give an incorrect value for `sigsetsize` if written in a source file that includes the libc headers. Lastly, move the note on an incorrect `sigsetsize` causing EINVAL up to the ERRORS section, so everything is in one place.
2016-08-24clone.2: tfixMichael Kerrisk1-1/+1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-24clone.2: Make the implications of CLONE_FILES more explicitMichael Kerrisk1-4/+5
If CLONE_FILES is not set, the duplicated FDs nevertheless share file offset and status flags via the open file description. Reported-by: Elliott Hughes <enh@google.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-24fcntl.2: Minor wording fix for F_DUPFDMichael Kerrisk1-5/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-23accept.2: tfixMichael Kerrisk1-5/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-23accept.2: Demote discussion of DECNet to NOTESMichael Kerrisk1-13/+14
DECNet ceased to be important long ago... Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-23accept.2: Mention epoll(7) alongside poll()/select()Michael Kerrisk1-4/+6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-22fanotify_init.2: Update BUGS informationMichael Kerrisk1-3/+2
Patch 0b37e097a648aa71d4db1ad108001e95b69a2da4 was included in Linux 3.18. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2016-08-20readlink.2: Make example program handle links that report a size of zeroMichael Kerrisk1-13/+24
Some "magic" symlinks created by the kernel (e.g., those under /proc and /sys) report 'st_size' as zero. Modify the example program to handle that possibility. Reported-by: Ursache Vladimir <f35f22fan@gmail.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-20readlink.2: Emphasize that truncation of returned buffer generates no errorMichael Kerrisk1-1/+4
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-17mmap.2: Small improvement to description of MAP_SHAREDMichael Kerrisk1-2/+3
See https://sourceware.org/bugzilla/show_bug.cgi?id=6887 Reported-by: Siward de Groot <siward@wanadoo.nl> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-17open.2: Minor layout fix in ERRORSMichael Kerrisk1-1/+3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-17fcntl.2: ffixMichael Kerrisk1-0/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2016-08-12select_tut.2: ffixMichael Kerrisk1-1/+2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>