Commit Graph

13795 Commits

Author SHA1 Message Date
Michael Kerrisk d99408f7a8 Ready for 4.00 2015-05-07 08:30:35 +02:00
Michael Kerrisk 5ffdc2fda9 Removed trailing white space at end of lines 2015-05-07 08:30:26 +02:00
Michael Kerrisk ac279f7638 Changes: Expanded tabs 2015-05-07 08:30:26 +02:00
Michael Kerrisk 721aebf904 loop.4: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-07 08:29:45 +02:00
Michael Kerrisk 3bc8a843fd loop.4: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-07 08:29:01 +02:00
Michael Kerrisk 877e13e9f8 xattr.7: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-07 08:28:31 +02:00
Michael Kerrisk 67d2c6873c add_key.2, chown.2, epoll_ctl.2, epoll_wait.2, execve.2, fcntl.2, get_mempolicy.2, getxattr.2, ioctl.2, keyctl.2, listxattr.2, mkdir.2, mknod.2, mmap.2, msync.2, nfsservctl.2, open.2, prctl.2, removexattr.2, request_key.2, sendfile.2, set_mempolicy.2, setxattr.2, shmget.2, shutdown.2, sigaction.2, syslog.2, truncate.2, umask.2, CPU_SET.3, atexit.3, bsearch.3, cmsg.3, err.3, gethostid.3, getmntent.3, getopt.3, iconv_close.3, inet_ntop.3, longjmp.3, lsearch.3, mcheck.3, on_exit.3, putpwent.3, regex.3, resolver.3, setbuf.3, setjmp.3, setlocale.3, setlogmask.3, sleep.3, strsignal.3, sysconf.3, undocumented.3, tty_ioctl.4, proc.5, resolv.conf.5, tzfile.5, aio.7, bootparam.7, capabilities.7, fanotify.7, inotify.7, ip.7, packet.7, pthreads.7, raw.7, signal.7, socket.7, unix.7, ld.so.8, nscd.8: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-07 08:26:32 +02:00
Michael Kerrisk 3f3b5c75cb xattr.7: srcfix: Add license tags
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-07 08:10:31 +02:00
Michael Kerrisk 6645170273 Changes: Ready for 4.00
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 21:51:37 +02:00
Michael Kerrisk 80e1913a68 Changes.old: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 21:09:07 +02:00
Brice Goglin 856778162b get_mempolicy.2, set_mempolicy: Policy is per thread, not per process
set/get_mempolicy manpages say that the memory allocation
policy is per process while reading the code and testing shows
that it's actually per thread.  Here's a quick fix, which may
need to be improved to better explain that we're allocating
in the context of a thread within a process address space.

Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 20:37:34 +02:00
Regid Ichira e23f2a23cd gai.conf.5: Minor wording fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 18:36:19 +02:00
Michael Kerrisk 320f8a8ec9 open.2: BUGS: O_CREAT | O_DIRECTORY succeeds if pathname does not exist
See http://www.openwall.com/lists/oss-security/2014/11/26/10
and http://thread.gmane.org/gmane.linux.file-systems/90997
    Subject: O_CREAT|O_DIRECTORY on nonexisting file with ext4
             not posix-compliant
    Newsgroups: gmane.linux.file-systems
    Date: 2014-12-15 17:39:09 GMT
and https://lkml.org/lkml/2005/9/23/80
    Subject: [PATCH] open: O_DIRECTORY and O_CREAT together should fail
    From:    Miklos Szeredi <>
    Date:    Fri, 23 Sep 2005 16:45:04 +0200

Reported-by: NeilBrown <neilb@suse.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 18:31:49 +02:00
Michael Kerrisk 70b53bc047 stat.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 17:58:39 +02:00
Michael Kerrisk 97d5b76276 open.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 17:57:32 +02:00
Michael Kerrisk 6ca52c17a9 shmget.2: Document SHM_HUGE_2MB, SHM_HUGE_1GB, and SHM_HUGE_SHIFT
Reported-by: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 17:41:21 +02:00
Michael Kerrisk 5d2038b6a8 mmap.2: Document MAP_HUGE_2MB, MAP_HUGE_1GB, and MAP_HUGE_SHIFT
Reported-by: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 17:41:21 +02:00
Michael Kerrisk 651b8a8257 ip.7: Relocate misplaced text describing ENOPROTOOPT error
Long ago, some page reworking moved this text to a somewhat
random location in the middle of the socket options list.
Move it to a sensible location, and at the same time,
rework the text to be a little clearer.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 15:31:45 +02:00
Graham Shaw 5f343bf20b packet.7: Add sll_protocol to list of required fields for outbound packets
The manpage packet(7) currently states that:

"When you send packets it is enough to specify sll_family, sll_addr,
sll_halen, sll_ifindex."

This is incorrect: you also need to specify sll_protocol.

(The protocol specified when the socket is created is used for
filtering inbound packets, but not for constructing outbound
packets.)

I encountered this while researching a page for my website:

http://www.microhowto.info/howto/send_an_arbitrary_ethernet_frame_using_an_af_packet_socket_in_c.html

To empirically verify the behaviour I took my test code from the
above page then changed it to use different values for the third
argument to socket() and the sll_protocol field:

- socket created with ETH_P_ARP, packet sent with ETH_P_ARP:
     packet sent with EtherType of ETH_P_ARP
- socket created with ETH_P_ARP, sll_protocol==0:
     packet sent with EtherType of 0
- socket created with 0x88b5, sll_protocol==htons(ETH_P_ARP):
     packet sent with EtherType of ETH_P_ARP
- socket created with ETH_P_ARP, sll_protocol==htons(0x88b5):
     packet sent with EtherType of 0x88b5

This shows that leaving sll_protocol set to zero does not have
the desired effect and that it needs to be set to the desired
link-layer protocol.

There is code in the relevant kernel source file
(net/packet/af_packet.c) which appears to inspect the value of the
sll_protocol field and use it as the link-layer protocol number,
however I am not sufficiently familiar with this subsystem to be
fully confident of what is happening. The line in question is:

     proto   = saddr->sll_protocol;

In version 3.4 of the kernel this can be found in the functions
packet_snd and tpacket_snd. In version 2.6.26 it is in packet_sendmsg.

Below is a patch that adds sll_protocol to the list of required fields.
This may not be the whole truth, since it is not clear what role if any
sll_protocol, sll_halen or sll_addr would play when the socket type is
SOCK_RAW, however I'm confident it is more accurate than the page as it
stands at present.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 15:01:52 +02:00
Michael Kerrisk 9e3f236d55 scanf.3: tfix
Reported-by: Jussi Lehtola <jussilehtola@fedoraproject.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 14:53:30 +02:00
Michael Kerrisk d86c357dee regex.3: Fix error in description of 'cflags'
'cflags' is a bit mask of *zero* (not one) or more flags.

Reported-by: Laurence Gonsalves <laurence@xenomachina.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 13:11:37 +02:00
Michael Kerrisk e464d6b282 tcp.7: srcfix: update FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 12:59:22 +02:00
Michael Kerrisk 15f043f9bf ip.7: Clarify details of the IP_MULTICAST_IF socket option
Reported-by: Jiri Pirko <jpirko@redhat.com>
Reported-by: Magnus REFTEL <magnus.xm.reftel@stericsson.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 12:34:33 +02:00
Michael Kerrisk 014dd01598 ip.7: Explain how IP_ADD_MEMBERSHIP determines its argument type
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 11:59:11 +02:00
Michael Kerrisk 38fdd3bba8 ip.7: Some minor rewordings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 11:59:11 +02:00
Michael Kerrisk 1d87723432 ip.7: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 11:05:49 +02:00
Michael Kerrisk d9b0993aab nscd.8: Add mention of 'services' and 'netgroup' databases
This makes the page consistent with nscd.conf(5).

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 10:39:44 +02:00
Michael Kerrisk 840aa3c7d4 unix.7: Note the 108 bytes for sun_path is how things are done on Linux
And refer the reader to NOTES for discussion of portability.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 10:24:56 +02:00
Michael Kerrisk 63bc262cd3 unix.7: Remove mention of UNIX_PATH_MAX
This kernel constant is not exposed to user space.

Reported-by: Christophe Lohr <Christophe.Lohr@telecom-bretagne.eu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 10:22:38 +02:00
Michael Kerrisk 5d75650a15 socket.7: srcfix: Add some comments on the undocumented SO_NO_CHECK option
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 10:02:57 +02:00
Michael Kerrisk d3c203f1a2 keyctl.2: srcfix: add FIXMES
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-06 09:44:03 +02:00
Michael Kerrisk 3a7ee7444c ip.7, socket.7: Remove dubious text that says that SO_PRIORITY set IP TOS
See https://bugzilla.kernel.org/show_bug.cgi?id=35852

Reported-by: Advait Dixi <advaitdixit@hotmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 21:18:51 +02:00
Michael Kerrisk ccbcc0aeed pthreads.7: Using thread IDs whose lifetime has expired gives undefined behavior
See https://bugzilla.kernel.org/show_bug.cgi?id=53061

Reported-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 21:11:59 +02:00
Michael Kerrisk 0ad13546b4 pthreads.7: Reorder text on thread IDs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 21:09:12 +02:00
Michael Kerrisk 77ee0a6073 ip.7: srcfix: remove unneeded comments
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 20:54:41 +02:00
Michael Kerrisk 79306ba124 printf.3: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:41:44 +02:00
Michael Kerrisk 73b9cbe1ca proc.5: Improve description of /proc/PID/status
Reported-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:35:54 +02:00
Michael Kerrisk 551b8ee119 get_phys_pages.3: srcfix: wrap long source lines
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:29:14 +02:00
Michael Kerrisk 1f11ec0ba7 get_phys_pages.3: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:28:35 +02:00
William Woodruff b2b19e8501 get_avphys_pages.3: New line to new get_phys_pages.3 page
Signed-off-by: William Woodruff <william@tuffbizz.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:24:04 +02:00
William Woodruff 178f0f6d67 get_phys_pages.3: Document get_phys_pages() and get_avphys_pages()
Signed-off-by: William Woodruff <william@tuffbizz.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:23:56 +02:00
Michael Kerrisk db939c9b26 cmsg.3: Fix error in SCM_RIGHTS code sample
Remove erroneous second initialization of msg.msg_controllen
in the example code for SCM_RIGHTS.
See https://bugzilla.kernel.org/show_bug.cgi?id=15952

Reported-by: Christopher Head <chead@chead.ca>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:00:26 +02:00
Michael Kerrisk ae1c1caab7 signal.7: Clarify that I/O operations on disks are not interrupted by signals
See https://bugzilla.kernel.org/show_bug.cgi?id=97721

Reported-by: Steinar H. Gunderson <sgunderson@bigfoot.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:00:26 +02:00
Michael Kerrisk fee59977e0 proc.5: Document /proc mount options
Document the 'hidepid' and 'gid' mount options that were added in
Linux 3.3.  See https://bugzilla.kernel.org/show_bug.cgi?id=90641
Based on text by Vasiliy Kulikov in
Documentation/filesystems/proc.txt.

Reported-by: Cameron Norman <camerontnorman@gmail.com>
Cowritten-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:00:26 +02:00
Michael Kerrisk 3739cdd4f8 prctl.2: Note that "parent" for purposes of PR_SET_DEATHSIG is a *thread*
See https://bugzilla.kernel.org/show_bug.cgi?id=43300

Reported-by: David Wilcox <davidvsthegiant@gmail.com>
Reported-by: Filipe Brandenburger <filbranden@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:00:26 +02:00
Gleb Fotengauer-Malinovskiy 4a38acf273 sendfile.2: tfix
Signed-off-by: Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 18:00:26 +02:00
Michael Kerrisk 3f4ed032f4 sendfile.2: RETURN VALUE: note the possibility of "short sends"
See https://bugzilla.kernel.org/show_bug.cgi?id=97491

Reported-by: Gregor Jasny <igjasny@googlemail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 16:03:55 +02:00
Michael Kerrisk 2a342fcf75 sendfile.2: Note that sendfile does not support O_APPEND for 'out_fd'
See https://bugzilla.kernel.org/show_bug.cgi?id=82841
Reported-by: Jason Newton <nevion@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 16:03:55 +02:00
Michael Kerrisk a27867c25e sendfile.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 16:03:55 +02:00
Michael Kerrisk 9e8a61e6ac sendfile.2: Clarify text on 'out_fd' and regular files in Linux 2.4
See https://bugzilla.kernel.org/show_bug.cgi?id=86001

Reported-by: Askar Safin <safinaskar@mail.ru>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-05-05 12:01:40 +02:00