aboutsummaryrefslogtreecommitdiffstats
path: root/man
AgeCommit message (Collapse)AuthorFilesLines
6 daysman/: SYNOPSIS: Don't highlight forward declarations of function parametersHEADmasterAlejandro Colomar139-237/+237
Previously, many people confused these for actual parameters, since it's hard to distinguish a ',' from ';'. By removing bold/italics from these, it will be easier to distinguish them. The cases have been found with a script: $ find -type f \ | xargs grep -l '^\.TH ' \ | sort \ | xargs mansect SYNOPSIS \ | man /dev/stdin \ | grep -e '^[^ ]' -e '[^ ]( [^ )].*[^)];' \ | less; Reported-by: Mark Naughton <mnaughto@redhat.com> Suggested-by: Mark Harris <mark.hsj@gmail.com> Acked-by: Mark Naughton <mnaughto@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man3attr/gnu::aligned.3attr: Add pageAlejandro Colomar1-0/+51
Cc: Aaron Ballman <aaron@aaronballman.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man3attr/intro.3attr: Add pageAlejandro Colomar1-0/+49
Cc: Aaron Ballman <aaron@aaronballman.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man3/ftime.3: Reorder and clarify STANDARDSCollin Funk1-2/+3
Put 4.2BSD first and mention that POSIX.1-2001 marked this function as LEGACY. Signed-off-by: Collin Funk <collin.funk1@gmail.com> Message-ID: <fcc66f4d8694f933a71688ad529e6f4f43024658.1750646692.git.collin.funk1@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man2/chmod.2: Document AT_SYMLINK_NOFOLLOW support in fchmodat(2)Benjamin Peterson1-1/+4
Historically, Linux systems did not support the AT_SYMLINK_NOFOLLOW flag to fchmodat(2). glibc added userspace emulation support in glibc 2.32, and Linux gained native support in 6.5. See glibc.git 6b89c385d8bd (2020-02-12; "io: Implement lchmod using fchmodat [BZ #14578]") and linux.git 09da082b07bb (2023-07-27; "fs: Add fchmodat2()"). Signed-off-by: Benjamin Peterson <benjamin@locrian.net> Message-ID: <20250619051342.145412-2-benjamin@locrian.net> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man2/statx.2: Add stx_atomic_write_unit_max_optJohn Garry1-1/+20
XFS supports atomic writes - or untorn writes - based on two different methods: - HW offload in the disk - FS method based on out-of-place writes The value reported in stx_atomic_write_unit_max will be the max size of the FS-based method. The max atomic write unit size of the FS-based atomic writes will typically be much larger than what is capable from the HW offload. However, FS-based atomic writes will also be typically much slower. Advertise this HW offload size limit to the user in a new statx member, stx_atomic_write_unit_max_opt. We want STATX_WRITE_ATOMIC to get this new member in addition to the already-existing members, so mention that a value of 0 in stx_atomic_write_unit_max_opt means that stx_atomic_write_unit_max holds this optimised limit. Linux will zero unused statx members, so stx_atomic_write_unit_max_opt will always hold 0 for older kernel versions which do not support this FS-based atomic write method (for XFS). Signed-off-by: John Garry <john.g.garry@oracle.com> Message-ID: <20250619154455.321848-3-john.g.garry@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man2/statx.2: Properly align stx_dio_read_offset_alignJohn Garry1-1/+1
Align this member in struct statx with the members above it. Signed-off-by: John Garry <john.g.garry@oracle.com> Message-ID: <20250619154455.321848-2-john.g.garry@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man5/elf.5: Clarify string table reference for SHT_SYMTAB sectionsDacian Pascu1-0/+4
Add clarification that for SHT_SYMTAB sections, the associated string table section index can be found in the sh_link member, following the same pattern documented for section header string tables. This was discovered while writing an ELF parser, where the sh_link field is needed to locate the string table for symbol name lookups in SHT_SYMTAB sections. Signed-off-by: Dacian Pascu <pascu.dacian@gmail.com> Message-ID: <78e41dade449bafddfb730b39226f8d9cb3fefdb.1750427945.git.pascu.dacian@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man3/malloc.3: Shorten parameter name (s/ptr/p/)Alejandro Colomar1-17/+17
Signed-off-by: Alejandro Colomar <alx@kernel.org>
6 daysman/man2/cachestat.2: Add pageMatteo Croce1-0/+112
The text was converted from the commit message in linux.git cf264e1329fb (2023-06-09; "cachestat: implement cachestat syscall"). Link: <https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=cf264e1329fb0307e044f7675849f9f38b44c11a> Signed-off-by: Nhat Pham <nphamcs@gmail.com> Signed-off-by: Matteo Croce <teknoraver@meta.com> Message-ID: <20250611141350.1829-1-technoboy85@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-19man/man5/core.5: Document the new %F identifier in core_patternJelle van der Waa1-0/+5
Signed-off-by: Jelle van der Waa <jvanderw@redhat.com> Message-ID: <20250616133212.131064-1-jvanderwaa@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-19man/man2/chmod.2: Document fchmodat(AT_EMPTY_PATH)Aleksa Sarai1-1/+24
The documentation and behaviour is indentical to the equivalent flag for fchownat(2). Signed-off-by: Aleksa Sarai <cyphar@cyphar.com> Message-ID: <20250619-fchmod-empty-path-v1-1-feff2c63abe4@cyphar.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-11man/man2/prctl.2, man/man2const/PR_FUTEX_HASH.2const: Document PR_FUTEX_HASHSebastian Andrzej Siewior2-0/+94
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Message-ID: <20250602140104.2769223-2-bigeasy@linutronix.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-11man/man1/iconv.1: Mention that -c does not change exit statusFlorian Weimer1-1/+6
And that input decoding failures are treated as errors. Exiting with status 0 is a POSIX conformance issue that was fixed in glibc 2.41. Signed-off-by: Florian Weimer <fweimer@redhat.com> Message-ID: <87msamxso9.fsf@oldenburg.str.redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-11man/man2/ioctl_vt.2: Document VT_GETCONSIZECSRPOSNicolas Pitre2-0/+19
Corresponding code is in drivers/tty/vt/vt_ioctl.c. New in Linux v6.16. Signed-off-by: Nicolas Pitre <npitre@baylibre.com> Message-ID: <4n723o1q-pr52-319q-nsr7-6442387s12s2@onlyvoer.pbz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-11man/man2const/TIOCLINUX.2const: Document TIOCL_GETBRACKETEDPASTENicolas Pitre1-0/+8
Corresponding code is in drivers/tty/vt/vt.c:tioclinux(). New in Linux v6.16. Signed-off-by: Nicolas Pitre <npitre@baylibre.com> Message-ID: <o5p79351-1ops-on58-3o20-rp142r6s4o21@onlyvoer.pbz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-08man/man3/scalb*.3: NAME: Document the meaning of the name of these functionsAlejandro Colomar2-3/+4
Cc: Alex Celeste <alexg.nvfp@gmail.com> Reported-by: Jorenar <dev@jorenar.com> Suggested-by: "Fred J. Tydeman" <tydeman@tybor.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-05man/man3/inet_net_pton.3: SYNOPSIS: ffixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-05man/man3/: Shorten parameter namesAlejandro Colomar2-13/+13
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-05man/: SYNOPSIS: Use array notationAlejandro Colomar4-8/+10
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-02man/man2const/PR_SET_MM_AUXV.2const: SYNOPSIS: Fix position of #include lineAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-02man/man2const/: TH: Fix subsectionAlejandro Colomar2-2/+2
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-06-01man/man2const/KEYCTL_SESSION_TO_PARENT.2const: SYNOPSIS: ffixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-31man/man2/: Fix broken references to proc_sys_vm(5)Ahelenia Ziemiańska2-3/+3
Fixes: 0569afbbccd6 (2023-08-17; "proc*.5: Make sashimi") Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Message-ID: <c28f98b90ff40c3944aaa3189627d795e0c2d9f6.1748714599.git.nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-31man/: Fix name of /proc/sys/vm/hugetlb_shm_groupAhelenia Ziemiańska4-7/+7
sysctl_hugetlb_shm_group is the name of the variable in "mm/hugetlb.c". Fixes: 090fdddb4342 (2021-05-17; "memfd_create.2, mmap.2, shmget.2: Document the EPERM for huge page allocations") Fixes: 6cee0ddeb414 (2021-05-17; "proc.5: Document /proc/sys/vm/sysctl_hugetlb_shm_group") Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Message-ID: <22436441b7bac0177213c99c55187c4af085d4ca.1748714599.git.nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/mbind.2: SYNOPSIS: ffixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/: SYNOPSIS: Use array notationAlejandro Colomar2-4/+7
Signed-off-by: Alejandro Colomar <alx@kernel.org> ar
2025-05-30man/man2/open.2: Fix doc for O_CREAT | O_DIRECTORYPaul Eggert1-14/+10
Although Linux kernels before 5.7 would create a regular file when opening a nonexistent file with O_CREAT | O_DIRECTORY, this behavior was changed to something deeply buggy in 5.7, and when the bug was fixed in 6.4 this combination of open flags became invalid. Adjust the documentation to match the 6.4+ behavior, which makes more sense anyway. Signed-off-by: Paul Eggert <eggert@cs.ucla.edu> Message-ID: <20250530072029.344532-1-eggert@cs.ucla.edu> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2: Tweak after making sashimi of this pageAlejandro Colomar1-55/+12
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_WAIT_REQUEUE_PI.2const: Tweak after splitAlejandro Colomar1-7/+5
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_WAIT_REQUEUE_PI.2const: Split ↵Alejandro Colomar2-106/+135
FUTEX_WAIT_REQUEUE_PI from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_CMP_REQUEUE_PI.2const: Tweak after splitAlejandro Colomar1-17/+11
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_CMP_REQUEUE_PI.2const: Split ↵Alejandro Colomar2-185/+224
FUTEX_CMP_REQUEUE_PI from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_UNLOCK_PI.2const: Tweak after splitAlejandro Colomar1-5/+4
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_UNLOCK_PI.2const: Split ↵Alejandro Colomar2-50/+80
FUTEX_UNLOCK_PI from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_TRYLOCK_PI.2const: Tweak after splitAlejandro Colomar1-4/+3
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_TRYLOCK_PI.2const: Split ↵Alejandro Colomar2-69/+125
FUTEX_TRYLOCK_PI from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_LOCK_PI2.2const: Tweak after splitAlejandro Colomar1-71/+6
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_LOCK_PI2.2const: Split FUTEX_LOCK_PI2 ↵Alejandro Colomar2-39/+127
from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_LOCK_PI.2const: Tweak after splitAlejandro Colomar1-34/+30
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_LOCK_PI.2const: Split FUTEX_LOCK_PI ↵Alejandro Colomar2-156/+238
from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_WA??_BITSET.2const: Tweak after split, and add link pageAlejandro Colomar2-6/+6
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_WAIT_BITSET.2const: Split ↵Alejandro Colomar2-152/+228
FUTEX_WAIT_BITSET and FUTEX_WAKE_BITSET from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_WAKE_OP.2const: Tweak after splitAlejandro Colomar1-21/+18
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_WAKE_OP.2const: Split FUTEX_WAKE_OP ↵Alejandro Colomar2-160/+216
from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_CMP_REQUEUE.2const: Tweak after splitAlejandro Colomar1-11/+10
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_CMP_REQUEUE.2const: Split ↵Alejandro Colomar2-135/+196
FUTEX_CMP_REQUEUE from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_REQUEUE.2const: Tweak after splitAlejandro Colomar1-8/+5
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_REQUEUE.2const: Split FUTEX_REQUEUE ↵Alejandro Colomar2-18/+71
from futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_FD.2const: Tweak after splitAlejandro Colomar1-4/+3
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_FD.2const: Split FUTEX_FD from futex(2)Alejandro Colomar2-51/+80
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_WAKE.2const: Tweak after splitAlejandro Colomar1-6/+7
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_WAKE.2const: Split FUTEX_WAKE from ↵Alejandro Colomar2-52/+90
futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2const/FUTEX_WAIT.2const: Tweak after splitAlejandro Colomar1-28/+25
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2, man/man2const/FUTEX_WAIT.2const: Split FUTEX_WAIT from ↵Alejandro Colomar2-112/+181
futex(2) Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2: De-duplicate information about timeoutsAlejandro Colomar1-18/+10
And be more explicit about the one case that's different. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/futex.2: Prepare for sashimiAlejandro Colomar1-20/+17
- Remove dead code (redundant .P). - Adjust white space. - Remove redundant note. - Use the same language as always about returning -1 and setting errno. - Split errors. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-30man/man2/sched_setaffinity.2: EXAMPLES: Use 0 instead of getpid()Ahelenia Ziemiańska1-2/+2
getpid() is superfluous here. Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Message-ID: <v5p4zfqrepnrorszmuie47aiulivcykicxuhtxfkqhrq5t3cis@tarta.nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-28man/man2/link.2: Update manual page referenceAlejandro Colomar1-1/+1
proc(5) was split into many small pages recently. Reported-by: Pali Rohár <pali@kernel.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-27man/man2/futex.2: wfixAlejandro Colomar1-2/+8
Suggested-by: Carlos O'Donell <carlos@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-27man/man2/futex.2: tfixAlejandro Colomar1-1/+1
Fixes: 3dfcc11d4630 (2015-12-15; "futex.2: Expand description of FUTEX_CMP_REQUEUE") Fixes: 8297383e9eeb (2015-12-15; "futex.2: Clean-ups and FIXME removeal after feedback from Thomas Gleixner") Reported-by: Jens Gustedt <jens.gustedt@inria.fr> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-24man/man5/proc_meminfo.5: Shmem also accounts for other types of shared memoryAlejandro Colomar1-1/+5
Reported-by: Carsten Grohmann <carstengrohmann@gmx.de> Message-ID: <20250523122617.48cf9feb@max.localdomain> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-22man/man2/syscall.2: x86-64 + x32 syscall numbers go in eaxBen Kallus1-2/+2
The kernel sign-extends eax before dispatching syscalls. From arch/x86/entry/entry_64.S: > movslq %eax, %rsi > IBRS_ENTER > UNTRAIN_RET > CLEAR_BRANCH_HISTORY > > call do_syscall_64 /* returns with IRQs disabled */ This patch updates syscall.2 to document this. ARM64 exhibits a similar behavior (w8 is extended), which is already documented. Signed-off-by: Ben Kallus <benjamin.p.kallus.gr@dartmouth.edu> Message-ID: <20250518234507.404608-1-benjamin.p.kallus.gr@dartmouth.edu> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-21man/man3/mbrtowc.3: RETURN VALUE: Tweak description of -2 returnSteffen Nurpmeso1-3/+3
Signed-off-by: Steffen Nurpmeso <steffen@sdaoden.eu> Message-ID: <f90b33d398ccf814083e300454df88e0937b94d3.1747784310.git.steffen@sdaoden.eu> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-21man/man3/*printf.3: Document ERRORSTobias Stoeckmann3-4/+58
The printf family of functions set errno if a negative value is returned. Source is POSIX.1, see <https://pubs.opengroup.org/onlinepubs/9799919799/functions/fprintf.html> <https://pubs.opengroup.org/onlinepubs/9799919799/functions/fwprintf.html> Also see manual pages of FreeBSD and OpenBSD. Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org> Message-ID: <34octlcodbwm3kfqlouvrvhriiftmlzzobbohgzivlkgi53nfs@7gxajeb56klz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-18man/man2const/UFFDIO_API.2const: Add an entry for UFFDIO_FEATURE_MOVEPeter Xu1-0/+6
Add the entry for UFFDIO_MOVE ioctl in UFFDIO_API man page. Fixes: d7dec35a3b19 ("man/man2/ioctl_userfaultfd.2, man/man2const/UFFDIO_MOVE.2const: Document UFFDIO_MOVE") Reviewed-by: Suren Baghdasaryan <surenb@google.com> Signed-off-by: Peter Xu <peterx@redhat.com> Message-ID: <20250514172630.569788-3-peterx@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-18man/man2const/UFFDIO_API.2const: Update userfaultfd handshake and feature probePeter Xu1-19/+25
There's a confusing paragraph in the man page on two-steps handshake for userfaultfd UFFDIO_API ioctl. In reality, after a successful UFFDIO_API ioctl, the userfaultfd will be locked up on the features and any further UFFDIO_API on top of an initialized userfaultfd would fail. Modify the UFFDIO_API(2const) man page to reflect the reality. Instead, add a paragraph explaining the right way to probe userfaultfd features. Add that only after the "Before Linux 4.11" paragraph, as the old kernel doesn't support any feature anyway. Fixes: a252b3345 ("ioctl_userfaultfd.2: Describe two-step feature handshake") Reviewed-by: Kyle Huey <khuey@kylehuey.com> Signed-off-by: Peter Xu <peterx@redhat.com> Message-ID: <20250514172630.569788-2-peterx@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-17*: grfixAlejandro Colomar1358-1359/+1359
Scripted change: $ grep -rl 'The authors of the Linux man-pages' \ | xargs sed -i '/Copyright, The authors of the Linux man-pages project/s/The/the/'; Reported-by: Josh Triplett <josh@joshtriplett.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-10*, AUTHORS: Consistently refer to authorsAlejandro Colomar1358-1359/+1359
- Rename the file CREDITS => AUTHORS - Say 'authors' in the copyright notice. Scripted change: $ grep -rn 'The contributors to the Linux man-pages' -l \ | xargs sed -i '/Copyright, The contributors to the Linux man-pages project/s/contributors to/authors of/' Suggested-by: Dave Martin <Dave.Martin@arm.com> Acked-by: "G. Branden Robinson" <branden@debian.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-09man/man2/: VERSIONS: POSIX.1-2024 specifies *_CLOFORK, but Linux doesn't ↵Alejandro Colomar2-0/+10
support it Link: <https://lore.kernel.org/all/20200515160342.GE23230@ZenIV.linux.org.uk/> Cc: Mateusz Guzik <mjguzik@gmail.com> Cc: Jeff Layton <jlayton@kernel.org> Cc: Chuck Lever <chuck.lever@oracle.com> Cc: <linux-fsdevel@vger.kernel.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-09man/: Consistently use 'path' for parameters referring to pathnamesAlejandro Colomar8-43/+45
And use 'pathname' in the descriptions. 'pathname' is the POSIXly correct term, and 'path' is a reasonable abbreviation for it in parameter names. Cc: "G. Branden Robinson" <branden@debian.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-08man/man3/[static_]assert.3: SYNOPSIS: Use 'bool' instead of 'scalar'Alejandro Colomar2-4/+5
The type _Bool perfectly models these APIs. Conversion from any scalar type to _Bool results in true if the value is non-zero, and false if it is zero. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-07man/: Refresh pages from tzdb-2025bAlejandro Colomar4-182/+211
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-07man/man7/bpf-helpers.7: Refresh page from Linux v6.14Alejandro Colomar1-1/+1
Scripted change: $ ~/src/linux/linux/v6.14/scripts/bpf_doc.py \ | rst2man \ >man/man7/bpf-helpers.7; Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-06*, CREDITS: Unify copyright noticesAlejandro Colomar1358-2571/+1449
Link: <https://lore.kernel.org/linux-man/jpin2dbnp5vpitnh7l4qmvkamzq3h3xljzsznrudgioox3nn72@57uybxbe3h4p/T/#u> Link: <https://www.linuxfoundation.org/blog/blog/copyright-notices-in-open-source-software-projects> Cc: "G. Branden Robinson" <branden@debian.org> Cc: Carlos O'Donell <carlos@redhat.com> Cc: Eugene Syromyatnikov <evgsyr@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-06man/, CREDITS: Move in-source contribution records to CREDITSAlejandro Colomar700-3828/+82
This information is better placed in the git logs, not in the source code itself. For people interested in the old history of pages, before we used git, they will probably look at old versions of these pages, like for example man-pages-1.70, or the 'prehistory' branch, and there they'll find these notes. Keep the names and emails of contributors in a new CREDITS file. Link: <https://lore.kernel.org/linux-man/jpin2dbnp5vpitnh7l4qmvkamzq3h3xljzsznrudgioox3nn72@57uybxbe3h4p/T/#u> Link: <https://www.linuxfoundation.org/blog/blog/copyright-notices-in-open-source-software-projects> Cc: "G. Branden Robinson" <branden@debian.org> Cc: Carlos O'Donell <carlos@redhat.com> Cc: Eugene Syromyatnikov <evgsyr@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-02man/man2const/TIOCLINUX.2const: Document CAP_SYS_ADMIN requirement for ↵Günther Noack1-2/+14
TIOCL_SETSEL modes CAP_SYS_ADMIN was previously required for the entire TIOCL_SETSEL subcode, but is now only needed for a subset of the selection modes, since linux.git 2f83e38a095f (2025-01-13; "tty: Permit some TIOCL_SETSEL modes without CAP_SYS_ADMIN"). The CAP_SYS_ADMIN requirement for TIOCL_SELMOUSEREPORT was further corrected in linux.git ee6a44da3c87 (2025-04-11; "tty: Require CAP_SYS_ADMIN for all usages of TIOCL_SELMOUSEREPORT"). Admittedly, there are kernels where CAP_SYS_ADMIN was briefly not required for TIOCL_SELMOUSEREPORT, even after Linux v6.7, but this was a mistake which is now fixed in all up-to-date stable kernels. Therefore, we still document CAP_SYS_ADMIN as required "since Linux 6.7" in this case. Link: <https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit?id=2f83e38a095f8bf7c6029883d894668b03b9bd93> Link: <https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit?id=ee6a44da3c87cf64d67dd02be8c0127a5bf56175> Signed-off-by: Günther Noack <gnoack3000@gmail.com> Message-ID: <20250502102405.4891-2-gnoack3000@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-01man/man2/memfd_secret.2: It is now enabled by defaultThiébaud Weksteen1-7/+7
In linux.git b758fe6df50d (2023-06-09; "mm/secretmem: make it on by default") memfd_secret was updated to be enabled by default. Signed-off-by: Thiébaud Weksteen <tweek@google.com> Message-ID: <20250428020252.1569621-1-tweek@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-01man/man2/close_range.2: EXAMPLES: Correct output of example programQuentin Armitage1-1/+1
The output shown for the example program listed /tmp/b twice; the second /tmp/b should be /tmp/c. Fixes: 336bd62ba24c (2021-03-21; "close_range.2: Include a better example program") Signed-off-by: Quentin Armitage <quentin@armitage.org.uk> Message-ID: <e8519ea77798c68944717bc6437052a1119a911f.camel@armitage.org.uk> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-01man/man2/mmap.2: CAVEATS: Document danger of mappings larger than PTRDIFF_MAXJann Horn1-0/+24
References: - C99 draft: https://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf section "6.5.6 Additive operators", paragraph 9 - object size restriction in GCC: https://gcc.gnu.org/legacy-ml/gcc/2011-08/msg00221.html - glibc malloc restricts object size to <=PTRDIFF_MAX in checked_request2size() since glibc v2.30 (released in 2019, as pointed out by Jakub Wilk): https://sourceware.org/cgit/glibc/commit/?id=9bf8e29ca136094f Signed-off-by: Jann Horn <jannh@google.com> Message-ID: <20250429164359.2699330-1-jannh@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-01man/man2/ioctl_userfaultfd.2, man/man2const/UFFDIO_MOVE.2const: Document ↵Suren Baghdasaryan2-0/+161
UFFDIO_MOVE Documentation was extracted from the original patch written by Andrea Arcangeli and upstreamed in [1]. Minor edits were made to maintain the same documentation style as other userfaultfd ioctl commands. [1] <https://lore.kernel.org/all/20231206103702.3873743-3-surenb@google.com/> Signed-off-by: Suren Baghdasaryan <surenb@google.com> Message-ID: <20250423195309.2841410-1-surenb@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-05-01man/man2/madvise.2: Update MADV_GUARD_INSTALL, MADV_GUARD_REMOVE for Linux 6.15Lorenzo Stoakes1-10/+29
Lightweight guard region support has been extended in Linux 6.15, permitting the use of these features for file-backed and read-only mappings. Update the description for these operations in the madvise manpage to describe the changed behaviour. Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com> Message-ID: <20250423183105.116978-1-lorenzo.stoakes@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-22man/man3/slist.3: SYNOPSIS: Add missing argumentSolomon Tan1-1/+1
Fixes: bb8164dec0c4 (2020-10-22; "slist.3: ffix: Use man markup") Signed-off-by: Solomon Tan <wjsota@icloud.com> Message-ID: <20250420124447.1552510-2-wjsota@icloud.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-22man/man7/mctp.7: Document Linux MCTP supportJeremy Kerr2-0/+190
This change adds a brief description for the new Management Component Transport Protocol (MCTP) support added to Linux as of linux.git bc49d8169aa7 (2021-07-29; "mctp: Add MCTP base"). This is a fairly regular sockets-API implementation, so we're just describing the semantics of socket(2), bind(2), sendto(2), and recvfrom(2) for the new protocol. Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au> Message-ID: <20250417-mctp-v3-1-07fff4d26f73@codeconstruct.com.au> [alx: minor tweaks] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-14man/man3/abs.3: Remove NOTES sectionAlejandro Colomar1-16/+0
This seems to be about implementation details that are unimportant to programmers. It is widely understood that compilers may optimize some libc calls. Cc: Anton Zellerhoff <wg14@ascz.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-14man/man3/abs.3: Reorganize pageAlejandro Colomar1-58/+39
Cc: Anton Zellerhoff <wg14@ascz.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-14man/man3/abs.3: Document u{,l,ll,imax}abs()Anton Zellerhoff5-10/+57
C2Y adds unsigned versions of the abs functions (see C2Y draft N3467 and proposal N3349). Support for these functions will be included in GCC 15 and glibc 2.42. Link: <https://www.open-std.org/JTC1/SC22/WG14/www/docs/n3467.pdf> Link: <https://www.open-std.org/JTC1/SC22/WG14/www/docs/n3349.pdf> Link: <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117024> Link: <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=5b132ec2b7712dbc055838b3b538b83ad1196414> Signed-off-by: Anton Zellerhoff <wg14@ascz.de> Message-ID: <28a36070fe18707ab9fa26b91c88e6fd87a72097.1744566285.git.wg14@ascz.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-05man/man?/fanotify*: Document mount namespace eventsAmir Goldstein3-1/+104
Used to subscribe for notifications for when mounts are attached/detached from a mount namespace. Reviewed-by: Jan Kara <jack@suse.cz> Reviewed-by: Miklos Szeredi <mszeredi@redhat.com> Reviewed-by: Christian Brauner <brauner@kernel.org> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250404104723.1709188-2-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-04man/man?/fanotify*: Reorganize documentation of FAN_FS_ERRORAmir Goldstein2-26/+24
The order of FAN_FS_ERROR entry in the event section was rather arbitrary inside the group of fid info events. FAN_FS_ERROR is a special event with error info, so place its entry after the entries for fid info events and before the entries for permission events. Reduce unneeded newlines in the FAN_FS_ERROR entry. Cc: Jan Kara <jack@suse.cz> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250404104723.1709188-1-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-02man/man7/fanotify.7: ffixAlejandro Colomar1-7/+16
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-02man/man7/fanotify.7: Document FAN_RESPONSE_INFO_AUDIT_RULEAmir Goldstein1-0/+41
Document FAN_RESPONSE_INFO_AUDIT_RULE extended response info record that was added in v6.3. Cc: Jan Kara <jack@suse.cz> Cc: Richard Guy Briggs <rgb@redhat.com> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250331082759.1424401-2-amir73il@gmail.com> [alx: ffix] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-02man/man?/fanotify*: Document FAN_PRE_ACCESS eventAmir Goldstein3-4/+58
The new FAN_PRE_ACCESS events are created before access to a file range, to provides an opportunity for the event listener to modify the content of the object before the user can accesss it. Those events are available for group in class FAN_CLASS_PRE_CONTENT They are reported with FAN_EVENT_INFO_TYPE_RANGE info record. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250330125536.1408939-1-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-02man/man?/fanotify*: Document FAN_REPORT_FD_ERRORAmir Goldstein2-0/+42
This flag from v6.13 allows reporting detailed errors on failure to open a file descriptor for an event. This API was backported to LTS kernels v6.12.4 and v6.6.66. Cc: Krishna Vivek Vitta <kvitta@microsoft.com> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250331133959.1436376-1-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-02man/man3type/intptr_t.3type: tfixMiroslav Cimerman1-1/+1
Signed-off-by: Miroslav Cimerman <mc@doas.su> Message-ID: <wsk_s0nLv-HYkjBgAMVkOJW4DSkT5iYYr2anB6R-7X8ftiYyEKKOuNqJlE1jtRjeZjSvnlkxJ4Lm50DmcuS9ftSR_OQxu-8RcySOD5vTaKk=@doas.su> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-04-02man/man2/open_by_handle_at.2: srcfixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man7/fanotify.7: Document FAN_DENY_ERRNO()Amir Goldstein1-0/+22
Document FAN_DENY_ERRNO(), which was added in Linux 6.13 to report specific errors on file access. Cc: Jan Kara <jack@suse.cz> Cc: Josef Bacik <josef@toxicpanda.com> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250331082759.1424401-3-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man7/fanotify.7: The response field is now a bit mask instead of an enumAmir Goldstein1-1/+1
Since the introduction of the FAN_AUDIT response flag, the response field of fanotify_response is no longer an enum it is now a bitmask, so fix the wording around FAN_ALLOW and FAN_DENY. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250331082759.1424401-1-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man2/open_by_handle_at.2: name_to_handle_at(): Document the ↵Amir Goldstein1-1/+30
AT_HANDLE_CONNECTABLE flag A flag since Linux 6.13 to indicate that the requested file_handle is intended to be used for open_by_handle_at(2) to obtain an open file with a known path. Cc: Chuck Lever <chuck.lever@oracle.com> Cc: Jeff Layton <jlayton@poochiereds.net> Cc: Christian Brauner <brauner@kernel.org> Cc: Jan Kara <jack@suse.cz> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250331081642.1423812-2-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man2/open_by_handle_at.2: name_to_handle_at(): Document the ↵Amir Goldstein1-0/+16
AT_HANDLE_MNT_ID_UNIQUE flag A flag since Linux 6.12 to indicate that the requested mount_id is a 64-bit unique id. Cc: Chuck Lever <chuck.lever@oracle.com> Cc: Jeff Layton <jlayton@poochiereds.net> Cc: Christian Brauner <brauner@kernel.org> Cc: Jan Kara <jack@suse.cz> Cc: Aleksa Sarai <cyphar@cyphar.com> Signed-off-by: Amir Goldstein <amir73il@gmail.com> Message-ID: <20250331081642.1423812-1-amir73il@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man2const/TIOCLINUX.2const: Document missing TIOCL_SETSEL selection ↵Günther Noack1-0/+34
modes: TIOCL_SELPOINTER, TIOCL_SELCLEAR, TIOCL_SELMOUSEREPORT Documents the following TIOCL_SETSEL sub-operations: * TIOCL_SELPOINTER * TIOCL_SELCLEAR * TIOCL_SELMOUSEREPORT These previously undocumented selection modes for the Linux console are implemented in <drivers/tty/vt/selection.c>. The name "selection mode" is slightly misleading as not all of them actually manipulate the kernel's mouse selection buffer. Includes clarified semantics pointed out by Jared Finder. Cc: Hanno Böck <hanno@hboeck.de> Cc: Jann Horn <jannh@google.com> Cc: Jiri Slaby <jirislaby@kernel.org> Cc: Jakub Wilk <jwilk@jwilk.net> Signed-off-by: Günther Noack <gnoack3000@gmail.com> Message-ID: <20250330143038.4184-5-gnoack3000@gmail.com> Acked-by: Jared Finder <jared@finder.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man2const/TIOCLINUX.2const: Restructure documentation for TIOCL_SETSEL ↵Günther Noack1-5/+20
selection modes * Indent the documented selection modes into tagged paragraphs. * Document constants from the header file <tiocl.h> instead of numbers. * Clarify expansion semantics as suggested by Jared Finder. Signed-off-by: Günther Noack <gnoack3000@gmail.com> Message-ID: <20250330143038.4184-4-gnoack3000@gmail.com> Acked-by: Jared Finder <jared@finder.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man3/: Use 'path' instead of 'pathname' for parametersAlejandro Colomar7-39/+37
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-31man/man3/mkfifo.3: PATH_MAX limits the size, not the lengthAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-30man/man7/boot.7: wsfixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-30man/: Use 'path' instead of 'pathname' for parametersAlejandro Colomar21-428/+434
It's just as informative, and takes less space. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-30man/man2/execve.2: Remove redundant textAlejandro Colomar1-9/+0
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-30man/: srcfix (\fX => \f[X])Alejandro Colomar369-3271/+5878
While doing this global change, fix other minor issues found nearby. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-29man/man2/recv.2: Don't use 0 as a null pointer constantPeter Radisson1-1/+1
It was probably a typo, since in sendto(2) this is (..., NULL, 0). Signed-off-by: Peter Radisson <radisson97@web.de> Message-ID: <189ef077-18f4-43a3-9008-286a75e7bd91@web.de> Reviewed-by: Carlos O'Donell <carlos@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-25man/man2/posix_fadvise.2: Consistency fix (len => size)Alejandro Colomar1-3/+3
Fixes: 18e7c4597c4e (2024-11-17; "man/: Terminology consistency reforms (n, size, length)") Closes: <https://bugzilla.kernel.org/show_bug.cgi?id=219921> Reported-by: Paul Pluzhnikov <ppluzhnikov@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-23man/man3/strto[u]l.3: C23 added "0b" and "0B"Alejandro Colomar2-6/+26
Link: <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=64924422a99690d147a166b4de3103f3bf3eaf6c> Reported-by: Bruno Haible <bruno@clisp.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-23man/man3/strtoul.3: The prefix "0X" is equivalent to "0x"Alejandro Colomar1-1/+1
strtol(3) mentiones both, but this page somehow forgot the uppercase variant. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-23man/man3/strtol.3: CAVEATS: Clarify how to perform range checksAlejandro Colomar1-0/+14
Reported-by: Bruno Haible <bruno@clisp.org> Co-authored-by: Bruno Haible <bruno@clisp.org> Signed-off-by: Bruno Haible <bruno@clisp.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-23man/man3/strto[u]l.3: BUGS: Signed numbers and white space are not rejectedAlejandro Colomar2-5/+20
Link: <https://stackoverflow.com/questions/60955490/strtoul-what-is-the-correct-return-value-for-very-negative-strings> Reported-by: Bruno Haible <bruno@clisp.org> Co-authored-by: Bruno Haible <bruno@clisp.org> Signed-off-by: Bruno Haible <bruno@clisp.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-20man/man3/wc{,r}tomb.3: wfix regarding MB_CUR_MAXKang-Che Sung2-3/+13
Add the missing length requirement about MB_CUR_MAX to wcrtomb(3). Change the wording on the MB_CUR_MAX requirement in wctomb(3). If programmers know the wide character to convert beforehand, they are allowed to use a buffer smaller than MB_CUR_MAX bytes, as long as it "fits" the sequence. Signed-off-by: Kang-Che Sung <explorer09@gmail.com> Message-ID: <CADDzAfN7_kdv4iQtH=OpgSWtRuqOZXYhxsBiz_OF8Zqf-zy4_Q@mail.gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-20man/man2/get_mempolicy.2: SYNOPSIS: Use GNU fwd declaration of parameters ↵Alejandro Colomar1-2/+3
for sizes of array parameters I forgot to include this change in the global change applied recently. Fixes: d2c2db8830f8 (2025-03-14; "man/: SYNOPSIS: Use GNU forward-declarations of parameters for sizes of array parameters") Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-14man/: SYNOPSIS: Use GNU forward-declarations of parameters for sizes of ↵Alejandro Colomar138-350/+568
array parameters This syntax has been proposed for standardization in N3433. Link: <https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3433.pdf> Cc: Christopher Bazley <chris.bazley.wg14@gmail.com> Cc: Martin Uecker <uecker@tugraz.at> Cc: Joseph Myers <josmyers@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-14man/: EXAMPLES: Add missing 'static'Alejandro Colomar4-8/+8
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-14man/man3/: SYNOPSIS: Fix incorrect array parametersAlejandro Colomar3-3/+3
See the non-wide equivalent functions. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-14man/man2/getsockopt.2: SYNOPSIS: Add missing _Nullable qualifierAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-09man/man7/ip.7: Document capabilities to use IP_TRANSPARENTMatthieu Buffet1-0/+2
CAP_NET_ADMIN has been overkill to use setsockopt(IP_TRANSPARENT) since a discussion on LKML[1] and a patch[2] in 2011. All that is left to do is to let devs know they don't need CAP_NET_ADMIN. [2] linux.git 6cc7a765c298 (2011-10-20; "net: allow CAP_NET_RAW to set socket options IP{,V6}_TRANSPARENT") Link: [1] <https://lore.kernel.org/netdev/20111020.182214.629562655202957174.davem@davemloft.net/T/> Signed-off-by: Matthieu Buffet <matthieu@buffet.re> Message-ID: <20250307222244.597006-1-matthieu@buffet.re> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-06man/man7/landlock.7: Document IPC scoping (Landlock ABI v6)Günther Noack1-1/+64
With this ABI version, Landlock can restrict outgoing interactions with higher-privileged Landlock domains through Abstract Unix Domain sockets and signals. Terminology: * The *IPC Scope* of a Landlock domain is that Landlock domain and its nested domains. * An *operation* (e.g., signaling, connecting to abstract UDS) is said to be *scoped within a domain* when the flag for that operation was set at ruleset creation time. This means that for the purpose of this operation, only processes within the domain's IPC scope are reachable. Link: <https://lore.kernel.org/all/20250303194510.135506-4-gnoack@google.com/> Signed-off-by: Günther Noack <gnoack@google.com> Cc: Mickaël Salaün <mic@digikod.net> Cc: Tahera Fahimi <fahimitahera@gmail.com> Cc: Tanya Agarwal <tanyaagarwal25699@gmail.com> Cc: Daniel Burgener <dburgener@linux.microsoft.com> Cc: <linux-security-module@vger.kernel.org> Message-ID: <20250303195056.136777-4-gnoack@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-05man/man7/landlock.7: Document network supportGünther Noack1-4/+14
Copy over the existing wording from kernel documentation, as it was introduced in Linux commit 51442e8d64bc (2023-10-26, "landlock: Document network support"). Landlock rules are not only about the filesystem any more and the new wording is more appropriate. Signed-off-by: Günther Noack <gnoack@google.com> Cc: Mickaël Salaün <mic@digikod.net> Cc: Tahera Fahimi <fahimitahera@gmail.com> Cc: Tanya Agarwal <tanyaagarwal25699@gmail.com> Cc: Daniel Burgener <dburgener@linux.microsoft.com> Cc: <linux-security-module@vger.kernel.org> Message-ID: <20250303195056.136777-2-gnoack@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-03-03man/man2/mkdir.2: ffixChen Linxuan1-0/+1
Fixes: 2904e040ded2 (2025-02-02; "man/man2/mkdir.2: ERRORS: Add EOVERFLOW") Signed-off-by: Chen Linxuan <chenlinxuan@uniontech.com> Message-ID: <6DF9A4EE0A868FB4+20250303095057.92138-1-chenlinxuan@uniontech.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-24man/man3/static_assert.3: EXAMPLES: Remove unused includeAlejandro Colomar1-1/+0
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-21man/man2/{mbind,set_mempolicy}.2: Document MPOL_PREFERRED_MANYMatthew Cassell2-0/+20
Browsing a header file in the kernel source and saw the memory policy enum used for mbind() and set_mempolicy() using an entry that I didn't recognize. I man 2'd both system calls and didn't see an entry for MPOL_PREFERRED_MANY. The commit on the enum entry: linux.git b27abaccf8e8 (2021-09-02; "mm/mempolicy: add MPOL_PREFERRED_MANY for multiple preferred nodes") The commit message gives the rationale as to why the MPOL_PREFERRED_MANY mode would be beneficial. Giving the ability to set the memory policy to target different tiers of memory over various NUMA nodes. Cc: Dave Hansen <dave.hansen@linux.intel.com> Signed-off-by: Matthew Cassell <mcassell411@gmail.com> Message-ID: <20250220225232.2138-1-mcassell411@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-20man/man3/getcwd.3: tfix (pathname => pathnames)Askar Safin1-1/+1
Reviewed-by: Carlos O'Donell <carlos@redhat.com> Signed-off-by: Askar Safin <safinaskar@zohomail.com> Message-ID: <20250220091926.3985504-3-safinaskar@zohomail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-20man/man3/getcwd.3: VERSIONS: The syscall can return "(unreachable)", but ↵Askar Safin1-1/+4
modern glibc wrapper cannot I verified using an expirement (see below) that the modern glibc wrapper getcwd() actually never returns "(unreachable)". I have also read the modern glibc sources for all three functions documented here. None of them return "(unreachable)". Now let me describe my expirement: d-user@comp:/tmp$ cat getcwd.c #include <unistd.h> #include <stdio.h> #include <sys/syscall.h> int main(void) { char buf[1000]; if (syscall(SYS_getcwd, buf, sizeof(buf)) == -1) perror("SYS_getcwd"); else printf("SYS_getcwd: %s\n", buf); if (getcwd(buf, sizeof(buf)) == NULL) perror("getcwd"); else printf("getcwd: %s\n", buf); return 0; } d-user@comp:/tmp$ gcc -Wall -Wextra -o getcwd getcwd.c d-user@comp:/tmp$ sudo unshare --mount bash d-root@comp:/tmp# mkdir /tmp/dir d-root@comp:/tmp# mount -t tmpfs tmpfs /tmp/dir d-root@comp:/tmp# cd /tmp/dir d-root@comp:/tmp/dir# umount -l . d-root@comp:/tmp/dir# /tmp/getcwd SYS_getcwd: (unreachable)/ getcwd: No such file or directory d-root@comp:/tmp/dir# exit exit Link: <https://sourceware.org/bugzilla/show_bug.cgi?id=18203> Link: <https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=52a713fdd0a30e1bd79818e2e3c4ab44ddca1a94> Reviewed-by: Carlos O'Donell <carlos@redhat.com> Signed-off-by: Askar Safin <safinaskar@zohomail.com> Message-ID: <20250220091926.3985504-2-safinaskar@zohomail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-18man/man3/ctime.3: Mention that timegm(3) is a UTC equivalent of mktime(3)Alejandro Colomar1-0/+3
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-16man/man7/mount_namespaces.7: Fix an incorrect path in an exampleGöran Uddeborg1-1/+1
In the example showing how locked mounts in a less privileged mount namespace can not be split, first </etc/shadow> is bind mounted, then an attempt is done to unmount </mnt/dir>, which gives an error complaining that </etc/shadow> is not mounted. The unmount should also refer to </etc/shadow>. Fixes: 906ab4945cd3 (2021-08-20; "mount_namespaces.7: Rewrite locked mounts examples to use/etc/shadow") Closes: <https://bugzilla.kernel.org/show_bug.cgi?id=217709> Signed-off-by: Göran Uddeborg <goeran@uddeborg.se> Cc: Rajesh <r.pandian@gmail.com> Message-ID: <26546.13734.573762.288144@gargle.gargle.HOWL> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-12man/man2/kill.2: RETURN VALUE: Fix wording issue with sig=0Amit Pinhas1-1/+3
The DESCRIPTION says: If *sig* is 0, then no signal is sent, but existence and permission checks are still performed; this can be used to check for the existence of a process ID. On the other hand, the `RETURN VALUE` section contradicted that. On success (at least one signal was sent), zero is returned. On error, -1 is returned... How can I get 0 when providing sig=0, if no signal was actually sent, which is the criteria for success of this call??? Reported-by: Amit Pinhas <amitpinhass@gmail.com> Co-authored-by: Alejandro Colomar <alx@kernel.org> Signed-off-by: Amit Pinhas <amitpinhass@gmail.com> Message-ID: <a4fa37e0fc89a3c99982ace3fe381991ebe85b00.1739393685.git.amitpinhass@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-12man/man7/bpf-helpers.7: Refresh page from Linux v6.13Alejandro Colomar1-14/+16
Scripted change: $ ~/src/linux/linux/v6.13/scripts/bpf_doc.py \ | rst2man \ >man7/bpf-helpers.7; Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-10man/man3/timespec_get.3: Correct return value and clarify descriptionMark Harris1-26/+37
- 0, not -1, is returned for an unsupported time base or error (C23 7.29.2.6, 7.29.2.7; POSIX.1-2024 line 74358). - Clarify that any supported value of base is always nonzero (i.e., there is no overlap between the two return value cases that may require errno or some other source to disambiguate) (C23 7.29.2.6, 7.29.2.7; POSIX.1-2024 line 74357). - Clarify that timespec_getres(NULL, base) is a valid call to check whether the specified time base is supported (C23 7.29.2.7). - Clarify that the resolution for a particular time base is constant for the lifetime of the process (i.e., there is no need to retrieve it repeatedly) (C23 7.29.2.7). - Calls to these functions are not technically equivalent to any clock_* function call; at least the return value will be different. Clarify that it is the time and resolution that are the same. - The ERRORS section is removed, because it states only what is true for every function that does not state otherwise (i.e., errno might be affected by underlying system calls). Fixes: 7bda5119fe5e (2024-09-08; "timespec_get.3, timespec_getres.3: Add page and link page") Cc: наб <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Mark Harris <mark.hsj@gmail.com> Message-ID: <5f8dc5d2dc51f080a18de53e98610df43389b98b.1739063937.git.mark.hsj@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-10man/man3/regex.3: EXAMPLES: Don't use z length modifier with unsigned intArkadiusz Drabczyk1-1/+1
GCC and Clang print warnings: $ clang main.c -Wall main.c:30:23: warning: format specifies type 'size_t' (aka 'unsigned long') but the argument has type 'unsigned int' [-Wformat] 30 | printf("#%zu:\n", i); | ~~~ ^ | %u 1 warning generated. $ gcc main.c -Wall main.c: In function ‘main’: main.c:30:16: warning: format ‘%zu’ expects argument of type ‘size_t’, but argument 2 has type ‘unsigned int’ [-Wformat=] 30 | printf("#%zu:\n", i); | ~~^ ~ | | | | | unsigned int | long unsigned int | %u Fixes: b42296e4feaf (2022-09-15; "Various pages: EXAMPLES: Use unsigned types for loop iterators") Signed-off-by: Arkadiusz Drabczyk <arkadiusz@drabczyk.org> Message-ID: <20250207211628.25164-1-arkadiusz@drabczyk.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-10man/man2/clone.2: Use munmap(2) to free 'stack'Alejandro Colomar1-0/+2
Cc: "Eric W. Biederman" <ebiederm@xmission.com> Reported-by: Chen Linxuan <chenlinxuan@uniontech.com> Message-ID: <647EBDB1A8DE7507+20250121031351.548052-1-chenlinxuan@uniontech.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-02man/man2/mkdir.2: ERRORS: Add EOVERFLOWChen Linxuan1-0/+4
mkdir(2) and mkdirat(2) might set errno to EOVERFLOW when UID or GID mapping has not been configured. Here's a small program that shows this behavior: #define _GNU_SOURCE #include <err.h> #include <sched.h> #include <stdlib.h> #include <sys/mman.h> #include <sys/mount.h> #include <sys/stat.h> #include <sys/wait.h> #include <unistd.h> static int childFunc(void *_) { if (mount("tmpfs", "/tmp", "tmpfs", 0, NULL)) err(EXIT_FAILURE, "mount"); if (mkdir("/tmp/test", 0755) == -1) err(EXIT_FAILURE, "mkdir"); return 0; } #define STACK_SIZE (1024 * 1024) int main(void) { char *stack; /* Start of stack buffer */ char *stackTop; /* End of stack buffer */ pid_t pid; stack = mmap(NULL, STACK_SIZE, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS | MAP_STACK, -1, 0); if (stack == MAP_FAILED) err(EXIT_FAILURE, "mmap"); stackTop = stack + STACK_SIZE; pid = clone(childFunc, stackTop, CLONE_NEWUSER | CLONE_NEWNS | SIGCHLD, NULL); if (munmap(stack, STACK_SIZE) == -1) err(EXIT_FAILURE, "munmap"); if (pid == -1) err(EXIT_FAILURE, "clone"); if (waitpid(pid, NULL, 0) == -1) err(EXIT_FAILURE, "waitpid"); exit(EXIT_SUCCESS); } Link: <https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=036d523641c66bef713042894a17f4335f199e49> Signed-off-by: Chen Linxuan <chenlinxuan@uniontech.com> Message-ID: <F22A2B1500170B63+20250202135733.11800-1-chenlinxuan@uniontech.com> [alx: wfix] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-02man/man7/signal.7: Update definition of SIGCHLD for POSIX.1-2001Arkadiusz Drabczyk1-2/+3
This is an XSI extension supported by Linux. Link: <https://unix.stackexchange.com/q/790116/72304> Link: <https://lore.kernel.org/linux-man/Z5U0Wh_KF3Ki62Pk@comp../> Signed-off-by: Arkadiusz Drabczyk <arkadiusz@drabczyk.org> Message-ID: <20250202130331.20320-1-arkadiusz@drabczyk.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-02man/man7/sched.7: Mention autogroup disabled behaviorPhil Auld1-0/+5
The autogroup feature can be contolled at runtime when built into the kernel. Disabling it in this case still creates autogroups and still shows the autogroup membership for the task in /proc. The scheduler code will just not use the the autogroup task group. This can be confusing to users. Add a sentence to this effect to sched.7 to point this out. The kernel code shows how this is used. The sched_autogroup_enabled toggle is only used in one place. kernel/sched/autogroup.h: static inline struct task_group * autogroup_task_group(struct task_struct *p, struct task_group *tg) { extern unsigned int sysctl_sched_autogroup_enabled; int enabled = READ_ONCE(sysctl_sched_autogroup_enabled); if (enabled && task_wants_autogroup(p, tg)) return p->signal->autogroup->tg; return tg; } task_wants_autogroup() is in kernel/sched/autogroup.c: bool task_wants_autogroup(struct task_struct *p, struct task_group *tg) { if (tg != &root_task_group) return false; ... return true; } One can see that any group set other than root also bypasses the use of the autogroup. All of the machinery around the creation of the autogroup is not effected by the toggle. From userspace: 0 /autogroup-112 nice 0 Note, systemd based system these days is not really using autogroups at all anyway because any task in a non-root cgroup bypasses the autogroup as well. Cc: Carlos O'Donell <codonell@redhat.com> Signed-off-by: Phil Auld <pauld@redhat.com> Message-ID: <20250116143747.2366152-1-pauld@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-02man/man2/rt_sigqueueinfo.2: tfix (tid => tgid)Askar Safin1-1/+1
Signed-off-by: Askar Safin <safinaskar@zohomail.com> Message-ID: <20250130050625.3356602-1-safinaskar@zohomail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-02-02man/man5/proc_pid_limits.5: tfixAlejandro Colomar1-1/+1
Reported-by: "Tomerius, Kai" <Kai.Tomerius@elektrobit.com> Fixes: 07c3768e9db8 (2023-08-15; "proc.5, proc_pid_limits.5: Split /proc/PID/limits from proc(5)") Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-28man/man7/pathname.7: Pathnames are opaque C stringsAlejandro Colomar1-85/+2
On Mon, Jan 27, 2025 at 07:27:59PM +0100, наб wrote: > Skimming the thread: UNIX paths are sequences of non-NUL bytes. > > It is never correct to expect to be able to have a (parse, unparse) > operation pair for which unparse(parse(x)) = x for path x. > > It's obviously wrong to reject a pathname just because you dont like it. > > Thus, when displaying a path, either (a) dump it directly to the output > (the user has configured their display device to understand the paths they use), > or if that's not possible (b) setlocale(LC_ALL, "") + mbrtowc() loop > and render the result (applying usual ?/� substitutions for mbrtowc() > errors makes sense here). > > There are very few operations on paths that are actually reasonable > to do, ever; those are: appending stuff, prepending stuff > (this is just appending stuff with the arguments backwards), > and cleaving at /es; > the "stuff" better be copied whole-sale from some other path > or an unprocessed argument (or, sure, the PFCS). > > If you're getting bytes to append to a path, do that directly. > > If you're getting characters to append to a path, > then wctomb(3) is the only non-invalid solution, > since that (obviously) turns characters into bytes in the current > locale, which (ex def) is the operation desired. > > I don't understand what the UTF-32 dance is supposed to be. > > If you're recommending transcoding paths, don't. > > To re-iterate: paths are not character sequences. > They do not represent characters. > You can't meaningfully coerce them thusly without loss of precision > (this is ok to do for display! and nothing else). > If at any point you find yourself turning wchar_t -> char > you are doing something wrong; > if you find yourself doing char -> wchar_t for anything beside display > you should probably reconsider. > > This is different under Win32 of course. But that concerns us naught. Suggested-by: наб <nabijaczleweli@nabijaczleweli.xyz> Cc: Jason Yundt <jason@jasonyundt.email> Cc: Florian Weimer <fweimer@redhat.com> Cc: "G. Branden Robinson" <branden@debian.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-28man/man7/pathname.7: EXAMPLES: Use a non-ASCII filenameAlejandro Colomar1-1/+1
The ASCII filename was too simple to actually show anything useful. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-28man/man7/pathname.7: Add file documenting pathnamesJason Yundt1-0/+159
The goal of this new manual page is to help people create programs that do the right thing even in the face of unusual paths. The information that I used to create this new manual page came from these sources: Link: <https://unix.stackexchange.com/a/39179/316181> Link: <https://sourceware.org/pipermail/libc-help/2024-August/006737.html> Link: <https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/fs/ext4/ext4.h?h=v6.12.9#n2288> Link: <man:unix(7)> Link: <https://unix.stackexchange.com/q/92426/316181> Cc: Florian Weimer <fweimer@redhat.com> Signed-off-by: Jason Yundt <jason@jasonyundt.email> Message-ID: <20250121133523.24606-1-jason@jasonyundt.email> Cc: "G. Branden Robinson" <branden@debian.org> [alx: wfix, ffix, and other tweaks] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-22man/man7/unicode.7: pfixAlejandro Colomar1-1/+1
Reported-by: Wyatt Carpenter <wyattscarpenter@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-15man/man7/man-pages.7: Stop telling contributors to write titles in all capsJason Yundt1-2/+1
Recently, I submitted my first patch to the Linux man-pages project. In my patch, I had created a new manual page. On the manual page’s title line, I had written the title of my new page in all caps because man-pages(7) said that I should write it that way. It turns out that man-pages(7) was wrong and that the title on the title line should have matched the title in the manual page’s filename [1][2]. This commit corrects man-pages(7) so that it does not tell contributors to use all caps when writing titles on title lines. Link: [1] <https://lore.kernel.org/linux-man/rph24kz36vysoeix4qoxxxcwq3c3fskws2vmxkkgcb2lpits3f@ysm7ug66svzh/T/#mc84250a6634d7f776118879021331001cceccbe5> Link: [2] <https://lore.kernel.org/linux-man/mog6nnwzwl2dmlrec5b7l76wbxlsnklvdulok644x6o557trib@3zwtoz47r4x3/T/#mf71422d0e159210a7ca2798f2bba50a668e1410e> Message-ID: <20250114211427.160509-1-jason@jasonyundt.email> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-14man/man2/fork.2: Add _exit(2) to exampleTobias Stoeckmann1-1/+3
The _exit(2) function is a better choice for exiting a child in many cases. Most prominently it avoids calls of functions registered with atexit(3) by the parent. There are valid reasons to call exit(3) and the example is actually one of them: flush FILE-based output. Since atexit(3) is never called, we could just stay with exit(3). Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org> Message-ID: <tngwcffbrzbfkj6vrxgxpekrp3bzuftdy2mzow56xyfkrcna2w@nbgr2ourerxo> Link: <https://github.com/shadow-maint/shadow/pull/1171> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-11man/man3/: SYNOPSIS: Use typeof() to improve readability of function pointer ↵Alejandro Colomar2-2/+2
types Due to different spacing, I had missed these ones in the previous commits of this kind. Suggested-by: Jorenar <dev@jorenar.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-11man/man7/user_namespaces.7: tfixAlexander Stepchenko1-1/+1
Fixes: 8c74a1cea495 (2016-07-07; "user_namespaces.7: Clarify details of CAP_SYS_ADMIN and cgroup v1 mounts") Signed-off-by: Alexander Stepchenko <geochip@altlinux.org> Message-ID: <bc17315eff26eb31ecc78a2c44b89dfb077813df.1736444255.git.geochip@altlinux.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-11man/man2/statx.2: Document STATX_DIO_READ_ALIGNChristoph Hellwig1-1/+28
Document the new STATX_DIO_READ_ALIGN flag and the new stx_dio_read_offset_align field guarded by it. Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Christian Brauner <brauner@kernel.org> Cc: Jan Kara <jack@suse.cz> Cc: Chandan Babu R <chandan.babu@oracle.com> Cc: Hongbo Li <lihongbo22@huawei.com> Cc: Ryusuke Konishi <konishi.ryusuke@gmail.com> Cc: <linux-nilfs@vger.kernel.org> Cc: <linux-fsdevel@vger.kernel.org> Cc: <linux-xfs@vger.kernel.org> Reviewed-by: "Darrick J. Wong" <djwong@kernel.org> Signed-off-by: Christoph Hellwig <hch@lst.de> Message-ID: <20250109083226.GA22264@lst.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-11src/bin/diffman, man/man1/diffman: Remove programAlejandro Colomar1-55/+0
It was useful for implementing duffman(1), but now it doesn't use it anymore. Drop this program. Users can do this instead: $ MAN_KEEP_FORMATTING=1 diff -u <(man page1) <(man page2); Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-11man/man1/diffman-git.1: Add manual pageAlejandro Colomar1-0/+68
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-09man/man2/stat.2: Linux 6.11 allows using NULL with AT_EMPTY_PATH.enh1-1/+3
Cc: Dan Albert <danalbert@google.com> Signed-off-by: Elliott Hughes <enh@google.com> Message-ID: <CAJgzZoqAOpJajmAnr-i9h3sPC8F_Uu0A+3eg4nkP+xTAV5fPGg@mail.gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-07man/man2/setns.2: Add missing info about time nsMichal Clapinski1-1/+11
Only singlethreaded processes can setns into time ns. Link: <https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/kernel/time/namespace.c?h=v6.12#n309> Signed-off-by: Michal Clapinski <mclapinski@google.com> Message-ID: <20250107135700.3995936-1-mclapinski@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-05man/man2/signal.2: VERSIONS: The typedef-less definition of signal(2) isn't ↵Alejandro Colomar1-2/+2
hard to read At least if you use typeof(). Acked-by: Jorenar <dev@jorenar.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-05man/: Use typeof() to improve readability of function pointer typesAlejandro Colomar7-17/+17
An exception of good taste is structure members. There, for alignment reasons, traditional syntax seems more appropriate usually. Suggested-by: Jorenar <dev@jorenar.com> Cc: Martin Uecker <uecker@tugraz.at> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-05src/bin/diffman, man/man1/diffman.1: Use man(1) to format the pagesAlejandro Colomar1-0/+3
This allows using the environment variables that man(1) understands. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-05man/man3/: EXAMPLES: wsfixAlejandro Colomar2-2/+2
Add a space after a cast. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-05man/man3/: EXAMPLES: Remove unnecessary parenthesesAlejandro Colomar3-3/+3
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-05man/man3/sem_open.3: SYNOPSIS: This is a variadic functionAlejandro Colomar1-3/+2
Specify the prototype consistently with open(2). Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-04man/man2/io_submit.2: Document RWF_NOAPPENDJohn Garry1-0/+10
Document flag introduced in Linux v6.9. Cc: Rich Felker <dalias@libc.org> Cc: Christian Brauner <brauner@kernel.org> Signed-off-by: John Garry <john.g.garry@oracle.com> Message-ID: <20241126090847.297371-3-john.g.garry@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-04man/man2/readv.2: Document RWF_NOAPPENDJohn Garry1-0/+23
Document flag introduced in Linux v6.9. Cc: Rich Felker <dalias@libc.org> Cc: Christian Brauner <brauner@kernel.org> Signed-off-by: John Garry <john.g.garry@oracle.com> Message-ID: <20241126090847.297371-2-john.g.garry@oracle.com> [alx: wfix, srcfix] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-04man/man2/statx.2: Update STATX_WRITE_ATOMIC filesystem supportJohn Garry1-0/+9
Linux v6.13 will include atomic write support for xfs and ext4, so update STATX_WRITE_ATOMIC commentary to mention that. Cc: "Darrick J. Wong" <djwong@kernel.org> Cc: <ritesh.list@gmail.com> Signed-off-by: John Garry <john.g.garry@oracle.com> Message-ID: <20241203145359.2691972-1-john.g.garry@oracle.com> [alx: ffix] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-04man/man3/pthread_cond_init.3: Remove EINTR error codeArkadiusz Drabczyk1-3/+0
In pthreads.7 it says: "For each of the pthreads functions that can return an error, POSIX.1-2001 specifies that the function can never fail with the error EINTR." Link: <https://lore.kernel.org/linux-man/Z3W_qgawqyEB-QrA@comp../> Cc: Florian Weimer <fweimer@redhat.com> Signed-off-by: Arkadiusz Drabczyk <arkadiusz@drabczyk.org> Message-ID: <20250103173816.6409-2-arkadiusz@drabczyk.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2025-01-04man/man7/signal.7: Don't mention that pthread API can return EINTRArkadiusz Drabczyk1-4/+0
In pthreads.7 it says: "For each of the pthreads functions that can return an error, POSIX.1-2001 specifies that the function can never fail with the error EINTR." Link: <https://lore.kernel.org/linux-man/Z3W_qgawqyEB-QrA@comp../> Cc: Florian Weimer <fweimer@redhat.com> Signed-off-by: Arkadiusz Drabczyk <arkadiusz@drabczyk.org> Message-ID: <20250103173816.6409-1-arkadiusz@drabczyk.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-24man/man3/: Don't use 'length' to refer to buffer sizeAlejandro Colomar17-106/+106
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-24man/man3/stdio_ext.3: wfixAlejandro Colomar1-1/+1
For consistency with wide characters, say characters instead of bytes. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-24man/man3/{stdin,stdio}.3: SYNOPSIS: Consistently declare as 'extern' variablesAlejandro Colomar2-6/+6
And leave two spaces between the type name and the variable name. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-23man/man2/ioctl_pipe.2: SYNOPSIS: Fix $1, which is not an array parameterAlejandro Colomar1-2/+2
Link: <https://lore.kernel.org/linux-man/20241214180423.2thsuyyfosrlyajb@devuan/T/#u> Reported-by: Alejandro Colomar <alx@kernel.org> Suggested-by: Cyril Hrubis <chrubis@suse.cz> Cc: David Howells <dhowells@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-23man/man2/madvise.2: wfixLorenzo Stoakes1-1/+2
Cc: Jann Horn <jannh@google.com> Suggested-by: Vlastimil Babka <vbabka@suse.cz> Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com> Message-ID: <20241206113418.14327-1-lorenzo.stoakes@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-22man/man3/string.3: SYNOPSIS: SimplifyAlejandro Colomar1-150/+76
Replace the prototypes by manual-page references, and use generic text which doesn't use the names of the parameters. It's just an overview. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-22src/bin/diffman, man/man1/diffman.1: -s: Add support for diff(1)'s -s flagAlejandro Colomar1-0/+3
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-20man/man3/getline.3: wfixAlejandro Colomar1-2/+2
Fixes: ef53ef760638 (2024-12-18, "man/man3/getline.3: Clarify ERRORS") Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-19man/man3/getopt.3: Remove _<PID>_GNU_nonoption_argv_flags_ descriptionAhelenia Ziemiańska1-9/+6
Per <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=bf079e19f50d64aa5e05b5e17ec29afab9aabb20>: - this was set by bash 2.0 (1996-12) (implemented in glibc b07c5668f672125074dd5b0b658145e1544120be) - it's no longer set by bash 2.01 (1997-06) because it was bad - glibc disabled this with no way to enable it in 2001-08 (518a0dd201c48a5c15d73c1919c304a9f8f5e3c1) - glibc removed it in 2017 bf079e19f50d64aa5e05b5e17ec29afab9aabb20 So this was experienced by people for 5 months at best, and could remotely be experienced for 3 years (if you somehow wanted this bad behaviour and added it into your shell), over 20 years ago. No modern reader (or, frankly, non-modern reader) has ever used this, or could use it, really. Link to the removal note for completeness only. Link: <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=bf079e19f50d64aa5e05b5e17ec29afab9aabb20> Cc: Eugene Syromyatnikov <evgsyr@gmail.com> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Message-Id: <dwfybzlb5ydbsc4puo6igj7nm7iregquv6hxhhqb53bwrvqswb@tarta.nabijaczleweli.xyz> [alx: Add break points in URI; minor tweaks to commit message too] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-18man/man3/getline.3: Clarify ERRORSenh1-4/+6
Signed-off-by: Elliott Hughes <enh@google.com> Message-ID: <CAJgzZoruFUg6X=JUNJXCbBOKs13SX=dsNFNdTMct2VecUFG=ww@mail.gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-16man/man3/strverscmp.3: This is NOT the ordering used by ls -vAhelenia Ziemiańska1-15/+8
Compare, given: #include <stdlib.h> #include <stdio.h> #include <string.h> int compar(const char **l, const char **r) { return strverscmp(*l, *r); } int main(int argc, char ** argv) { qsort(argv + 1, argc - 1, sizeof(*argv), compar); for(int i = 1; i < argc; ++i) puts(argv[i]); } yields: $ /bin/ls -v1 a* # coreutils ls a-1.0a a-1.0.1a $ ../vers a* # as above a-1.0.1a a-1.0a $ ls -v1 a* # voreutils ls @ 5781698 with strverscmp()-equivalent sorting a-1.0.1a a-1.0a compare also the results for real data like netstat-nat-1.{0,1{,.1},2,3.1,4{,.{1,2,3,4,5,6,7,8,9,10}}}.tar.gz Thus, coreutils ls -v (and sort -V) does NOT use strverscmp(3); it uses a modified Debian version comparison algorithm with additional suffix processing and `ls -v`-specific exceptions. Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Message-Id: <myuppkwnltqtxduoop7g7wfuyou5cdo6sotocrvyztmqnazvph@tarta.nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-14man/man2/get_mempolicy.2: SYNOPSIS: ffixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-14man/man2/: SYNOPSIS: Use array notationAlejandro Colomar2-5/+5
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-13man/: SYNOPSIS: Use typeof() to improve readability of function pointer typesAlejandro Colomar27-69/+79
Suggested-by: Jorenar <dev@jorenar.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-13man/man3/makecontext.3: SYNOPSIS: Add ellipsis to function typeAlejandro Colomar1-3/+3
The old syntax with empty parentheses has been removed from the language in C23. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-11man/man3/isalpha.3: tfixAlejandro Colomar1-12/+12
Fixes: ba687b00ecb3 (2023-07-30, "man3/: srcfix") Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-06proc_pid_fdinfo.5: Reduce indent for most of the pageIan Rogers1-36/+25
When /proc/pid/fdinfo was part of proc.5 man page the indentation made sense. As a standalone man page the indentation doesn't need to be so far over to the right. Remove the initial tagged pragraph, move the "since Linux 2.6.22" to a new HISTORY subsection. Suggested-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Message-Id: <20241206073828.1119464-1-irogers@google.com> [alx: ffix] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-06src/bin/diffman, diffman.1: -U: Add support for diff(1)'s -U optionAlejandro Colomar1-0/+6
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-06src/bin/diffman: -w: Add support for diff(1)'s -w flagAlejandro Colomar1-0/+5
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-06ld.so.8: tfixAnhad Singh1-1/+1
Signed-off-by: Anhad Singh <andypython@protonmail.com> Message-Id: <20241206071814.55913-1-andypython@protonmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-05madvise.2: Add description of MADV_GUARD_INSTALL, MADV_GUARD_REMOVELorenzo Stoakes1-0/+102
Lightweight guard region support has been added to Linux 6.13, which adds MADV_GUARD_INSTALL and MADV_GUARD_REMOVE flags to the madvise() system call. Therefore, update the manpage for madvise() and describe these operations. Reviewed-by: Jann Horn <jannh@google.com> Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com> Message-Id: <20241205104125.67518-1-lorenzo.stoakes@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-05madvise.2: MADV_SOFT_OFFLINE requests can report EBUSYtyberry@redhat.com1-0/+7
If the page could not be offlined madvise will report EBUSY. This might occur if the page is currently in use or locked. Signed-off-by: Tyonnchie Berry <tyberry@redhat.com> Message-Id: <Z0XzU9R9Kx0RoeUG@redhat.com> Acked-by: "Luis Claudio R. Goncalves" <lgoncalv@redhat.com> [alx: wfix, ffix, and other tweaks] Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-04man/: wfixAlejandro Colomar4-4/+6
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-12-04process_madvise.2: Describe 6.13 behaviour permitting all madvise flagsLorenzo Stoakes1-1/+7
Since Linux 6.13 it has become possible to use all madvise flags when targeting the calling process. Reviewed-by: David Hildenbrand <david@redhat.com> Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com> Message-Id: <20241129164422.89837-1-lorenzo.stoakes@oracle.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-28readlink.2: SYNOPSIS: Use array notationAlejandro Colomar1-3/+3
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-26landlock_create_ruleset.2: SYNOPSIS: Add missing includeAlejandro Colomar1-0/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-26src/bin/sortman, sortman.1, share/mk/: Move sortman script to src/bin/, and ↵Alejandro Colomar1-0/+29
add manual page Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-25man1/: SYNOPSIS: ffixAlejandro Colomar13-39/+66
Use SY/YS, and other formatting improvements. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-25src/bin/diffman, diffman.1: Add program and its manual pageAlejandro Colomar1-0/+38
This program diffs manual pages. It's useful for reviewing changes to a manual page: $ diffman membarrier ./man2/membarrier.2 | less -R; Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-22getgroups.2: EXAMPLES: Add example programAlejandro Colomar1-0/+61
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-20posix_fadvise.2: POSIX_FADV_NOREUSE now supported.Yuanchu Xie1-1/+9
POSIX_FADV_NOREUSE is now supported in Linux. Update text regarding former no op behavior. Indicate the readahead policy and treatment of file pages read with this flag. Link: <https://lore.kernel.org/linux-mm/20221230215252.2628425-2-yuzhao@google.com/> Signed-off-by: T.J. Alumbaugh <talumbau@google.com> Signed-off-by: Yuanchu Xie <yuanchu@google.com> Message-Id: <20241120045214.1294799-1-yuanchu@google.com> Acked-by: Yu Zhao <yuzhao@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-19alloca.3: Clarify that alloca(3)ted space is deallocated when the caller returnsAlejandro Colomar1-1/+2
Reported-by: Pali Rohár <pali@kernel.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-17mount_namespaces.7: Use correctly the terms "mount" and "mount point"Alejandro Colomar1-2/+3
On Sun, Nov 17, 2024 at 16:12:24 +0100, Michael Kerrisk wrote: > > A "mount" is a tuple consisting of: > * a mount ID > * a source (e.g., a device) > * a target or "mount point" (i.e. a path name) > * the ID of the parent of this mount > * other stuff (e.g., options) Reported-by: Helge Kreutzmann <debian@helgefjell.de> Cc: Jakub Wilk <jwilk@jwilk.net> Acked-by: "Michael T. Kerrisk" <mtk.manpages@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-17cgroups.7: grfixAlejandro Colomar1-1/+1
Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-17man/: Terminology consistency reforms (n, size, length)Alejandro Colomar67-425/+425
Use 'length' for the lenght of a string. Use 'n' for the number of elements. Use 'size' for the number of bytes. (And in wide-character string functions, 'size' also refers to the number of wide characters.) The change is quite large, and I might have made some mistakes. But overall, this should improve consistency in use of these terms. Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-17getdents.2: ffixAlejandro Colomar1-1/+1
Reported-by: Helge Kreutzmann <debian@helgefjell.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
2024-11-17wcwidth.3: Rename function parameterAlejandro Colomar1-6/+6
Reported-by: Helge Kreutzmann <debian@helgefjell.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>