Commit Graph

2940 Commits

Author SHA1 Message Date
Michael Kerrisk 50fe8d5366 ptrace.2: Note SPARC deviation with respect to get/set regs
SPARC reverses the use of 'addr' and 'data' for
PTRACE_GETREGS, PTRACE_GETFPREGS, PTRACE_SETREGS,
and PTRACE_SETFPREGS.

Reported-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:11:45 +12:00
Michael Kerrisk c7c7235c38 prctl.2: Amend details of PR_SET_PDEATHSIG
The corresponding kernel change from Marchel Holtmann was

    The attached patch fixes a flaw in the "parent process
    death signal" when executing SUID binaries. An
    unprivileged user may send arbitrary signal to a child
    process even if it is running with higher privileges.

    The idea to fix this issue is to reset pdeath_signal not
    only on fork, but also on the execution of a SUID binary.

Reported-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-23 21:30:59 +12:00
Michael Kerrisk 7cb4d005c6 fallocate.2: Fix description of ENOSYS and EOPNOTSUP errors
As reported in https://bugzilla.redhat.com/show_bug.cgi?id=680214
the descriptions of ENOSYS and EOPNOTSUP are not corrected

Reported-by: John Sullivan <jsrhbz@kanargh.force9.co.uk>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-23 10:07:47 +12:00
Stefan Puiu 4c49bf908c send.2: Document EACCES error case for UDP
It seems sendto() can return EACCES for UDP as well; the current
man page in git only says it can return EACCES for Unix sockets.

I was able to make sendto() return EACCES if I try to send from
192.168.1.1/24 to 192.168.1.0. I think the relevant code (in
kernel 2.6.38, but also present in 2.6.7 and 2.6.32, the 2 kernels
we use) is this (net/ipv4/udp.c, udp_sendmsg()):

 910                err = -EACCES;
 911                if ((rt->rt_flags & RTCF_BROADCAST) &&
 912                    !sock_flag(sk, SOCK_BROADCAST))
 913                        goto out;

So I guess if the kernel finds a route to the destination and
it's a broadcast route (and the socket doesn't have the broadcast
flag), then it returns EACCES.

I can verify the behavior with a very simple program (attached).
I've run it on my Ubuntu 10.10 (2.6.35 kernel) and got this:

stefan@spuiu-vml2:~/src/test/broadcast$ ./broadcast_test 10.205.20.94
10.205.20.1
sendto() returned 4
stefan@spuiu-vml2:~/src/test/broadcast$ ./broadcast_test 10.205.20.94
10.205.20.0
sendto() returned negative, errno: 13/Permission denied

(10.205.20.94 is my local IP, of course).

=====
    #include <stdio.h>

    #include <sys/types.h>
    #include <sys/socket.h>
    #include <netinet/in.h>
    #include <arpa/inet.h>
    #include <errno.h>
    #include <stdlib.h>

    int main(int argc, char **argv)
    {
        int sock;

        if (argc < 2) {
            printf("Usage: %s local_address destination_address\n", argv[0]);
            exit(1);
        }

        sock = socket(AF_INET, SOCK_DGRAM, 0);
        if (sock < 0) {
            perror("socket");
            return -1;
        }

        struct sockaddr_in local_addr;
        local_addr.sin_family = AF_INET;
        local_addr.sin_port = htons(1234);
        local_addr.sin_addr.s_addr = inet_addr(argv[1]);
        int ret = bind(sock, (struct sockaddr *) &local_addr, sizeof(local_addr));
        if (ret < 0) {
            perror("bind");
            return -1;
        }

        struct sockaddr_in remote_addr;
        remote_addr.sin_family = AF_INET;
        remote_addr.sin_port = htons(1234);
        remote_addr.sin_addr.s_addr = inet_addr(argv[2]);
        ret = sendto(sock, "blah", 4, 0, (struct sockaddr *)&remote_addr, sizeof(remote_addr));
        if (ret < 0) {
            printf("sendto() returned negative, errno: %d/%m\n", errno);
        }
        else {
            printf("sendto() returned %d\n", ret);
        }

        return 0;
    }
=====

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-23 08:15:01 +12:00
Michael Kerrisk a146d9cccd fchmodat.2: Improve discussion of difference between wrapper and underlying syscall
Reported-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-22 07:09:18 +12:00
Michael Kerrisk 0364dd73e4 fchmodat.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-22 06:55:30 +12:00
Michael Kerrisk cbf94ac122 sigaction.2: Remove mention of raise(3) for SI_USER
For a long time now, glibc's raise(3) didn't yield SI_USER
for the signal receiver, so remove mention of raise(3)
here. The user can deduce the details, if needed, by looking
at the recently updated raise(3) page.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-20 13:14:31 +12:00
Michael Kerrisk b546a5284b bind.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-18 09:47:59 +12:00
Michael Kerrisk 437e08fc95 fchmodat.2: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:25:14 +12:00
Michael Kerrisk 50b5741877 Removed trailing white space at end of lines 2012-04-17 23:09:04 +12:00
Michael Kerrisk 69287cb678 prctl.2: Fixes to PR_SET_MM after comments from Cyrill
Remove some FIXMEs and comment out pieces of text that describe
features not yet merged mainline kernel.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:09:04 +12:00
Michael Kerrisk 3612be0418 prctl.2: Various edits and improvements to Cyrill's patch
* Wording improvements

* Addition of some FIXMEs for suspicious points

* Addition of various EINVAL cases

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:09:04 +12:00
Cyrill Gorcunov 3a620d0b7b prctl.2: Document PR_SET_MM (new in Linux 3.3)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:09:04 +12:00
Michael Kerrisk 3062824dae mmap.2: Clarify NOTES discussion of mmap() versus mmap2()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:09:04 +12:00
Michael Kerrisk 02ddee60aa mmap2.2: Clarify that this system call should not be invoked directly
See https://bugzilla.kernel.org/show_bug.cgi?id=42892

Reported-by: Kevin O'Gorman <kevinogorman4@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:09:04 +12:00
Michael Kerrisk 962232bffc times.2: ERRORS: Add EFAULT
As Simone notes, RETURN VALUE says:

On error, (clock_t) -1 is returned, and errno is set appropriately

but no value for errno is specified.  The only error case is
EFAULT, so let's add that.

Reported-by: Simone Piccardi <piccardi@truelite.it>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-17 23:08:58 +12:00
Michael Kerrisk 20d58e69bd times.2: tfix: BUGS: clockid_t ==> clock_t
Reported-by: Simone Piccardi <piccardi@truelite.it>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-16 08:27:09 +12:00
Michael Kerrisk b857fda584 poll.2: Document semantics of passing zero in 'events' field
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-16 08:27:09 +12:00
Michael Kerrisk 096ca08af4 poll.2: Document negative value in 'fd' field
Reported-by: Michael Welsh Duggan <mwd@cert.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-16 08:27:09 +12:00
Mike Frysinger ef30129360 sigprocmask.2: ERRORS: add EFAULT
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-16 08:27:09 +12:00
Michael Kerrisk 2d350ede02 fchmodat.2: Note difference between glibc wrapper and underlying system call
The wrapper function has a 'flags' argument (which currently
serves no purpose), while the underlying system call does not.

Reported-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-16 08:26:36 +12:00
Michael Kerrisk d660ffd524 fchmodat.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-16 08:18:29 +12:00
Abhijith Das a8ceabbc8c fcntl.2: Explain behaviour of F_GETLEASE during lease break
Here's a patch to the fcntl.2 manpage that explains
the working of F_GETLEASE in a bit more detail during
lease breaks. Basically, what happens is this: When a
lease break is initiated by a lease breaker, subsequent
F_GETLEASE calls return the target lease type after
the lease break and not the existing lease type. This
behavior persists until the lease holder downgrades/unlocks
the lease or the kernel forcibly does it after the lease
break timeout expires.

The implicit assumption is that F_GETLEASE should
return the existing lock type until the downgrade/unlock
has actually taken place, which is not true. I've verified
that the kernel indeed returns the target lease type. It
is also simple enough to verify this behavior in a small
program, where you can observe that the lease type
returned by F_GETLEASE in the signal handler for a
lease break is different from the existing lease type.

Signed-off-by: Abhijith Das <adas@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 10:43:00 +12:00
Michael Kerrisk 7396b79c68 epoll_wait.2: Another thread can add to epoll instance while epoll_wait is blocked
See https://bugzilla.kernel.org/show_bug.cgi?id=43072

Reported-by: Armin Rigo <arigo@tunes.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk 70a6338b76 epoll_wait.2: A few wording improvements
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk 72bbde85be epoll_wait.2: Clarify that epoll_pwait() blocks calling *thread*
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk 284976f891 epoll_wait.2: Minor change: add explicit reference to epoll(7) at start of DESCRIPTION
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk fde633deb6 epoll_create.2: Rework discussion of 'size' argument
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk 6b6f540407 epoll_create.2: Add .SS for description of epoll_create1()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk 5f4e9d5acd epoll_create.2: Minor change: add explicit reference to epoll(7) at start of DESCRIPTION
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk 78d1cbdec8 epoll_ctl.2: Minor change: add explicit reference to epoll(7) at start of DESCRIPTION
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-15 09:39:52 +12:00
Michael Kerrisk f1e90ec441 gettimeofday.2: Note that compiler issues warnings if 'tv' is NULL
Reported-by: Felix <fkater@googlemail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-12 13:16:49 +12:00
Michael Kerrisk d5c4e19747 gettimeofday.2: Reorganize content
The main change is to move the historical information about
the 'tz_dsttime' to NOTES.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-12 13:10:57 +12:00
Michael Kerrisk dff6bb1919 sigaction.2: Clarify that the use of SI_SIGIO is for Linux 2.2 only
See also http://sourceware.org/bugzilla/show_bug.cgi?id=6745

Reported-by: Andreas Jaeger <aj@suse.com>
Reported-by: <who@connect.carleton.ca>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-12 11:47:43 +12:00
Michael Kerrisk d53de2a707 select.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-12 05:44:52 +12:00
Michael Kerrisk ed9821bba0 fcntl.2: Change type of arg from "long" to "int"
Various fcntl(2) commands require an integral 'arg'.
The man page said it must be "long" in all such cases.
However, for the cases covered by POSIX, there is an
explicit requirement that these arguments be "int".
Update the man page to reflect. Probably, all of the
other "long" cases (not specified in POSIX) should
be "int", and this patch makes them so. Based on a
note fromEric Blake, relating to F_DUPFD_CLOEXEC.

Reported-by: Eric Blake <ebb9@byu.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-30 07:36:20 +13:00
Michael Kerrisk d39a9b9833 ptrace.2: Minor edits to Denys Vlasenko's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-30 06:59:50 +13:00
Denys Vlasenko b16ecdae13 ptrace.2: Various fixes
For some reason, the PTRACE_TRACEME paragraph talks about some
general aspects of ptraced process behavior. It repeats the
"tracee stops on every signal" information even though that was
already explained just a few paragraphs before. Then it describes
legacy SIGTRAP on execve().

This patch deletes the first part, and moves the second part up,
into the general ptrace description. It also adds
"If PTRACE_O_TRACEEXEC option is not in effect" to the description
of the legacy SIGTRAP on execve().

The patch also amends the part which says "For requests other
than PTRACE_KILL, the tracee must be stopped." - PTRACE_ATTACH
also doesn't require that.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-30 06:59:50 +13:00
Michael Kerrisk d2470c5d28 gettid.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-29 12:43:47 +13:00
Michael Kerrisk a4405ff934 clone.2, unshare.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-29 12:43:30 +13:00
Michael Kerrisk c86365595d symlinkat.2: PROTOTYPE: Correct header file
Reported-by: Eric Blake <ebb9@byu.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 07:20:14 +13:00
Michael Kerrisk 3045389f28 utimensat.2: PROTOTYPE: Add <fcntl.h> for AT_* constants
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 07:20:14 +13:00
Michael Kerrisk 4075a06302 unlinkat.2: PROTOTYPE: Add <fcntl.h> for AT_* constants
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 07:20:14 +13:00
Michael Kerrisk a917d281e5 unlinkat.2: PROTOTYPE: Correct header file
Reported-by: Eric Blake <ebb9@byu.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 07:20:14 +13:00
Michael Kerrisk 959c1dc498 symlinkat.2: PROTOTYPE: Correct header file
Reported-by: Eric Blake <ebb9@byu.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 07:20:14 +13:00
Michael Kerrisk ba78c947f0 futimesat.2: PROTOTYPE: Correct header file and feature test macro requirements
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 07:19:45 +13:00
Michael Kerrisk ea4282fa86 fcntl.2: wfix: /proc/sys/fs/pipe-size-max ==> /proc/sys/fs/pipe-max-size
Reported-by: Matthew Gregan <kinetik@flim.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-25 06:51:50 +13:00
Michael Kerrisk be02e49f7c open.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-24 13:05:14 +13:00
David Prévot a5c725cfd3 ptrace.2: ffix and tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-24 13:05:14 +13:00
Michael Kerrisk 8f318249c6 ptrace.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-24 11:59:07 +13:00
Denys Vlasenko b16d33ef72 ptrace.2: Document PTRACE_GETEVENTMSG for PTRACE_EVENT_EXEC
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-24 11:59:07 +13:00
Michael Kerrisk 0597933fb0 syscalls.2: Remove unimplemented system calls from main syscall list
The unimplemented system calls are in any case noted lower down
in the page. Also: rearrange the text describing the unimplemented
system calls.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>

syscalls.2: fix

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-24 11:58:59 +13:00
Michael Kerrisk 1d3dc33c72 syscalls.2: Add process_vm_readv(2) and process_vm_writev(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-23 14:20:26 +13:00
Michael Kerrisk 13f66890a4 syscalls.2: Note a few system calls that were removed in Linux 2.6
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-23 14:09:47 +13:00
Bjarni Ingi Gislason a92d3bb413 keyctl.2: Strip trailing tabs from source line
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=664688

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-21 06:54:30 +13:00
Michael Kerrisk a17e05c5e0 ptrace.2: Minor fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-20 07:45:58 +13:00
Denys Vlasenko f098951d39 ptrace.2: Various fixes to recent updates of this page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-20 07:45:53 +13:00
David Prévot 381ee84e1a fallocate.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-20 07:44:29 +13:00
Michael Kerrisk 01b844cc10 rt_sigqueueinfo.2, iswctype.3, longjmp.3: Minor fix: add Section number to page xref
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 04:58:10 +13:00
Michael Kerrisk 02cb2646e0 rt_sigqueueinfo.2: spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 04:46:10 +13:00
Michael Kerrisk c90561d7bb rt_sigqueueinfo.2: spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 04:45:27 +13:00
Michael Kerrisk 3ba9126c04 rt_sigqueueinfo.2: spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 04:44:55 +13:00
Michael Kerrisk 6030f2d859 add_key.2, keyctl.2, request_key.2, offsetof.3, pthread_attr_init.3, pthread_attr_setaffinity_np.3, pthread_attr_setdetachstate.3, pthread_attr_setguardsize.3, pthread_attr_setinheritsched.3, pthread_attr_setschedparam.3, pthread_attr_setschedpolicy.3, pthread_attr_setscope.3, pthread_attr_setstackaddr.3, pthread_attr_setstacksize.3, pthread_cancel.3, pthread_cleanup_push.3, pthread_cleanup_push_defer_np.3, pthread_equal.3, pthread_exit.3, pthread_getattr_np.3, pthread_getcpuclockid.3, pthread_self.3, pthread_setaffinity_np.3, pthread_setcancelstate.3, pthread_setconcurrency.3, pthread_setschedparam.3, pthread_setschedprio.3, pthread_testcancel.3: Global formatting fix: balance .nf/.fi pairs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 04:37:22 +13:00
Michael Kerrisk c9f2ff9d7e _exit.2, chmod.2, abs.3, cbrt.3, mkdtemp.3: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 04:22:05 +13:00
Michael Kerrisk 2bfa8272f0 intro.2, btowc.3, intro.3, pthread_sigqueue.3: Correct order of SEE ALSO entries
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 03:58:56 +13:00
Michael Kerrisk 7a5b06940e vfork.2: Minor wording fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-13 03:50:13 +13:00
Michael Kerrisk f23cc1df32 ptrace.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-10 06:30:59 +13:00
Michael Kerrisk 66d90115ca utimensat.2, wait.2, end.3: srcfix: remove duplicate words in comments
Reported-by: Justin T Pryzby <justinp@norchemlab.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-09 04:26:06 +13:00
Michael Kerrisk d6e37473a1 Removed trailing white space at end of lines 2012-03-06 08:54:38 +13:00
Michael Kerrisk b8d02d5633 ptrace.2: Further improvements after review by Denys Vlasenko
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Michael Kerrisk a42c0c5a19 ptrace.2: grfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Michael Kerrisk dc85ba7ce5 ptrace.2: Integrated changes after further review from Denys Vlasenko
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Michael Kerrisk 8898a252ad ptrace.2: Integrated changes after review from Denys Vlasenko
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Michael Kerrisk 181f997f23 ptrace.2: Global clean-up of page
* Wording and formatting fixes to existing text and
  Denys Vlasenko's new text.
* Various technical amendments and improvements to
  Denys Vlasenko's new text.
* Added FIXME for various problems with the current text.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Michael Kerrisk 8b20acd1aa ptrace.2: srcfix: Wrap lines at sentence boundaries
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Denys Vlasenko 4d12a715f2 ptrace.2: add extended description of various ptrace quirks
Changes include:

s/parent/tracer/g, s/child/tracee/g - ptrace interface now
is sufficiently cleaned up to not treat tracing process
as parent.

Deleted several outright false statements:
- pid 1 can be traced
- tracer is not shown as parent in ps output
- PTRACE_ATTACH is not "the same behavior as if tracee had done
  a PTRACE_TRACEME": PTRACE_ATTACH delivers a SIGSTOP.
- SIGSTOP _can_ be injected.
- Removed mentions of SunOS and Solaris as irrelevant.
- Added a few more known bugs.

Added a large block of text in DESCRIPTION which doesn't focus
on mechanical description of each flag and operation, but rather
tries to describe a bigger picture. The targeted audience is
a person which is reasonably knowledgeable in Unix but did not
spend years working with ptrace, and thus may be unaware of its
quirks. This text went through several iterations of review by
Oleg Nesterov and Tejun Heo.
This block of text intentionally uses as little markup as possible,
otherwise future modifications to it will be very hard to make.

Reviewed-by: Oleg Nesterov <oleg@redhat.com>
Reviewed-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-06 08:45:57 +13:00
Michael Kerrisk 18a97acf29 syscalls.2: Note that nfsservctl(2) was removed in Linux 3.1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-05 13:15:52 +13:00
Michael Kerrisk 70a3e2734f syscalls.2: Note that bdflush(2) is deprecated
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-05 13:15:25 +13:00
Michael Kerrisk dcee880f07 nfsservctl.2: Note that this system call was removed in Linux 3.1
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-05 13:14:10 +13:00
Michael Kerrisk 966ba49822 bdflush.2: Note that bdflush() is deprecated, and does nothing
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-05 13:14:10 +13:00
Michael Kerrisk b9145b2cab clone.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-03-03 06:54:00 +13:00
Michael Kerrisk 706b0ab140 Removed trailing white space at end of lines 2012-02-27 14:14:12 +13:00
Michael Kerrisk 1901002c4a fallocate.2, fork.2, open.2, send.2: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 14:12:16 +13:00
Michael Kerrisk ba9830cfc9 fsync.2: Note that some systems require a writable file descriptor
An edited version of Guillem Jover's comments:
[While the file descriptor does not need to be writable on Linux]
that's not a safe portable assumption to make on POSIX in general
as that behavior is not specified and as such is
implementation-specific. Some Unix systems do actually fail on
read-only file descriptors, for example [HP-UX and AIX].

Reported-by: Guillem Jover <guillem@hadrons.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:50:55 +13:00
Michael Kerrisk ad4760331e fsync.2: Minor clean-ups of Christoph's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:50:55 +13:00
Christoph Hellwig 71ae2f4a3f fsync.2: Various improvements
- explain the situation with disk caches better
- remove the duplicate fdatasync() explanation in the NOTES
  section
- remove an incorrect note about fsync() generally requiring two
  writes
- remove an obsolete ext2 example note
- fsync() works on any file descriptor (doesn't need to be
  writable); correct the EBADF error code explanation

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:49:25 +13:00
Michael Kerrisk c0c3d0195d fallocate.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk 7eb92881ee fallocate.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk 54d25ecaec fallocate.2: ERRORS: Add EPERM error case for FALLOC_FL_PUNCH_HOLE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk f52e0be8bb fallocate.2: Substantial restructuring of DESCRIPTION
The addition of a second class of operation ("hole punching")
to the man page made it clear that some significant restructuring
is required. So I substantially reworked the page, including the
preexisting material on the default "file allocation" operation.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk 96575bbc0e fallocate.2: Add further details for FALLOC_FL_PUNCH_HOLE
Reported-by: Josef Bacik <josef@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Lucian Adrian Grijincu 1c7857e9dd fallocate.2: Document FALLOC_FL_PUNCH_HOLE
FALLOC_FL_PUNCH_HOLE was added in Linux 2.6.38,
for punching holes in the allocated space in a file.

Signed-off-by: Lucian Adrian Grijincu <lucian.grijincu@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk 74819bb2b8 request_key.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk be464b55a0 add_key.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 13:30:55 +13:00
Michael Kerrisk 174428192d sendmmsg.2: minor changes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 11:11:48 +13:00
Michael Kerrisk 969d3d9e76 sendmmsg.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 11:10:11 +13:00
Michael Kerrisk 53aeb9c2da send.2: Add mention of sendmmsg(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 11:10:11 +13:00
Michael Kerrisk 82c182484a sendmmsg.2: New page for sendmmsg(2)
Some pieces inspired by an initial attempt by Stephan Mueller.

Reported-by: Stephan Mueller <stephan.mueller@atsec.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-27 11:10:11 +13:00
Michael Kerrisk d5563c9427 dup.2: SYNOPSIS: Add "#include <fntl.h>" for O_* constants
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-14 10:19:54 +13:00
Michael Kerrisk 509b5e8b73 pipe.2: SYNOPSIS: Add "#include <fntl.h>" for O_* constants
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=659750

Reported-by: Salvo Tomaselli <tiposchi@tiscali.it>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-14 10:16:21 +13:00
Jessica McKellar 0deb3ce930 open.2: Fix grammar in O_DIRECT description
Some small grammar fixes to the O_DIRECT description.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-13 10:22:05 +13:00
Michael Kerrisk 2b2e0ce503 mremap.2: spfix
Reported-by: Vijay Rao <vijay@portuosus.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-12 22:53:31 +13:00
Michael Kerrisk c799ca6250 sync.2: PROTOTYPE: Fix return type of syncfs()
Reported-by: Simone Piccardi <piccardi@truelite.it>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-12 06:01:35 +13:00
Michael Kerrisk f49ee36532 vfork.2: CONFORMING TO: Note that POSIX.1-2001 marked vfork() obsolete
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 12:05:46 +13:00
Michael Kerrisk 619c3d1b2d vfork.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 12:05:46 +13:00
Michael Kerrisk c59392ff61 vfork.2: Add some notes on reasons why vfork() still exists
Reported-by: starlight@binnacle.cx
Reported-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 12:05:36 +13:00
Michael Kerrisk ab47b8bc20 vfork.2: Note clone() flags equivalent to vfork()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 10:03:58 +13:00
Michael Kerrisk 60875c0427 vfork.2: Clarify what is duplicated in the child
Add some words to make it clear to the reader that vfork(),
like fork(), creates duplicates of process attributes
in the child.

Reported-by: starlight@binnacle.cx
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 10:00:41 +13:00
Michael Kerrisk 6de06bb89f fork.2: NOTES: Descibe clone() call equivalent to fork()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 09:30:07 +13:00
Michael Kerrisk cf2b18fe6d vfork.2: Clarify that calling *thread* is suspended during vfork()
Reported-by: starlight@binnacle.cx
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-02-08 09:28:06 +13:00
Michael Kerrisk 82d0acff52 mount.2: Removed erroneous statement about MS_RDONLY and bind mounts
Reported-by: Junjiro Okajima <jro@mx3.ttcn.ne.jp>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-01-18 23:23:51 +13:00
Clemens Ladisch 45b4eda6e8 sched_rr_get_interval.2: Update notes on modifying quantum
Since Linux 2.6.24, it is no longer possible to
modify the SCHED_RR quantum using setpriority(2).
(Slight edits to Clemens' patch by mtk.)

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-16 07:01:47 +02:00
Michael Kerrisk 585d38140f sched_rr_get_interval.2: Reworded text of ESRCH error
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-16 06:54:16 +02:00
Michael Kerrisk ca016ea98b sched_rr_get_interval.2: srcfix: Changed in-line formatting to dot directives
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-16 06:50:04 +02:00
Michael Kerrisk 4e2621b57e sched_rr_get_interval.2: Reordered various pieces of text
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-16 06:45:57 +02:00
Michael Kerrisk 7f03801baa recvmmsg.2: srcfix: Added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-05 06:45:34 +02:00
Michael Kerrisk dc43a89191 syscalls.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-05 06:44:40 +02:00
Michael Kerrisk c409c4ffa3 Removed trailing white space at end of lines 2011-10-04 08:34:28 +02:00
Michael Kerrisk 41acdb62c9 Changes, setns.2, stat.2, proc.5, capabilities.7: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 08:32:21 +02:00
Michael Kerrisk 1eee8505ff recvmmsg.2: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 07:58:49 +02:00
Michael Kerrisk 6df3494543 recvmmsg.2: SEE ALSO: add sendmmsg(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 07:55:35 +02:00
Michael Kerrisk 946fb6e2ce recvmmsg.2: Added copyright and license notice
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 07:55:35 +02:00
Michael Kerrisk d92f6e8405 recv.2: Add mention of recvmmsg(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 07:55:35 +02:00
Michael Kerrisk 8b0ea18b39 recvmmsg.2: Various improvements and formatting fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 07:55:35 +02:00
Andi Kleen 242966fd5b recvmmsg.2: New man page for recvmmsg(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-04 07:55:35 +02:00
Michael Kerrisk 9eff286780 mount.2, prctl.2: s/task/thread/ for consistency with other pages
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 15:40:42 +02:00
Michael Kerrisk 5503c85ea4 intro.1, fork.2, futex.2, open.2, rename.2, select_tut.2, semop.2, spu_create.2, stat.2, netlink.3, random.3, scanf.3, shm_open.3, strftime.3, console.4, console_codes.4, sk98lin.4, st.4, bootparam.7, cpuset.7, credentials.7, man-pages.7, path_resolution.7, uri.7: Global fix: remove spaces around em-dash
Normal English typographical convention is not to have
spaces around em dashes.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:47:35 +02:00
Michael Kerrisk 7aa166c58d setns.2: Edited in review comments from Eric Biederman
Reviewed-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Michael Kerrisk 92dcb22063 setns.2: Various improvements
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Michael Kerrisk b93a34b5a2 setns.2: Minor improvements
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Michael Kerrisk 4e1e208d0f setns.2: srcfix: Added FIXMEs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Michael Kerrisk 63b6ef4127 setns.2: Note privileges required
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Michael Kerrisk c07ad242fd setns.2: Minor improvements
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Eric W. Biederman dfa22c8b77 setns.2: New manual page for setns(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:36:41 +02:00
Michael Kerrisk 9c1e33bc99 sigwaitinfo.2: Note that attempts to wait for SIGKILL and SIGSTOP are silently ignored
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 08:14:23 +02:00
Kevin Lyda 8be7707745 rt_sigqueueinfo.2: spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 07:43:42 +02:00
Kevin Lyda 59e754b885 mknodat.2: scrfix: spelling fix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-03 07:41:50 +02:00
Michael Kerrisk 295bb82e56 stat.2: Regarding automounter action, add a reference to fstatat(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-01 07:16:10 +02:00
Michael Kerrisk d3e8b1410a stat.2: Note POSIX.1-2001 and POSIX.1-2008 requirements for lstat()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-01 07:16:10 +02:00
Michael Kerrisk beb0ebc887 stat.2: Clean up text describing which POSIX descibes S_IF* constants
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-01 07:16:10 +02:00
Michael Kerrisk e5ded49fc8 send.2: CONFORMING TO: POSIX.1-2008 adds MSG_NOSIGNAL
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-10-01 07:16:10 +02:00
Michael Kerrisk 280ff2097b stat.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-28 06:27:15 +02:00
Michael Kerrisk ad3fd4c0e3 execve.2, recv.2, getaddrinfo.3, getcwd.3, getipnodebyname.3, getlogin.3, mbsinit.3: Global fix: s/null pointer/NULL pointer/
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-28 06:25:05 +02:00
Michael Kerrisk cebca1bd40 flock.2, recv.2, btree.3, dbopen.3, des_crypt.3, fts.3, mpool.3, recno.3: Global fix: use ORing
Use "ORing", not "OR'ing", nor an italic ".IR OR ing".

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-28 05:06:37 +02:00
Michael Kerrisk 435b60754a capget.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-28 05:05:10 +02:00
Michael Kerrisk 836830b4c9 readlink.2, getsubopt.3, termcap.5, tzfile.5, unix.7: srcfix: change single quote to "\(aq"
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-28 04:56:17 +02:00
Michael Kerrisk 4e83614439 clock_getres.2, clone.2, mbind.2, set_mempolicy.2, atan2.3, getipnodebyname.3, ilogb.3, lgamma.3, elf.5, capabilities.7, math_error.7: srcfix: Remove double space
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-27 05:17:10 +02:00
Guillem Jover 25675bff81 lseek.2: CONFORMING TO: Note other systems that have SEEK_HOLE+SEEK_DATA
Signed-off-by: Guillem Jover <guillem@hadrons.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-25 07:09:58 +02:00
Michael Kerrisk f497e4567d readlink.2: Minor fixes (copyright, example program)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-25 06:54:33 +02:00
David Prévot 4ada4f45a4 lseek.2: wfix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-24 07:54:34 +02:00
Michael Kerrisk 1976f57a63 Removed trailing white space at end of lines 2011-09-23 08:01:18 +02:00
Michael Kerrisk fe48639fc3 set_mempolicy.2, getcwd.3: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-23 07:17:13 +02:00
David Prévot 8c3fb60451 madvise.2: ffix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-23 07:13:09 +02:00
Michael Kerrisk b18e759d8c fstatat.2, rt_sigqueueinfo.2, sendfile.2, hsearch.3, matherr.3, rtld-audit.7: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-23 07:11:27 +02:00
David Prévot 62fc472fa8 posix_fadvise.2: ffix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-23 07:07:58 +02:00
David Prévot fb30b09644 lseek.2, inet_pton.3, tzfile.5: tfix
Please find attach a consistency fix: there were only five
"zeroes" but twenty four "zeros" in those manual pages.
(Make all instances "zeros".)

Signed-off-by: David Prévot <taffit@debian.org>
2011-09-23 07:02:06 +02:00
Michael Kerrisk f7cac3c341 sigqueue.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-22 16:35:41 +02:00
David Prévot c0e140e64c madvise.2: tfix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-22 04:58:20 +02:00
Denis Barbier 928b19706f fallocate.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-22 04:54:53 +02:00
Michael Kerrisk 3d4b49b0a1 madvise.2: Minor fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-21 06:59:45 +02:00
Doug Goldstein e8dd3ed2f1 madvise.2: Add MADV_HUGEPAGE and MADV_NOHUGEPAGE
Document the MADV_HUGEPAGE and MADV_NOHUGEPAGE flags added to
madvise() in Linux 2.6.38.

Signed-off-by: Doug Goldstein <cardoe@cardoe.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-21 06:59:38 +02:00
Michael Kerrisk 7f98857ab9 sched_setscheduler.2: Document 2.6.39 changes to rules governing changes from SCHED_IDLE policy
Since Linux 2.6.39, unprivileged processes under the
SCHED_IDLE policy can switch to another nonrealtime
policy if their nice value falls within the range
permitted by their RLIMIT_NICE limit.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 18:25:40 +02:00
Michael Kerrisk 96f6255496 readlink.2: Added copyright text + changelog note for Guillem Jover's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 08:50:20 +02:00
Michael Kerrisk b61acee948 readlink.2: Minor edits to Guillem Jover's previous patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 08:39:57 +02:00
Guillem Jover f91c6bd76f readlink.2: Document using st_size to allocate the buffer
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 08:19:52 +02:00
Michael Kerrisk 1e0819c860 lseek.2: Document SEEK_HOLE and SEEK_DATA
These flags, designed for discovering holes in a file,
were added in Linux 3.1. Included comments from Eric
Blake and Sunil Mushran.

Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Sunil Mushran <sunil.mushran@oracle.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 08:07:47 +02:00
Michael Kerrisk b9d482436e fstatat.2: AT_NO_AUTOMOUNT has no effect if mount has already occurred
Reported-by: David Howells <dhowells@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 07:05:48 +02:00
Michael Kerrisk cdc839c3ee fstatat.2: Document AT_NO_AUTOMOUNT
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 07:05:48 +02:00
Michael Kerrisk 363f71eb27 sigqueue.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 07:05:48 +02:00
Michael Kerrisk 6b6646e855 clone.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-20 07:05:48 +02:00
David Prévot 5243e7b3b8 ptrace.2: tfix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-19 17:32:54 +02:00
David Prévot 4a7300fe45 mlock.2: tfix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-19 17:32:54 +02:00
David Prévot 26d5d1fd84 sendfile.2: ffix
Signed-off-by: David Prévot <taffit@debian.org>
2011-09-19 17:32:54 +02:00
Michael Kerrisk 45eb0d22b7 fallocate.2: ERRORS: Add EPERM and ESPIPE errors
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-19 17:32:54 +02:00
Michael Kerrisk 710fdd5d6b lseek.2: Remove suspect note about 'whence' being incorrect English.
As noted by Alan Curry:

According to man2/lseek.2,

 This document's use of whence is incorrect English, but
 maintained for historical reasons.

What is the grammatical objection?

From WordNet (r) 3.0 (2006) [wn]:
 whence
     adv 1: from what place, source, or cause

Wiktionary:
 [edit] Adverb
 whence (not comparable)
  1. From where; from which place or source.

lseek's second parameter is a distance to be traveled, and
the third parameter chooses the starting point from which
that distance is measured.  How is that not a "whence"?

Looking at some man page archives, I found that the accusation
of incorrect English goes back to before 4.4BSD. It survives
not just in the linux-man-pages but also in recent versions
of {Net,Open,Free}BSD. The name "whence" for this parameter
goes back at least to V7.

Of all the people who have read this page over the years,
am I the only one wondering... what's this about? Who decided
that "whence" was incorrect and put that note in the man page?
Was there ever anything wrong, or do we have someone's
20-year-old unresearched pet peeve lingering in the man pages?

Reported-by: Alan Curry <pacman@kosh.dhis.org>
Reported-by: Reuben Thomas <rrt@sc3d.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-19 17:32:54 +02:00
Michael Kerrisk 4a19d2ace3 tkill.2: SEE ALSO: Add rt_sigqueueinfo (2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-19 17:32:54 +02:00
Michael Kerrisk 485ab7013e getrlimit.2, kill.2, rt_sigqueueinfo.2, sigaction.2, signal.2, signalfd.2, sigprocmask.2, sigwaitinfo.2, psignal.3, pthread_sigqueue.3, credentials.7, signal.7: Change reference to "sigqueue(2)" to "sigqueue(3)"
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-19 17:32:53 +02:00
Michael Kerrisk 7767750f4b syscalls.2: srcfix: remove unneeded comments
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-19 17:32:53 +02:00
Michael Kerrisk 27b93dae24 sigqueue.2: Create link to page that was relocated to section 3
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-18 06:58:46 +02:00
Michael Kerrisk ae88a0d6b1 sigqueue.3: Move this page to section 3
Now that the underlying system call rt_sigqueueinfo(2) is
properly documented, move sigqueue() to Section 3, since
it is really a library function.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-18 06:58:46 +02:00
Michael Kerrisk b203e4d582 rt_tgsigqueueinfo.2: New link to new rt_sigqueueinfo.2 page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-18 06:58:46 +02:00
Michael Kerrisk 23f438b540 rt_sigqueueinfo.2: New page for rt_sigqueueinfo(2) and rt_tgsigqueueinfo(2)
This replaces the previous '.so' man page link file for
rt_sigqueueinfo.2, which linked to ths sigqueue() man page.

Reported-by: Stephan Mueller <stephan.mueller@atsec.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-18 06:58:33 +02:00
Michael Kerrisk d0e1cbceeb syscalls.2: Minor: remove duplicated open_by_handle() entry
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-17 07:11:02 +02:00
Paul Pluzhnikov cadcf1b16b prctl.2: PR_SET_DUMPABLE makes process non-ptrace-attachable
We've recently discovered that GDB will fail to attach to any
process that sets itself non-dumpable. Tested on kernel 2.6.32,
with:

int main(int argc, char *argv[])
{
    if (prctl(PR_SET_DUMPABLE, 0, 0, 0) != 0) {
        perror("prctl");
    }
    printf("Run gdb %s %d\n", argv[0], getpid());
    sleep(20);
    abort();
}

./a.out
Run gdb ./a.out 30476

gdb -q  ./a.out 30476
Reading symbols from /tmp/a.out...done.
Attaching to program: /tmp/a.out, process 30476
ptrace: Operation not permitted.
/tmp/30476: No such file or directory.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-17 06:10:54 +02:00
Paul Pluzhnikov 2e781e2082 prctl.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-17 06:08:35 +02:00
Michael Kerrisk 1ad008e71e Removed trailing white space at end of lines 2011-09-17 05:45:55 +02:00
Michael Kerrisk 1293f354e2 sendfile.2: wfix
Reported-by: Stefan Puiu <stefan.puiu@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-17 05:16:43 +02:00
Michael Kerrisk f81c6cc693 fcntl.2, recv.2, crypt.3, err.3, strtoul.3, proc.5: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:02:06 +02:00
Hendrik Jan Thomassen 3d5be2aa85 unlink.2: Improve EBUSY description
The current version of the page says (under ERRORS):

> EBUSY (not on Linux)
>  The  file pathname cannot be unlinked because it is being
>  used by the system or another process and the
>  implementation considers this an error.

But if you look in the kernel source file fs/namei.c
at routine may_delete() you'll see two occasions where
an EBUSY is generated. So the above "not on Linux" is wrong.

I suggest that this '(not on Linux)' be removed. It may
also improve the page if the commentary is reworded to give a
better description of the two situations. Something along
the lines of:
> The file pathname cannot be unlinked because it is being used
> by the system, e.g. if some (relative) rootdir is mounted upon it,
> or because the NFS client software created it to represent an
> active but otherwise nameless inode ("NFS silly renamed").

Just FYI: the NFS silly rename (you'll find this term mentioned
in the kernel source code) is described at:
       http://nfs.sourceforge.net/#section_d
under section D2. The reason I found this manpage bug is because
I stumbled upon one of these silly renamed files, and an strace
of the rm-command revealed the EBUSY return errno.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk 12e263f178 open.2: wfix
Reported-by: Graham Gower <graham.gower@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Tomislav Jonjic 612144c541 timerfd_create.2: Fix small error in description of timerfd_settime()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk 963da6c54d mlock.2: Clarify EINVAL error
See http://bugs.debian.org/cgi-bin/bugreport.cgi?625747

Reported-by: Brian M. Carlson <sandals@crustytoothpaste.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Simon Paillard 3cbd3fee32 get_mempolicy.2: spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk 1e8a0addef execve.2: Note that the first argv[] value should contain name of executable
Reported-by: Sebastian Geiger <sbastig@gmx.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Tolga Dalman 866ed7369f sendfile.2: Add an explicit reference to splice(2)
Unlike sendfile(), splice() can transfer data
between a pair of sockets.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk 009cdc2239 timerfd_create.2: Note behavior when timerdfd_settime() old_value is NULL
See http://bugs.debian.org/cgi-bin/bugreport.cgi?641513
timerfd_settime(2) states that "The old_value argument returns a
structure containing the setting of the timer that was current at
the time of the call"; however, it does not mention that the
caller can pass NULL to ignore that value.  Only the example
shows that the caller can pass NULL.

Reported-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk bb0fed2e8a sendfile.2: Shift text on falling back to read()/write() to NOTES
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk c8a58c6aa0 sendfile.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Akira Fujita fe0ed23f6f sendfile.2: Since 2.6.33, 'out_fd' can refer to any file type
Linux kernel commit cc56f7de7f00d188c7c4da1e9861581853b9e92f
meant sendfile(2) can work with any output file.
Therefore the 'out_fd' of sendfile(2) can refer to any file
(since Linux 2.6.33).

Signed-off-by: Akira Fujita <a-fujita@rs.jp.nec.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00
Michael Kerrisk c39f51b0f2 syscalls.2: Update to mention 3.x kernel series
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2011-09-16 07:00:48 +02:00