Commit Graph

3080 Commits

Author SHA1 Message Date
Michael Kerrisk f2d587e6a1 getitimer.2: Fix types used to declare fields in timeval struct
Reported-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-30 07:40:52 +02:00
David Prévot 8f172c56b2 quotactl.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-28 08:04:03 +02:00
Michael Kerrisk ca8a0bd25b sched_get_priority_max.2, sched_setparam.2, sched_setaffinity.2, sched_setscheduler.2, timer_create.2, malloc.3, pthread_attr_init.3, pthread_attr_setinheritsched.3, pthread_attr_setschedparam.3, pthread_attr_setschedpolicy.3, pthread_attr_setscope.3, pthread_attr_setstack.3, pthread_getattr_np.3, pthread_cancel.3, pthread_create.3, pthread_setschedparam.3, pthread_setschedprio.3, aio.7, time.7: Global ffix: disable justification and hyphenation in SEE ALSO
For a better visual result, disable justification and hyphenation
in SEE ALSO where page names are long.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-25 06:39:39 +02:00
Michael Kerrisk e264f02416 keyctl.2: ffix: prevent hyphenation and justification under SEE ALSO
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-25 06:05:33 +02:00
David Prévot cf4d436127 keyctl.2: Reorder SEE ALSO, without .br
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-25 06:00:07 +02:00
Michael Kerrisk 6c1544c132 syscalls.2, uname.2, boot.7: Global fix: s/OS/operating system/
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-24 10:05:20 +02:00
Michael Kerrisk 66a9882e46 bdflush.2, get_robust_list.2, kexec_load.2, madvise.2, mmap.2, mount.2, prctl.2, query_module.2, rt_sigqueueinfo.2, shmget.2, sigaction.2, syscalls.2, umount.2, malloc.3, hpsa.4, initrd.4, proc.5, bootparam.7, icmp.7, netlink.7, signal.7: Global fix: use "Linux kernel source" consistently
Rather than "kernel source".

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-24 10:02:34 +02:00
David Prévot 173fe7e792 arch_prctl.2, fcntl.2, flock.2, get_robust_list.2, getpriority.2, ioprio_set.2, migrate_pages.2, mmap.2, mremap.2, msync.2, sched_get_priority_max.2, sched_rr_get_interval.2, sched_setparam.2, sched_setscheduler.2, sched_yield.2, select.2, socket.2, subpage_prot.2, unshare.2, btree.3, dbopen.3, dl_iterate_phdr.3, dlopen.3, getnameinfo.3, hash.3, lockf.3, netlink.3, recno.3, rpc.3, xdr.3, cciss.4, console_ioctl.4, hpsa.4, initrd.4, msr.4, rtc.4, st.4, hosts.5, services.5, tzfile.5, aio.7, arp.7, capabilities.7, cpuset.7, feature_test_macros.7, futex.7, inotify.7, ip.7, ipv6.7, iso_8859-16.7, iso_8859-2.7, koi8-r.7, math_error.7, netlink.7, packet.7, pthreads.7, raw.7, spufs.7, udplite.7, uri.7, x25.7: Global fix: Various consistency fixes for SEE ALSO
Coauthored-by: Michael Kerrisk <mtk.manpages@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-24 09:53:22 +02:00
Guillem Jover 318c814291 stat.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-24 07:15:36 +02:00
David Prévot f06f501401 syscalls.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-24 07:15:03 +02:00
Adrian Bunk 85d301e129 wait4.2: Note that these functions are nonstandard and recommend alternatives
Some edits to Adrian's path by mtk.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-24 07:15:03 +02:00
Michael Kerrisk 0ac42204d0 wait4.2: CONFORMING TO: Note SUS details for wait3()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-23 15:50:58 +02:00
Michael Kerrisk a38a23a17f sigaction.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-23 06:49:47 +02:00
Michael Kerrisk ca15be9183 sigaction.2: Tweak SA_RESETHAND description
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-23 06:49:47 +02:00
Michael Kerrisk 556bb77a36 shutdown.2: Document EINVAL error (and associated bug)
Eric Dumazet noted that EINVAL was not documented. Some further
digging shows that it's also not diagnosed consistently.
See https://bugzilla.kernel.org/show_bug.cgi?id=47111.

Reported-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-06 11:42:51 +02:00
Michael Kerrisk 72da9ef157 ldd.1, execve.2, getdents.2, quotactl.2, select_tut.2, clock_getcpuclockid.3, fopencookie.3, getservent_r.3, matherr.3, mq_notify.3, pthread_create.3, pthread_getattr_np.3, wordexp.3: Global fix: s/-/\\-/ when real hyphen is required (e.g., in code)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-29 12:14:08 +02:00
Michael Kerrisk 352c778d01 semop.2: Recast discussion of blocking behavior in terms of threads
semop() blocks the calling thread, not the process.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-27 12:59:11 +02:00
Michael Kerrisk 77ba6370c2 semop.2: Minor rewording
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-27 12:45:23 +02:00
Michael Kerrisk f81b78a4ca semop.2: SEE ALSO: Add clone(2)
Give reader a clue about CLONE_SYSVSEM.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-27 12:43:52 +02:00
Michael Kerrisk 2e72e99169 select.2: Clarify equivalent pslect() code in terms of threads
s/sigprogmask/pthread_sigmask/

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-22 15:29:04 +02:00
Michael Kerrisk 5adf628119 clock_nanosleep.2: wfix: s/SA_SIGACTION/SA_RESTART/
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-22 15:28:19 +02:00
Michael Kerrisk 67378c4842 epoll_wait.2: Add pointer to select(2) for discussion of close in another thread
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-17 08:41:35 +02:00
Michael Kerrisk f33050d604 poll.2: Add pointer to select(2) for discussion of close in another thread
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-17 08:36:48 +02:00
Michael Kerrisk 10ed041e56 select.2: Note behavior if monitored file descriptor is closed in another thread
Executive summary: a sane application can't rely on any
particular behavior if another thread closes a file descriptor
being monitored by select().

See https://bugzilla.kernel.org/show_bug.cgi?id=40852

Reported-by: Stephane Fillod <fillods@users.sf.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-17 08:36:48 +02:00
Michael Kerrisk 8c1d94ae86 select.2: Minor wording fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-17 08:36:48 +02:00
Michael Kerrisk 355f61b5bc epoll_wait.2: Describe timeout limitation in kernels < 2.6.37
As reported by Fredrik (and as far as I can tell the problem
went back to 2.6.0):

The timeout argument has an upper limit. Any values above that
limit are treated the same as -1, i.e. to wait indefinitely.
The limit is given by:

    #define EP_MAX_MSTIMEO min(1000ULL * MAX_SCHEDULE_TIMEOUT / HZ, \
	(LONG_MAX - 999ULL) / HZ)

That is, the limit depends on the size of a long and the timer
frequency.  Assuming the a long is never smaller than 32 bits
and HZ never larger than 1000, the worst case is 35 minutes.
I think this should be mentioned under "BUGS".

Although this is likely to be fixed in the future
(http://lkml.org/lkml/2010/8/8/144), the problem exists in
at least 2.6.14 - 2.6.35. I don't know if select(2) and poll(2)
are affected.

https://bugzilla.kernel.org/show_bug.cgi?id=20762

Reported-by: Fredrik Arnerup <arnerup@kth.se>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-17 08:36:28 +02:00
Michael Kerrisk 11c85ed875 Removed trailing white space at end of lines 2012-08-14 00:39:21 +02:00
Michael Kerrisk bf42aad4a7 mprotect.2, syscall.2, realpath.3, iso_8859-1.7: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-14 00:37:33 +02:00
Michael Kerrisk 4832b48ab0 futex.2: Fix description of EINVAL error
The current text seems incorrect. Replace with a more general
description.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-14 00:10:36 +02:00
Michael Kerrisk e808bba0ff futex.2: Various wording fix-ups
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-13 14:50:26 +02:00
Марк Коренберг 9f6c40c0e6 futex.2: Consolidate error descriptions to ERRORS
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-13 14:25:13 +02:00
Michael Kerrisk a2f11be3c1 mprotect.2: 'addr' argument is not const
As reported by Rasmus:

    Both my system's man-pages (3.22) and the latest online
    (3.41) show:

        int mprotect(const void *addr, size_t len, int prot);

    as the prototype for mprotect(2). However, POSIX [1] and the
    actual sys/mman.h (on all the systems I checked) do not have
    the const qualifier on the first argument.

Reported-by: Rasmus Villemoes <Rasmus.Villemoes@decode.is>

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-13 14:00:29 +02:00
Sami Kerola 608bf95023 capget.2, futex.2, sched_setscheduler.2, spu_create.2, spu_run.2, vfork.2, getnameinfo.3, netlink.3, cciss.4, console_codes.4, dsp56k.4, hpsa.4, sk98lin.4, filesystems.5, protocols.5, aio.7, capabilities.7, charsets.7, feature_test_macros.7, futex.7, hier.7, iso_8859-16.7, iso_8859-2.7, koi8-r.7, libc.7, man.7, netlink.7, numa.7, standards.7, unicode.7, units.7, uri.7, x25.7: Global fix: use UR macro where applicable
The syntax .UR http://example.com paired with .UE will create
links which one can interact, if the pager allows that.  One
way to see the effect is ask the man(1) command to use browser
display, e.g.:

    man -H man7/uri.7

("\:" is optional groff syntax to permit hyphenless line breaks.)

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-13 10:02:36 +02:00
Michael Kerrisk 6edb20bcd8 migrate_pages.2: spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-13 09:26:21 +02:00
David Prévot b0b1d9b517 ptrace.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-13 09:22:34 +02:00
Michael Kerrisk 13f78d96ad getdents.2, select_tut.2, atof.3, atoi.3, pthread_create.3, pthread_sigmask.3, rtime.3, setbuf.3, tsearch.3, netlink.7: Remove unneeded casts
Reported-by: Jan Engelhardt <jengelh@medozas.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Denys Vlasenko ca302d0ee3 ptrace.2: Explain WNOHANG behavior and EINTR bug
I didn't like ithe "SIGKILL operates similarly, with exceptions"
phrase (if it's different, then it's not "similar", right?),
and now I got around to changing it. Now it says simply:
"SIGKILL does not generate signal-delivery-stop and therefore
the tracer can't suppress it."

Replaced "why WNOHANG is not reliable" example with a more
realistic one (the one which actually inspired to add this
information to man page in the first place): we got
ESRCH - process is gone! - but waitpid(WNOHANG) can still
confusingly return 0 "no processes to wait for".

Replaced "This means that unneeded trailing arguments may
be omitted" part with a much better recommendation
to never do that and to supply zero arguments instead.
(The part about "undocumentedness" of gcc behavior was bogus,
btw - deleted).

Expanded BUGS section with the explanation and an example
of visible strace behavior on the buggy syscalls which
exit with EINTR on ptrace attach. I hope this will lead
to people submitting better bug reports to lkml about
such syscalls.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Michael Kerrisk 65cee725a9 adjtimex.2: srcfix: added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Michael Kerrisk cb72917199 ptrace.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Michael Kerrisk 41a65f128c migrate_pages.2: Fix description of return value
Reported-by: Christoph Lameter <cl@linux.com>
Reported-by: JoonSoo Kim <js1304@gmail.com>

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Akihiro MOTOKI 1f1fd5eff5 socket.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Akihiro MOTOKI 982ff543cd inotify_init.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Michael Kerrisk 82fdd7c7d0 ioprio_set.2: Document who==0 for IOPRIO_WHO_PROCESS and IOPRIO_WHO_PGRP
For IOPRIO_WHO_PROCESS, who==0 means operate on the caller.
For IOPRIO_WHO_PGRP, who==0 means operate on the caller's
process group.

See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=652443

Reported-by: Марк Коренберг <socketpair@gmail.com>
Reported-by: Kalle Olavi Niemitalo <kon@iki.fi>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Michael Kerrisk c4949ba488 ioprio_set.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Colin McCabe b91e4e72eb ioprio_set.2: Clarify the multithreaded behavior of ioprio_set(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-08-03 10:33:49 +02:00
Michael Kerrisk bf1298c9e5 sigwaitinfo.2: Some wording clarifications
Mainly rewording things like "is delivered" to "becomes pending",
which is more accurate terminology.

Reported-by: Daniel Zingaro <daniel.zingaro@utoronto.ca>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-21 05:52:22 +02:00
Michael Kerrisk 4e9ee22571 set_tid_address.2: Some rewordings and minor clarifications
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-21 05:09:45 +02:00
Michael Kerrisk 72442c6803 set_tid_address.2: Some minor rewordings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-21 05:01:37 +02:00
Michael Kerrisk 568c4c02b7 set_tid_address.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-21 04:55:31 +02:00
Michael Kerrisk f5fe595295 set_tid_address.2: Rename 'ctid' argument for consistency with clone(2) page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-20 17:17:06 +02:00
Michael Kerrisk 5add3af3d8 clone.2: Rewrite discussion of sys_clone
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-20 17:17:06 +02:00
Michael Kerrisk 98309d3fea syscalls.2: Move discussion of set_zone_reclaim(2) out of main table
This system call was never visible to user space, so it makes
sense to move it out of the main table of system calls into
the notes below the table.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:28 +02:00
Michael Kerrisk 8eec4a2373 syscalls.2: Add kcmp(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:28 +02:00
Michael Kerrisk 45c99e3ec4 get_robust_list.2, get_thread_area.2, getcpu.2, getdents.2, gettid.2, io_cancel.2, io_destroy.2, io_getevents.2, io_setup.2, io_submit.2, ioprio_set.2, kexec_load.2, llseek.2, modify_ldt.2, mq_getsetattr.2, pivot_root.2, readdir.2, rt_sigqueueinfo.2, set_thread_area.2, sgetmask.2, spu_create.2, spu_run.2, subpage_prot.2, sysctl.2, tkill.2: Add note to SYNOPSIS that there is no glibc wrapper for system call
Reduce the chance that the reader may be misled into thinking
that there is a wrapper function for this system call by noting
explicitly in the SYNOPSIS that there is no glibc wrapper and
pointing the reader to NOTES for further details.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:28 +02:00
Michael Kerrisk 498a96a239 syscall.2: Add some more details to the description of syscall(2)
And add another example of using syscall() to the program example.

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

syscall.2: fix

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:28 +02:00
Michael Kerrisk 50cebc0485 kexec_load.2: tfix
Reported-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:28 +02:00
Michael Kerrisk 38c6b6401d path_resolution.2, epoll.4, fifo.4, futex.4, complex.5, environ.5: Remove outdated links
Remove links >= 5 years old that were created after historical
moves of pages to new sections.

Reported-by: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:28 +02:00
Michael Kerrisk 44535dd29b mount.2: For MS_REMOUNT, source is ignored
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-07-19 12:51:27 +02:00
Michael Kerrisk f658081708 seteuid.2: Note glibc version where setegid() implementation changed
In glibc 2.2/2.3, setegid() switched from setregid() to setresgid().
2012-07-19 12:51:27 +02:00
Michael Kerrisk 6fdbc7794f access.2, prctl.2, recv.2, send.2, euidaccess.3, mbstowcs.3, mcheck.3: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-06-08 03:10:26 +12:00
Akihiro MOTOKI 02ace852fb open.2, select.2, aio_cancel.3, aio_suspend.3: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-06-08 03:10:25 +12:00
Akihiro MOTOKI a59e64bef2 spfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-06-08 03:10:25 +12:00
Michael Kerrisk f66524636d msgctl.2, msgget.2, msgop.2, semctl.2, semget.2, semop.2, shmctl.2, shmget.2: NOTES: <sys/types.h> and <sys/ipc.h> aren't strictly needed
Add text to NOTES to say that the <sys/types.h> and <sys/ipc.h>
header files aren't required by Linux or the standards, but may
be needed for portability to old systems.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-06-08 03:10:25 +12:00
Michael Kerrisk 548be2a60e msgctl.2, semctl.2, shmctl.2, svipc.7: Don't mention that ipc_perm is defined in <sys/ipc.h>
There's no need to mention that the 'ipc_perm' structure
is defined in <sys/ipc.h>. That's an implementation detail,
and furthermore <sys/ipc.h> is itself included by the other
System V IPC header files. The current text might lead the
reader to conclude that they must include <sys/ipc.h>, which
is not the case (it is required neither on Linux, nor by the
standards).

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-06-08 03:10:25 +12:00
Michael Kerrisk 96668cfdbb keyctl.2: srcfix: Added FIXMEs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-06-08 03:10:25 +12:00
Michael Kerrisk 0ab8aeecc5 Removed trailing white space at end of lines 2012-05-11 08:13:04 +12:00
Michael Kerrisk dbd577f885 get_robust_list.2: tstamp fix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-11 08:11:32 +12:00
Michael Kerrisk e5080839ee semop.2: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-11 08:10:50 +12:00
Michael Kerrisk eae2dfceab futimesat.2, mount.2, confstr.3, iconv.3, makedev.3, malloc.3, strcasecmp.3, strcat.3, strcmp.3, strcpy.3, strdup.3, strftime.3, strnlen.3, strpbrk.3, strspn.3, strtok.3, strxfrm.3, sk98lin.4, icmp.7, ipv6.7, packet.7, raw.7, rtnetlink.7, unix.7, x25.7, ldconfig.8, nscd.8: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-11 08:09:28 +12:00
David Prévot 01d8b73f92 poll.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-10 18:07:47 +12:00
Michael Kerrisk e1c5ebfa25 io_cancel.2, io_destroy.2, io_getevents.2, io_setup.2, io_submit.2: Rewrite to focus on system call API
Rewrite to focus on the system call interface, adding
some notes on the libaio wrapper differences.
See the following mail:
2012-05-07 "aio manuals", linux-man@vger.kernel.org
http://thread.gmane.org/gmane.linux.man/1935/focus=2910

Other minor rewrites.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-10 11:57:03 +12:00
Michael Kerrisk dd3ec6febb io_cancel.2, io_destroy.2, io_getevents.2, io_setup.2, io_submit.2: srcfix: remove old commented-out formatting directives
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-10 11:57:03 +12:00
Nick Piggin 1847167b8b open.2: Describe race of direct I/O and fork()
Rework 04cd7f64, which didn't capture the details correctly.
See the April/May 2012 linux-man@ mail thread "[PATCH]
Describe race of direct read and fork for unaligned buffers"
http://thread.gmane.org/gmane.linux.kernel.mm/77571

Acked-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cowritten-by: Jan Kara <jack@suse.cz>
Cowritten-by: Hugh Dickins <hughd@google.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-09 19:18:43 +12:00
David Prévot 99eccaa774 get_robust_list.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-09 17:18:07 +12:00
Michael Kerrisk ded312a306 getcpu.2: DESCRIPTION: reword a sentence to be clearer
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-09 17:18:07 +12:00
Michael Kerrisk 6ca014574b getcpu.2: Refer reader to NOTES for more info about 'tcache'
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-09 17:18:07 +12:00
Mike Frysinger 178df36f74 getcpu.2: Add RETURN VALUE and ERRORS sections
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-09 17:11:37 +12:00
D. Barbier 5d2f567434 symlinkat.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-08 22:37:34 +12:00
D. Barbier 8065732760 inotify_init.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-08 22:37:01 +12:00
David Prévot 65a0c0120f clock_getres.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-08 09:20:22 +12:00
Bjarni Ingi Gislason e53eca7462 ioctl_list.2: ffix
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=671514

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:19 +12:00
Bjarni Ingi Gislason 0ce81ab564 ptrace.2: srcfix to avoid groff warning
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:19 +12:00
Bjarni Ingi Gislason 56f2caff29 syscalls.2: Formatting fixes
From "groff -ww ..." (or "man --warnings=w ..."):

    warning: around line 157: table wider than line width

Have to use text blocks.  Move some text to its correct column.
Split text to two columns to avoid hyphenation.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:18 +12:00
Bjarni Ingi Gislason 77b9991851 stat.2: Formatting fixes
From "groff -ww" (or "man --warnings=w ..."):

    warning: around line 442: table wider than line width

GNU man uses line length of 78.

Use text blocks.  Two spaces between sentences or better: start
each sentence in a new line.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:18 +12:00
Michael Kerrisk 4a037a4a01 socket.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:18 +12:00
Michael Kerrisk 3e18f289e7 ptrace.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:18 +12:00
Michael Kerrisk a3492501ff prctl.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:18 +12:00
Michael Kerrisk 4208a89631 mount.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk f6253e6182 madvise.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk 078a7d6e3a _exit.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk 61e1aee047 mount.2, dbopen.3, fenv.3: grfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk 2dd7f4cbe3 accept.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Simon Paillard b3682895f8 clock_getres.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk 4175f99924 add_key.2, query_module.2, request_key.2, resolver.3, stpcpy.3, strftime.3, elf.5, proc.5, mdoc.samples.7: srcfix: Wrap source lines at sentence boundaries
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk f61d734d64 madvise.2: grfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk e9dedcd212 madvise.2: grfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:17 +12:00
Michael Kerrisk a1402e4c93 syslog.2: Remove some details about obsolete Linux libc
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk 8a2384a440 sysinfo.2: Remove reference to obsolete libc5
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk 2606a2b068 signal.2: Note that 'sig_t' requires _BSD_SOURCE
Also remove some old Linux libc details

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk 6f0b2c8c9a poll.2: Clarify discussion of wrapper function emulation
Clarify that glibc (as well as old libc) provides emulation
using select(2) on older kernels that don't have a poll()
system call.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk 77a53cb65a mount.2: Comment out an old Linux libc detail
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk 1941c8e763 execve.2: Rewording to deemphasize libc5 details
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk 7bf5c019f1 execve.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk c95b6ae1ce faccessat.2, fchmodat.2, fchownat.2, fstatat.2, futimesat.2, inotify_init.2, linkat.2, mkdirat.2, mknodat.2, openat.2, readlinkat.2, renameat.2, setns.2, splice.2, symlinkat.2, sync.2, tee.2, unlinkat.2, vmsplice.2: Global fix: note glibc version that added library support
Reported-by: Lauri Kasanen <curaga@operamail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:16 +12:00
Michael Kerrisk ce50b4c311 get_robust_list.2: Various edits and additions
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:15 +12:00
Michael Kerrisk 8a9b4d2030 set_robust_list.2: New link to new get_robust_list.2 page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:15 +12:00
Ivana Varekova 1f62bc9ecd get_robust_list.2: New page documenting get_robust_list(2) and set_robust_list(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:15 +12:00
David Prévot 244195afe4 fchmodat.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:15 +12:00
Michael Kerrisk 9d0637e513 select.2: Expand description of the self-pipe trick
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk b8b850053f select.2: grfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk a16eec1e9c select.2: Add further details on pselect6() system call that underlies pselect()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 736552001d semop.2: Clarify that 'timeout' of semtimedop() is a *minimum* interval
Make it clear that 'timeout' interval will be rounded up to the
system clock granularity, and may overrun because of kernel
scheduling delays.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 3a1876bd71 recvmmsg.2: Clarify that 'timeout' is a *minimum* interval
Make it clear that 'timeout' interval will be rounded up to the
system clock granularity, and may overrun because of kernel
scheduling delays.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 95b803548b sigwaitinfo.2: Clarify that 'timeout' of sigtimedwait() is a *minimum* interval
Make it clear that 'timeout' is a minimum interval; the actual
interval will be rounded up to the system clock granularity,
and may overrun because of kernel scheduling delays.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 77e74cf141 poll.2: Make the meaning of a zero timeout explicit
Clarify that timeout==0 causes an immediate return, even if
no file descriptors are ready.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 19257d8fe6 poll.2: Clarify that 'timeout' is a *minimum* interval
Make it clear that 'timeout' is a minimum interval; the actual
interval will be rounded up to the system clock granularity,
and may overrun because of kernel scheduling delays.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk f07cd91a9e epoll_wait.2: Clarify that 'timeout' is a *minimum* interval
Make it clear that 'timeout' is a minimum interval; the actual
interval will be rounded up to the system clock granularity,
and may overrun because of kernel scheduling delays.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 8c121f4004 select.2: Clarify that 'timeout' is a *minimum* interval
Make it clear that 'timeout' is a minimum interval; the actual
interval will be rounded up to the system clock granularity,
and may overrun because of kernel scheduling delays.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Mike Frysinger aed1f3b9fb fork.2: ERRORS: add ENOSYS
Can occur on, for example, non-MMU hardware.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Jan Kara 04cd7f643d open.2: Describe race of direct read and fork() for unaligned buffers
This is a long standing problem (or a surprising feature) in our
implementation of get_user_pages() (used by direct IO). Since
several attempts to fix it failed (e.g.,
http://linux.derkeiler.com/Mailing-Lists/Kernel/2009-04/msg06542.html,
or http://lkml.indiana.edu/hypermail/linux/kernel/0903.1/01498.html
refused in http://comments.gmane.org/gmane.linux.kernel.mm/31569)
and it's not completely clear whether we really want to fix
it given the costs. Let's at least document it.

Signed-off-by: Jan Kara <jack@suse.cz>
Acked-by: Jeff Moyer <jmoyer@redhat.com>
Acked-by: Mel Gorman <mgorman@suse.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Yuri Kozlov 9a830e6211 prctl.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 8d8eb2f0c8 epoll_wait.2: Minor wording clarification to EINTR error
Try to avoid the type of misreading reported in
https://bugs.launchpad.net/ubuntu/+source/manpages/+bug/480566

Reported-by: Angelo Borsotti <angelo.borsotti@gmail.com >
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:14 +12:00
Michael Kerrisk 22594a3cb6 clock_getres.2: Expand description of CLOCK_REALTIME
Make it clear that this clock may be discontinuous, and is
affected my incremental NTP and clock-adjtime(2) adjustments.

See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=540872

Reported-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:13 +12:00
Michael Kerrisk c3ee1c5d6a pread.2: BUGS: Note O_APPEND + pwrite() does the wrong thing
See https://bugzilla.kernel.org/show_bug.cgi?id=43178

Reported-by: Kasper Dupont <kasperd@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:13 +12:00
Jason Baron c639b31479 madvise.2: Document MADV_DONTDUMP and MADV_DODUMP
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-07 15:30:13 +12:00
Michael Kerrisk 3960d7a208 Removed trailing white space at end of lines 2012-04-27 10:58:21 +12:00
Michael Kerrisk af75eecea0 process_vm_writev.2: Correct target of link
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-27 10:57:58 +12:00
Michael Kerrisk 04b2e45352 process_vm_readv.2: Further improvements after Mike Frysinger's comments
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:13:00 +12:00
Michael Kerrisk 0b01869b0a process_vm_readv.2: Cleanups after comments from Mike Frysinger and Christopher Yeoh
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:13:00 +12:00
Michael Kerrisk 7985dbf3f7 process_vm_readv.2: Many additions, rewrites, and clarifications
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:13:00 +12:00
Michael Kerrisk 9762bc8a64 process_vm_readv.2: Minor tweaks to example code
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:59 +12:00
Michael Kerrisk 529b74009b process_vm_readv.2: Formatting fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:59 +12:00
Mike Frysinger 5e5ab35394 process_vm_writev.2: Link to new process_vm_readv(2) page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:59 +12:00
Mike Frysinger 0b0ec7588c process_vm_readv.2: New page for process_vm_readv(2) and process_vm_writev(2)
Cowritten-by: Christopher Yeoh <cyeoh@au1.ibm.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:59 +12:00
Michael Kerrisk 82232e78e9 gettimeofday.2, ptrace.2, sigaction.2, aio_init.3, mpool.3, scandir.3, inotify.7, netdevice.7: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:59 +12:00
Michael Kerrisk 63f0f3d9b8 clock_getres.2: Clarify difference between CLOCK_MONOTONIC and CLOCK_MONOTONIC_RAW
Note interactions of these two clocks with discontinuous
adjustments to the system time and NTP/adjtime(2).

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:59 +12:00
Michael Kerrisk 5f04b9486b gettimeofday.2: gettimeofday() is affected by discontinuous jumps in the system time
Advise reader to use clock_gettime(2), if they need a
monotonically increasing time source.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:10 +12:00
Michael Kerrisk fb6fc61227 gettimeofday.2: SEE ALSO: Add clock_gettime(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:06 +12:00
Michael Kerrisk bc02b3ea72 prctl.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:06 +12:00
Michael Kerrisk 06afe6739c prctl.2: Add PR_TASK_PERF_EVENTS_DISABLE and PR_TASK_PERF_EVENTS_ENABLE
Add some basic documentation of these operations, with a pointer to
tools/perf/design.txt for more information.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-04-26 09:12:06 +12:00
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