summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
* man7/: srcfixfAlejandro Colomar2023-07-30-314/+517
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man8/: srcfixAlejandro Colomar2023-07-30-6/+9
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* ipv6.7: srcfixG. Branden Robinson2023-07-30-3/+2
| | | | | | | | | | | | | Protect literals in a (very long) paragraph tag from hyphenation by using hypenation control escape sequences, instead of `nh` and `hy` requests. The latter approach is incorrect for use with groff(1) since '.hy' does not restore the previous hyphenation mode but sets it to 1, which is not appropriate for the English-language hyphenation patterns groff uses. (Also, AT&T man(7) used a hyphenation mode of 14.) Also wrap long input line with \newline escape sequence. Signed-off-by: Alejandro Colomar <alx@kernel.org>
* setnetgrent.3, unlocked_stdio.3: ffixG. Branden Robinson2023-07-30-4/+0
| | | | | | | Stop attempting to manipulate adjustment outside of tbl(1) text blocks. Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man3/: srcfixG. Branden Robinson2023-07-30-45/+39
| | | | | | | | | | | | | Clean up in preparation for "MR sed". Protect (non-cross-referenced) man page names from hyphenation. Use the hyphenation control escape sequence `\%` to do this rather than bracketing a region of the page with `na` and `hy` requests, which enables automatic hyphenation even when it is not desired and uses the wrong hyphenation mode for English to boot. Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* pthread_setcancelstate.3: ffixG. Branden Robinson2023-07-30-1/+1
| | | | | | | | | | Clean up in preparation for "MR sed". Protect man page name from hyphenation. `MR` will take care of that for us; this change is to detect a regression when migrating to it. Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* pthread_setcancelstate.3: srcfixG. Branden Robinson2023-07-30-1/+0
| | | | | | | | | | | Continue commit 9e54434ead, 19 July. Fix half-bracketed table that didn't turn hyphenation off prior to the `TS` call in the first place. Fizes: 9e54434ead ("man*/: ffix (un-bracket tables)") Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* termios.3: srcfixG. Branden Robinson2023-07-30-2/+0
| | | | | | | | | | | Continue commit 9e54434ead, 19 July. Fix an anomalously bracketed table, not detected by my sed script because of the intrusion of a *roff comment. Fizes: 9e54434ead ("man*/: ffix (un-bracket tables)") Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man*/: ffix (un-bracket tables, continued)G. Branden Robinson2023-07-30-24/+0
| | | | | | | | | | | | | | | | | Continue commit 9e54434ead, 19 July. 4 pages issued requests to manipulate adjustment and automatic hyphenation around tbl(1) tables in a different order from the other 525 documents in the tree that performed this trick. I produced this change with the following GNU sed script. /^\.nh/{N;/\n\.ad l/{N;/\n\.TS/s/.*/.TS/}} /^\.TE/{N;/\n\.ad/{N;/\n\.hy/s/.*/.TE/}} Fizes: 9e54434ead ("man*/: ffix (un-bracket tables)") Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* syscalls.2: srcfixG. Branden Robinson2023-07-30-2/+4
| | | | | | | | | | | | Clean up in preparation for "MR sed". Use font style alternation macros instead of font selection escape sequences to mark up man page cross references in table entry text blocks. Also protect them from hyphenation. (`MR` will take care of that for us.) Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* memcmp.3: Recast security caveatG. Branden Robinson2023-07-30-3/+11
| | | | | | | | | | | | | | | | Use terminology more carefully. * Refer to the info sec property of confidentiality[1] instead of saying, vaguely, "security-critical". * Try not to confuse anyone who's studied the analysis of algorithms: don't say "constant time" when "deterministic time" is meant. The time to perform the memory comparison remains linear (O(n)), not constant (O(1)). * Tighten wording. Link: [1] <https://informationsecurity.wustl.edu/items/confidentiality-integrity-and-availability-the-cia-triad/> Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* time.1: ffixG. Branden Robinson2023-07-30-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mark up ellipses properly. They should be in roman. The item preceding an ellipsis should be in the singular. Use unbreakable space between metasyntactic variable and subsequent ellipsis. (Whitespace-separated arguments should be separated from a subsequent ellipsis. "[-v...]" suggests that both "-vv" and "-v -v" are permitted; "[-v ...]" suggests only the latter.) Quoting groff_man_style(7): • Symbols that are neither to be typed literally nor replaced at the user’s discretion appear in the roman style; brackets surround optional arguments, and an ellipsis indicates that the previous syntactical element may be repeated arbitrarily. [...] • The dummy character escape sequence \& follows the ellipsis when further text will follow after space on the output line, keeping its last period from being interpreted as the end of a sentence and causing additional inter‐sentence space to be placed after it. [...] \| Thin space (one‐sixth em on typesetters, zero‐width on terminals); a non‐breaking space. Used primarily in ellipses (“.\|.\|.”) to space the dots more pleasantly on typesetting devices like dvi, pdf, and ps. [...] Several features of the above example are of note. [...] • The non‐breaking adjustable space escape sequence \~ is used to prevent the output line from being broken within the option brackets; see subsection “Portability” below. [...] • Why doesn’t the package provide a string to insert an ellipsis? Examples of ellipsis usage are shown above, in subsection “Command synopsis macros”. The idiomatic roff ellipsis is three dots (periods) with thin space escape sequences \| internally separating them. Since dots both begin control lines and are candidate end‐of‐sentence characters, however, it is sometimes necessary to prefix and/or suffix an ellipsis with the dummy character escape sequence \&. That fact stands even if a string is defined to contain the sequence; further, if the string ends with \&, end‐of‐sentence detection is defeated when you use the string at the end of an actual sentence. (Ending a sentence with an ellipsis is often poor style, but not always.) A hypothetical string EL that contained an ellipsis, but not the trailing dummy character \&, would then need to be suffixed with the latter when not ending a sentence. Instead of... ...do this. ────────────────────────────────────────────────── .ds EL \&.\|.\|. Arguments are Arguments are .IR src‐file\~ .\|.\|.\& .IR src‐file\~ \*(EL\& .IR dest‐dir . .IR dest‐dir . ────────────────────────────────────────────────── The first column practices a false economy; the savings in typing is offset by the cost of obscuring even the suggestion of an ellipsis to a casual reader of the source document, and reduced portability to non‐roff man page formatters that cannot handle string definitions. There is an ellipsis code point in Unicode, and some fonts have an ellipsis glyph, which some man pages have accessed in a non‐ portable way with the font‐dependent \N escape sequence. We discourage the use of these; on terminals, they may crowd the dots into a half‐width character cell, and will not render at all if the output device doesn’t have the glyph. In syntax synopses, missing ellipses can cause great confusion. Dots and space are universally supported. Signed-off-by: G. Branden Robinson <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* pipe.2: tfix: refer to correct sectionThomas Weißschuh2023-07-30-1/+1
| | | | | | | | | Commit 4131356cdab8 reorganized the sections a bit breaking the reference. Fix it. Fixes: 4131356cdab8 ("man*/, man-pages.7: VERSIONS, STANDARDS, HISTORY: Reorganize sections") Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* string_copying.7: tfixLennart Jablonka2023-07-29-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On some of the commas: There are a few of instances of Subject verb object partclause, advphrase. For example: This function catenates the input character sequence | subject | verb | object | contained in a null-padded wixed-width buffer, | participial clause | into a destination string. | adverbial phrase | Imagining the participial clause away, there shouldn't be a comma preceding the restrictive adverbial phrase: The input character sequence is really, always catenated into a destination string; that is essential. For example: This function catenates the input character sequence into a destination string. The participial clause, being non-restrictive---there is but one input character sequence that could be meant---, should be enclosed by commas. That is the existing comma's purpose and doesn't work without the added, first comma. Cc: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Lennart Jablonka <humm@ljabl.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man.7: ffixG. Branden Robinson2023-07-29-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `\c` escape sequence works in an argument to a macro call that is part of a paragraph tag with font style alternation macros, but not the ordinary font macros `B` and `I`. This is because `TP`, `B`, and `I` all set up input traps; the six font style alternation macros do not. The old formatting would, for some versions of some formatters, set the "[trailer]" text as part of the paragraph body, not the tag--like this. .UE [trailer] Terminate the link text of the preceding .UR macro, with the optional trailer (if present, usually a (and so on) This was a poorly understood--and undocumented--interaction of man(7) features until recently. Gory details involving nroff on Unix Version 7 (1979) running on a simulated PDP-11/45 are available.[1] Here is a comparison of the former and new markup. before ====== groff 1.22.3: BAD groff 1.22.4: GOOD groff 1.23.0: BAD mandoc 1.14.6: BAD now === groff 1.22.3: BAD groff 1.22.4: GOOD groff 1.23.0: GOOD mandoc 1.14.6: GOOD [1] https://savannah.gnu.org/bugs/?51468 https://lists.gnu.org/archive/html/groff/2022-06/msg00020.html Signed-off-by: G. Branden Robinson <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* string_copying.7: don't grant strl{cpy,cat} magicLennart Jablonka2023-07-29-5/+1
| | | | | | | | | | | | | | | | | A function can't check whether a pointer points to the start of a string. What it certainly can do is to keep reading until you either find a null byte or read the secret key that lies adjacent in memory and post it to your favorite mailing list. strlcpy and strlcat behave the exact same way any other function accepting a string behaves: If you don't pass a string, the behavior is undefined. And that, I believe, does not deserve a special mention here, seeing as all the other string functions don't get such a mention either. Link: <https://lore.kernel.org/linux-man/ZMQVYtquNN-s0IJr@beryllium/T/#u> Signed-off-by: Lennart Jablonka <humm@ljabl.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* prctl.2: Use mathematical notation for a rangeAlejandro Colomar2023-07-28-3/+6
| | | | | Reported-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man*/: srcfixG. Branden Robinson2023-07-28-11/+7
| | | | | | | | | | | | | | | | | | | | [Clean up in preparation for "MR sed".] Drop spurious, nilpotent uses of *roff `\c` escape sequence. Quoting groff_man_style(7): \c End a text line without inserting space or attempting a break. Normally, if filling is enabled, the end of a text line is treated like a space; an output line _may_ be broken there (if not, an adjustable space is inserted); if filling is disabled, the line _will_ be broken there, as in .EX/.EE examples. The next line is interpreted as usual and can include a macro call (contrast with \newline). \c is useful when three font styles are needed in a single word, as in a command synopsis. Signed-off-by: G. Branden Robinson <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* vfork.2: ffixG. Branden Robinson2023-07-28-5/+4
| | | | | | | | | | | | | | | [Clean up in preparation for "MR sed".] * Use typographer's quotation marks. * Quote the 4.2BSD vfork(2) page _exactly_, including font styling. https://minnie.tuhs.org/cgi-bin/utree.pl?file=4.2BSD/usr/man/man2/vfork.2 This is to remove a false positive in preparation for a sed(1)-driven update of man page cross references to use the groff 1.23.0 `MR` macro. Signed-off-by: G. Branden Robinson <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man.7: srcfixG. Branden Robinson2023-07-28-35/+35
| | | | | | | | | | | | | | | | | | [Clean up in preparation for "MR sed".] Drop spurious uses of *roff `\&` escape sequence. Quoting groff_man_style(7): \& Dummy character. Insert at the beginning of an input line to prevent a dot or apostrophe from being interpreted as beginning a roff control line. Append to an end‐of‐sentence punctuation sequence to keep it from being recognized as such. Neither case applies to the uses in this page. Signed-off-by: G. Branden Robinson <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* gettimeofday.2: Add details about the nullability of tv in different libc'sZijun Zhao2023-07-28-0/+11
| | | | | | | | | | | | | | | tv arg is allowed to be NULL in bionic. POSIX says this behavior is undefined, and bionic just exposes the Linux syscall directly. There's no code in bionic for gettimeofday/settimeofday; just a description of the syscall name and arguments from which an assembler stub is automatically generated at build time. musl and glibc go out of their way to behave differently from the Linux kernel, but no idea why. Signed-off-by: Zijun Zhao <zijunzhao@google.com> Cc: Elliott Hughes <enh@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* bpf.2: Added missing EAGAIN error case for BPF_PROG_LOADMichael Weiß2023-07-28-0/+10
| | | | | | | | | | | | | | | | | | | | | | | Since commit c3494801cd1785e2 ("bpf: check pending signals while verifying programs"), bpf() may also fail with EAGAIN if the verifier detects pending signals. This was triggered in the cmld of GyroidOS when loading a cgroups device program during container start. We had a look in the man page and were confused that EAGAIN was not listed as possible error. Digging in the kernel source revealed the EAGAIN in the verifier introduced by the commit above. Further investigation showed that libbpf already wraps that case, by a retry loop. Since GyroidOS uses the system call directly and not libbpf, we missed to handle this error correctly. Thus, this hint in the man page for the bpf() system call should be helpful for others who implement on the low-level interface, too. Signed-off-by: Michael Weiß <michael.weiss@aisec.fraunhofer.de> Cc: Alexei Starovoitov <ast@kernel.org> [alx: wfix] Signed-off-by: Alejandro Colomar <alx@kernel.org>
* abort.3: Clarify consequences of calling abort()Tomáš Golembiovský2023-07-28-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Clarify that atexit(3)/on_exit(3) are not called because those are called only on normal process termination (as documented on their respective manual pages). Check with the following test program: ```c #define _DEFAULT_SOURCE #include <stdio.h> #include <stdlib.h> void one(void) { puts("atexit called"); } void two(int, void*) { puts("on_exit called"); } int main(void) { atexit(one); on_exit(two, NULL); puts("terminating"); //abort(); exit(EXIT_SUCCESS); } ``` Cc: "G. Branden Robinson" <g.branden.robinson@gmail.com> Cc: Stefan Puiu <stefan.puiu@gmail.com> Signed-off-by: Tomáš Golembiovský <tgolembi@redhat.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* tmpfs.5: Update reference to CONFIG_TRANSPARENT_HUGEPAGEJohn Hubbard2023-07-28-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | In commit 462a385e9a2 ("tmpfs.5: Document current mount options"), there is a reference to CONFIG_TRANSPARENT_HUGE_PAGECACHE. However, that option was removed from the kernel via commit 396bcc5299c2 ("mm: remove CONFIG_TRANSPARENT_HUGE_PAGECACHE"), a couple of years later. The net effect is that CONFIG_TRANSPARENT_HUGEPAGE is now used in all the remaining places in the kernel where CONFIG_TRANSPARENT_HUGE_PAGECACHE had previously been used. This has caused some minor confusion at the man page level, though. So let's fix it by updating the man page to refer to CONFIG_TRANSPARENT_HUGEPAGE. Reported-by: Vahid Noormofidi <vnoormof@nvidia.com> Cc: Matthew Wilcox (Oracle) <willy@infradead.org> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Carsten Grohmann <carstengrohmann@gmx.de> Cc: Mike Frysinger <vapier@gentoo.org> Signed-off-by: John Hubbard <jhubbard@nvidia.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man*/: ffix (un-bracket tables)G. Branden Robinson2023-07-20-2100/+1422
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Stop disabling adjustment and automatic hyphenation before tables, and incorrectly "restoring" it afterward. In addition to repetitious boilerplate around tables, the `ad` and `hy` requests, when not given arguments, do not behave as many man page authors expect. If adjustment was initially disabled when rendering the page, it was being activated after `TE` calls, frustrating the desire of the reader. Furthermore, `hy` when given no argument enables automatic hyphenation in mode "1", which is not an appropriate value for the TeX-based hyphenation patterns for English that groff has used for over 30 years. And analogously to `ad`, a simple `hy` request would reactivate automatic hyphenation even if the reader had disabled it. Moreover, such fiddling is often unnecessary. tbl(1) from groff 1.23.0 describes how tbl(1) has always worked, dating back to Michael Lesk's original implementation at Bell Labs in the 1970s. "Ordinarily, a table entry is typeset rigidly. It is not filled, broken, hyphenated, adjusted, or populated with additional inter- sentence space. ... Text blocks are formatted as was the text prior to the table, modified by applicable column descriptors. ... Add na or ad requests to the beginning of a text block to alter its adjustment distinctly from other text in the document. As with other table entries, when a text block ends, any alterations to formatting parameters are discarded. They do not affect subsequent table entries, not even other text blocks." * Apropos of the foregoing, add `na` and `nh` requests to the "Interface" columns of MT-safety tables in pages' "ATTRIBUTES" sections, so that C function names are not inappropriately hyphenated. I produced this change with the following GNU sed script. :start /^\.ad l/{N;/\n\.nh/{N;/\n\.TS/s/.*/.TS/}} /^\.TE/{N;/\n\.hy/{N;/\n\.ad/s/.*/.TE/}} /^Interface.*Attribute.*Value/{N;/\nT{/s/.*/&\n.na\n.nh/ :loop n /T{/s/.*/&\n.na\n.nh/ /^\.TE/b start; b loop } Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man*/: ffix (use `\%`)G. Branden Robinson2023-07-20-8/+8
| | | | | | | | | | | | | | | | | | | | Protect instances of some literals from hyphenation. These are only those necessary to improve analyzability of a large-scale (500+ file), sed-driven change to improve adjustment and hyphenation enablement management around tables. * man2/getrlimit.2: Protect some instances of `RLIMIT_MSGQUEUE`, `RLIMIT_SIGPENDING`, `RLIMIT_FSIZE`, and `getrlimit` from hyphenation. * man2/sigaltstack.2: Protect an instance of `setrlimit` from hyphenation. * man3/gethostbyname.3: Protect an instance of `endhostent` from hyphenation. * man3/getmntent.3: Protect an instance of `getmntinfo` from hyphenation. Signed-off-by: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* recv.2: Document MSG_CMSG_CLOEXEC as returned in msg_flagsMatthew House2023-07-18-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ever since commit 4a19542e5f69 ("O_CLOEXEC for SCM_RIGHTS") added the MSG_CMSG_CLOEXEC flag to recvmsg(2), the flag has also been copied into the returned msg->msg_flags when specified, regardless of whether any file descriptors were actually received, or whether the protocol supports receiving file descriptors at all. This behavior was primarily an implementation artifact: by copying MSG_CMSG_CLOEXEC into the msg_flags, scm_detach_fds() in net/core/scm.c (and its _compat() counterpart in net/compat.c) could determine whether it was set without having to receive a copy of the recvmsg(2) flags. This mechanism was closely modeled after the internal MSG_CMSG_COMPAT flag, which is passed by the compat versions of the send[m]msg(2) and recv[m]msg(2) syscalls to inform various functions that user space expects a compat layout. When the flag was first implemented by commits 3225fc8a85f4 ("[NET]: Simplify scm handling and sendmsg/recvmsg invocation, consolidate net compat syscalls.") and 7e8d06bc1d90 ("[COMPAT]: Fix MSG_CMSG_COMPAT flag passing, kill cmsg_compat_recvmsg_fixup.") (in history/history.git), the behavior was very similar: recvmsg(2) would add MSG_CMSG_COMPAT to the msg_flags, and put_cmsg() and scm_detach_fds() in net/core/scm.c would read the flag to determine whether to delegate to their _compat() counterparts. However, after the initial implementation, more work was done to hide MSG_CMSG_COMPAT from user space. First, commit 37f7f421cce1 ("[NET]: Do not leak MSG_CMSG_COMPAT into userspace.") started scrubbing the bit from msg_flags right before copying it back into user space. Then, since passing the MSG_CMSG_COMPAT flag into the syscalls from non-compat code could confuse the kernel, commits 1be374a0518a ("net: Block MSG_CMSG_COMPAT in send(m)msg and recv(m)msg") and a7526eb5d06b ("net: Unbreak compat_sys_{send,recv}msg") made them return -EINVAL if user space attempted to pass the flag. But to reduce breakage, commit d720d8cec563 ("net: compat: Ignore MSG_CMSG_COMPAT in compat_sys_{send, recv}msg") rolled that back somewhat, making MSG_CMSG_COMPAT an error for the non-compat syscalls and a no-op for the compat syscalls, which is the current status quo. Even though MSG_CMSG_CLOEXEC was implemented after the kernel started scrubbing MSG_CMSG_COMPAT from the returned msg_flags, the newer flag never received the same treatment. At this point, this behavior has effectively become part of the user-space API, to the extent that io_uring has been careful in commit 9bb66906f23e ("io_uring: support multishot in recvmsg") to replicate the behavior in its multishot IORING_OP_RECVMSG operation. Therefore, document this behavior to avoid confusion when user space sees MSG_CMSG_CLOEXEC returned in msg->msg_flags. On 2023-07-18 15:24, Ulrich Drepper wrote: > On Tue, Jul 18, 2023 at 2:10 PM Alejandro Colomar <alx@kernel.org> wrote: >> On 2023-07-18 08:00, Matthew House wrote: >>> >>> As for the original purpose of the behavior, it's not really clear, >>> and it may well have been an implementation artifact that got >>> enshrined in the user space ABI. >>> (Even io_uring is careful to replicate this behavior!) >> >> This is what worries me. I've CCd a bunch of people to see if they can >> bring some light. > > It definitely was an artifact of the implementation. I haven't tested > getting the close-on-exec flag information for all interfaces. The > assumption was that the information about the close-on-exec flag is > received with the universal fcntl() call. Cc: linux-api@vger.kernel.org Cc: netdev@vger.kernel.org Cc: Ulrich Drepper <drepper@redhat.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Matthew House <mattlloydhouse@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* statfs.2: Unshade as deprecated, but direct to statvfs(3)наб2023-07-18-2/+8
| | | | | | Link: https://lore.kernel.org/linux-man/f54kudgblgk643u32tb6at4cd3kkzha6hslahv24szs4raroaz@ogivjbfdaqtb/t/#u Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* grantpt.3: It's a no-op on modern glibc and other UNIXes; HISTORYiseнаб2023-07-18-12/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | FreeBSD, OpenBSD, and Linux (/dev/ptmx) do all intialisation in open(2), and grantpt(3) is a no-op (that checks whether the fd is a pty, except on musl). The illumos gate and NetBSD do a ioctl (and, indeed, illumos-gate commit facf4a8d7b59fde89a8662b4f4c73a758e6c402c ("PSARC/2003/246 Filesystem Driven Device Naming"), which kills pt_chmod, notes that it's been "6464196 bfu should remove pt_chmod, obsoleted by /dev filesystem"). glibc 2.33 completely kills BSD PTY support on Linux (Debian hasn't configured with them on any architecture since 2007: https://bugs.debian.org/338404 and even earlier on some arches; they're really just trivia under Linux ‒ this may be better served stuffed into HISTORY as an explainer for the SIGCHLD thing, since regardless of the "version", the behaviour is well-defined and consistent). There really aren't many cohesive "versions" of this ‒ indeed, so long as grantpt(3) exists it behaves precisely as described here ‒ inasmuch as different systems, historically, had different ptys, and thus different implementations. These are all but trivia. Cc: Jakub Wilk <jwilk@jwilk.net> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* complex.7: Add LIBRARY section (libm)Alejandro Colomar2023-07-18-1/+3
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* cpuset.7: wfixAlejandro Colomar2023-07-18-2/+6
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* ld.so.8: ffixAlejandro Colomar2023-07-18-1/+1
| | | | | Cc: "G. Branden Robinson" <g.branden.robinson@gmail.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* CONTRIBUTING: tzselect(8) also comes from tzAlejandro Colomar2023-07-17-2/+2
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* *.mk: Escape newlines instead of using +=Alejandro Colomar2023-07-17-44/+55
| | | | | | | | | | | | | It's more robust to only spell the variable name once. We've fixed typos related to that in the past, and in this patch we're fixing another one: DEFAULT_CPPCHECKFLAgS += --inconclusive Even if we could merge some of those lines into one (because they're short), I prefer to keep one line per option. Semantic newlines, aren't they? :) Signed-off-by: Alejandro Colomar <alx@kernel.org>
* Makefile: SimplifyAlejandro Colomar2023-07-17-4/+1
| | | | | Suggested-by: Andreas Schwab <schwab@suse.de> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* ld.so.8: tfix: Correct linker option nameFangrui Song2023-07-16-2/+2
| | | | | | | | | | | | | | | The linker option that sets the DF_1_NODEFLIB flag is -z nodefaultlib. -z nodeflib is invalid. ``` % ld.bfd -m elf_x86_64 -e 0 /dev/null -z nodeflib ld.bfd: warning: -z nodeflib ignored % ld.lld -m elf_x86_64 -e 0 /dev/null -z nodeflib ld.lld: warning: unknown -z value: nodeflib ``` Signed-off-by: Fangrui Song <maskray@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* Makefile: SimplifyAlejandro Colomar2023-07-16-43/+8
| | | | | | | | | Suggested-by: Dmitry Goncharov <dgoncharov@users.sf.net> Suggested-by: Torbjorn SVENSSON <torbjorn.svensson@foss.st.com> Cc: Philip Guenther <guenther@gmail.com> Cc: Bruno Haible <bruno@clisp.org> Cc: Paul Smith <psmith@gnu.org> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* Makefile: Add include guardAlejandro Colomar2023-07-16-0/+8
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* epoll_create.2: HISTORYise "max_user_instances" EMFILEнаб2023-07-16-8/+11
| | | | | | | | | | | | /proc/sys/fs/epoll/max_user_instances hasn't existed since commit 9df04e1f25effde823a600e755b51475d438f56b ("epoll: drop max_user_instances and rely only on max_user_watches") from Date: Thu Jan 29 14:25:26 2009 -0800 which describes to v2.6.29-rc3-24-g9df04e1f25ef. Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* Makefile: Improve Makefile troubleshootingAlejandro Colomar2023-07-16-0/+24
| | | | | | | | | Add an empty double-colon rule that targets the makefiles, to instruct make(1) to not remake makefiles. This improves (considerably reduces) the output of 'make -d'. Suggested-by: Dmitry Goncharov <dgoncharov@users.sf.net> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* crypt.3, encrypt.3: Fix library name and descriptionXi Ruoyao2023-07-16-17/+17
| | | | | | | | | | | | libcrypt is the password hashing library, and libcrypto is a completely different library (OpenSSL cryptography library). While the encrypt() function can "encrypt" things, it uses a broken algorithm so let's not call libcrypt an "encryption" library at all. In crypt.3, also replace "encrypt" with "hash" except several places where it really means "encrypt". Signed-off-by: Xi Ruoyao <xry111@xry111.site> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man2/: Use SPDX-License-Identifier: Linux-man-pages-copyleft-varAlejandro Colomar2023-07-16-57/+6
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* LICENSES/Linux-man-pages-copyleft-var.txt: Add license textAlejandro Colomar2023-07-16-0/+16
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* pipe.7: document read()s with O_NONBLOCKнаб2023-07-16-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | Which don't behave like you may expect them to; unprimed, I expected the natural extension of either: files (being a filesystem object), always returning 0 if no data, or sockets (being an IPC mechanism), always EAGAINing if no data. The pipe semantics make sense of course ‒ pipes can be modelled as sockets if there aren't writers, but files if there are; indeed, this makes sense as the writer continuously appending a sliding "window" over a file ‒ but they're unique amongst the UNIX file types, but arriving at that specific interaction table is non-obvious, especially to a user. Quoth Issue 8 Draft 3: 60746 When attempting to read from an empty pipe or FIFO: 60747 • If no process has the pipe open for writing, read( ) shall return 0 to indicate end-of-file. 60748 • If some process has the pipe open for writing and O_NONBLOCK is set, read( ) shall return 60749 −1 and set errno to [EAGAIN]. 60750 • If some process has the pipe open for writing and O_NONBLOCK is clear, read( ) shall 60751 block the calling thread until some data is written or the pipe is closed by all processes that 60752 had the pipe open for writing. Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man2/: Use SPDX-License-Identifier: Linux-man-pages-copyleft-2-paraAlejandro Colomar2023-07-15-22/+4
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* LICENSES/Linux-man-pages-copyleft-2-para.txt: Add license textAlejandro Colomar2023-07-15-0/+8
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* man*/: Use SPDX-License-Identifier: Linux-man-pages-1-paraAlejandro Colomar2023-07-15-125/+36
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* LICENSES/Linux-man-pages-1-para.txt: Add license textAlejandro Colomar2023-07-15-0/+4
| | | | Signed-off-by: Alejandro Colomar <alx@kernel.org>
* .mailmap: Remove fileAlejandro Colomar2023-07-15-12/+0
| | | | | | | It's unmaintainable. Reported-by: Serge Hallyn <serge@hallyn.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
* socket.7: tfixEric Biggers2023-07-15-1/+1
| | | | | Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>