Commit Graph

5168 Commits

Author SHA1 Message Date
Eric W. Biederman 6d47504df1 umount.2: Document the effect of shared subtrees on umount(2)
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-03 15:49:39 +01:00
Eric W. Biederman f131122173 umount.2: Correct the description of MNT_DETACH
I recently realized that I had been reasoning improperly about
what umount(MNT_DETACH) did based on an insufficient description
in the umount.2 man page, that matched my intuition but not the
implementation.

When there are no submounts, MNT_DETACH is essentially harmless to
applications.  Where there are submounts, MNT_DETACH changes what
is visible to applications using the detach directories.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-03 15:49:38 +01:00
Michael Kerrisk c9b0afde95 setns.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-03 09:50:24 +01:00
Michael Kerrisk 0f0daf7d99 ioctl_list.2: srcfix: remove unneeded "changelog" text
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-03 08:33:01 +01:00
Heinrich Schuchardt a44ffc6491 ioctl_list.2: include/linux/ext2_fs.h
Include linux/ext2_fs.h does not contain any ioctl definitions
anymore.

Request codes EXT2_IOC* have been replaced by FS_IOC* in
linux/fs.h.

Some definitions of FS_IOC_* use long* but the actual code expects
int* (see fs/ext2/ioctl.c).

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-03 08:30:03 +01:00
Michael Kerrisk 1533d24295 clone.2: Small rewording of explanation of clone() wrt threads
Clone has so many effects that it's an oversimplification to say
that the *main* use of clone is to create a thread.  (In fact,
the use of clone() to create new processes may well be more
common, since glibc's fork() is a wrapper that calls clone().)

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:25:57 +01:00
Michael Kerrisk bc9e70fad6 mount.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:25:57 +01:00
Michael Kerrisk 9316cc647e syscalls.2: Update for Linux 4.0
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:25:57 +01:00
Michael Kerrisk 28b44abc49 clone.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:25:56 +01:00
Josh Triplett 3dd889d9c1 clone.2: Document that clone silently ignores CLONE_PID and CLONE_STOPPED
Normally, system calls return EINVAL for flags they don't support.
Explicitly document that clone does *not* produce an error for these two
obsolete flags.

Signed-off-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:25:56 +01:00
Stéphane Aulery 1288e3ebaa intro.2: tfix
Signed-off-by: Stéphane Aulery <saulery@free.fr>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:25:56 +01:00
Michael Kerrisk f8b553ce14 getsockopt.2: Minor fixes to Konstantim Shemyak's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:22:26 +01:00
Konstantin Shemyak eb048645b6 getsockopt.2: Note RETURN VALUE details when netfilter is involved
From email conversation with Konstantin:

> * Are you saying there are case where successful
>   setsockopt() via nf_register_sockopt() might return a
>   value other zero?

Yes - it happens when the option is served by a custom
netfilter hook (this is how I bumped into this). Example:

Userspace code:

===================  cut here ================================

int main(void) {
   int sock;

   if ((sock = socket(AF_INET, SOCK_RAW, IPPROTO_RAW)) < 0)
     return -1;

   return setsockopt(sock, IPPROTO_IP, TEST_SETSOCKOPT_RETURN, NULL, 0);
}
===================  cut here ================================

Kernel module, handling the option 400 "TEST_SETSOCKOPT_RETURN":

===================  cut here ================================

/* Random value - just should not be already used by the running
system: */

static int test_sock_set_so(struct sock *sk, int cmd, void *param,
unsigned len) {
         return 42;
}

static struct nf_sockopt_ops test_sock_ops = {
         list:       {NULL, NULL},
         pf:         PF_INET,
         set_optmin: TEST_SETSOCKOPT_RETURN,
         set_optmax: (TEST_SETSOCKOPT_RETURN + 1),
         set:        test_sock_set_so,
         get_optmin: 0,
         get_optmax: 0,
         get:        NULL
};

static int test_sock_init(void) {
         return nf_register_sockopt(&test_sock_ops);  /* sanity check
skipped */
}

static void test_sock_exit(void) {
         nf_unregister_sockopt(&test_sock_ops);
}

module_init(test_sock_init);
module_exit(test_sock_exit);
===================  cut here ================================

After successful loading of the module, the executable returns 42,
and as I understand, that is the intention of netfilter authors.
Netfilter code calls the registered handle and just returns back to
user what it receives from it.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:22:26 +01:00
Heinrich Schuchardt 60dd142120 ioctl_list.2: SEE ALSO ioctl_fat.2
add FAT_IOCTL_GET_VOLUME_ID
SEE ALSO ioctl_fat.2

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:22:25 +01:00
Bill Pemberton 553deb4145 memfd_create.2: spfix
Change "behaviour" to American spelling "behavior".

Signed-off-by: Bill Pemberton <wfp5p@worldbroken.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:22:25 +01:00
Bill Pemberton 266df08333 cacheflush.2: spfix
Signed-off-by: Bill Pemberton <wfp5p@worldbroken.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:22:25 +01:00
Dmitry Deshevoy 146740934e fcntl.2: tfix
Signed-off-by: Dmitry Deshevoy <mityada@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 17:22:25 +01:00
Michael Kerrisk fe0fefbff3 mmap.2, a64l.3, abort.3, abs.3, acos.3, acosh.3, addseverity.3, adjtime.3, aio_cancel.3, aio_error.3, aio_fsync.3, aio_read.3, aio_return.3, aio_suspend.3, aio_write.3, alloca.3, argz_add.3, asin.3, asinh.3, assert.3, assert_perror.3, atan.3, atan2.3, atanh.3, atof.3, atoi.3, backtrace.3, basename.3, bcmp.3, bcopy.3, bindresvport.3, bsd_signal.3, btowc.3, byteorder.3, bzero.3, cabs.3, cacos.3, cacosh.3, canonicalize_file_name.3, carg.3, casin.3, casinh.3, catan.3, catanh.3, catgets.3, catopen.3, cbrt.3, ceil.3, cfree.3, cimag.3, clock_getcpuclockid.3, clog.3, clog10.3, closedir.3, confstr.3, conj.3, copysign.3, cos.3, cosh.3, cpow.3, cproj.3, creal.3, crypt.3, ctermid.3, daemon.3, des_crypt.3, difftime.3, dirfd.3, div.3, drand48.3, drand48_r.3, dysize.3, ecvt.3, ecvt_r.3, envz_add.3, erf.3, erfc.3, euidaccess.3, exec.3, exit.3, exp.3, exp10.3, exp2.3, expm1.3, fabs.3, fclose.3, fcloseall.3, fdim.3, fenv.3, ferror.3, fflush.3, ffs.3, fgetc.3, fgetwc.3, fgetws.3, finite.3, flockfile.3, floor.3, fma.3, fmax.3, fmin.3, fmod.3, fmtmsg.3, fnmatch.3, fopen.3, fopencookie.3, fpclassify.3, fread.3, frexp.3, ftime.3, ftok.3, futimes.3, gamma.3, getauxval.3, getcontext.3, getcwd.3, getdate.3, getdirentries.3, getdtablesize.3, getenv.3, getfsent.3, getgrent.3, getgrnam.3, getgrouplist.3, getloadavg.3, getlogin.3, getopt.3, getpass.3, getpt.3, getpwent.3, getpwnam.3, gets.3, getsubopt.3, getttyent.3, getusershell.3, getutmp.3, getw.3, gnu_get_libc_version.3, grantpt.3, hsearch.3, iconv.3, iconv_open.3, if_nametoindex.3, ilogb.3, index.3, inet.3, inet_pton.3, isalpha.3, isatty.3, isgreater.3, iswalnum.3, iswalpha.3, iswblank.3, iswcntrl.3, iswctype.3, iswdigit.3, iswgraph.3, iswlower.3, iswprint.3, iswpunct.3, iswspace.3, iswupper.3, iswxdigit.3, j0.3, ldexp.3, lio_listio.3, localeconv.3, lockf.3, log.3, log10.3, log1p.3, log2.3, logb.3, lrint.3, lround.3, lseek64.3, makecontext.3, makedev.3, malloc.3, malloc_usable_size.3, matherr.3, mblen.3, mbrlen.3, mbrtowc.3, mbsinit.3, mbstowcs.3, mbtowc.3, memccpy.3, memchr.3, memcmp.3, memcpy.3, memfrob.3, memmem.3, memmove.3, mempcpy.3, memset.3, mkdtemp.3, mkfifo.3, mkstemp.3, modf.3, mq_close.3, mq_getattr.3, mq_open.3, mq_receive.3, mq_send.3, mq_unlink.3, mtrace.3, nan.3, nextafter.3, nl_langinfo.3, opendir.3, posix_fallocate.3, posix_openpt.3, pow.3, pow10.3, pthread_attr_setdetachstate.3, pthread_attr_setguardsize.3, pthread_attr_setinheritsched.3, pthread_attr_setschedpolicy.3, pthread_attr_setscope.3, pthread_attr_setstack.3, pthread_attr_setstackaddr.3, pthread_attr_setstacksize.3, pthread_equal.3, pthread_exit.3, pthread_getcpuclockid.3, pthread_kill.3, pthread_kill_other_threads_np.3, pthread_self.3, pthread_setaffinity_np.3, pthread_setcancelstate.3, pthread_setconcurrency.3, pthread_setschedparam.3, pthread_setschedprio.3, pthread_sigmask.3, pthread_sigqueue.3, pthread_testcancel.3, pthread_yield.3, ptsname.3, putenv.3, puts.3, putwchar.3, qecvt.3, raise.3, rand.3, random.3, random_r.3, re_comp.3, readdir.3, realpath.3, regex.3, remainder.3, remove.3, remquo.3, rewinddir.3, rexec.3, rint.3, round.3, rtime.3, scalb.3, scalbln.3, sched_getcpu.3, seekdir.3, sem_destroy.3, sem_getvalue.3, sem_init.3, sem_post.3, sem_unlink.3, sem_wait.3, setbuf.3, setenv.3, siginterrupt.3, signbit.3, sigpause.3, sigqueue.3, sigset.3, sigsetops.3, sigvec.3, sigwait.3, sin.3, sincos.3, sinh.3, sockatmark.3, sqrt.3, stdarg.3, stdio_ext.3, stpcpy.3, stpncpy.3, strcasecmp.3, strcat.3, strchr.3, strcmp.3, strcpy.3, strerror.3, strfmon.3, strfry.3, strftime.3, strlen.3, strnlen.3, strpbrk.3, strptime.3, strsep.3, strspn.3, strstr.3, strtod.3, strtoimax.3, strtok.3, strtol.3, strtoul.3, strverscmp.3, strxfrm.3, swab.3, system.3, sysv_signal.3, tan.3, tanh.3, tcgetpgrp.3, tcgetsid.3, telldir.3, tempnam.3, termios.3, tgamma.3, timegm.3, tmpfile.3, tmpnam.3, toascii.3, toupper.3, towctrans.3, towlower.3, towupper.3, trunc.3, tsearch.3, ttyname.3, ttyslot.3, ualarm.3, ungetwc.3, unlockpt.3, usleep.3, wcpcpy.3, wcpncpy.3, wcscasecmp.3, wcscat.3, wcschr.3, wcscmp.3, wcscpy.3, wcscspn.3, wcsdup.3, wcslen.3, wcsncasecmp.3, wcsncat.3, wcsncmp.3, wcsncpy.3, wcsnlen.3, wcspbrk.3, wcsrchr.3, wcsspn.3, wcsstr.3, wcstoimax.3, wcstok.3, wcswidth.3, wctomb.3, wctrans.3, wctype.3, wcwidth.3, wmemchr.3, wmemcmp.3, wmemcpy.3, wmemmove.3, wmemset.3, y0.3, attributes.7, man-pages.7, standards.7: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-03-02 16:12:18 +01:00
Ma Shimiao 8fddf95ad5 mmap.2: ATTRIBUTES: Note functions that are thread-safe
The function mmap() and munmap() are thread safe.

Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-27 14:07:56 +01:00
Michael Kerrisk 5d28ea3e45 Removed trailing white space at end of lines 2015-02-21 12:14:39 +01:00
Michael Kerrisk 6d322d5fc7 time.1, access.2, arch_prctl.2, cacheflush.2, capget.2, clone.2, execve.2, fcntl.2, fork.2, getpid.2, getxattr.2, ioctl.2, ioctl_fat.2, killpg.2, listxattr.2, madvise.2, migrate_pages.2, modify_ldt.2, mprotect.2, msgget.2, msgop.2, perf_event_open.2, ptrace.2, sched_setattr.2, semget.2, semop.2, sendfile.2, set_thread_area.2, setxattr.2, stat.2, statfs.2, wait.2, wait4.2, encrypt.3, mktemp.3, pthread_attr_setschedparam.3, resolver.3, statvfs.3, syslog.3, tzset.3, core.5, host.conf.5, intro.5, proc.5, resolv.conf.5, pthreads.7, socket.7, unix.7, ld.so.8, ldconfig.8: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 09:26:52 +01:00
Michael Kerrisk db49aa3ea6 statfs.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:16 +01:00
Michael Kerrisk dba3f0dd25 statfs.2: Add a note on the __fsword_t type
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:16 +01:00
Michael Kerrisk 35c69c1e34 statfs.2: Use __fsword_t in statfs structure definition
This more closely matches modern glibc reality.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:16 +01:00
Michael Kerrisk 8645dc8689 statfs.2: Reinstate 'f_spare' but more vaguely
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:16 +01:00
Tao Ma c7c843be54 statfs.2: Add OCFS2_SUPER_MAGIC
Signed-off-by: Tao Ma <tao.ma@oracle.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:16 +01:00
Michael Kerrisk 1d6523633e statfs.2: Document the 'f_flags' field added in Linux 2.6.36
Reported-by: Jan Chaloupka <jchaloup@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 22795e81bb statfs.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk d85ddcc5b5 statfs.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 580ef86409 statfs.2: Minor wording and formatting fixes in structure definition
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 8add428555 statfs.2: Clarify that 'statfs' structure has some padding bytes
The number of padding bytes has changed over tyme, as some
bytes are used, so describe this aspect of the structure
less explicitly.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 36e5bc92ed madvise.2: Add mention of VM_PFNMAP in discussion of MADV_DONTNEED and MADV_REMOVE
Reported-by: Minchan Kim <minchan@kernel.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk d5e9c9bb50 madvise.2: Improve MADV_DONTNEED description
Cowritten-by: Michal Hocko <mhocko@suse.cz>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 8bdce466c4 madvise.2: Drop sentence saying that kernel may ignore 'advice'
The sentence creates misunderstandings, and does not really
add information.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk cd15218ee1 madvise.2: Clarifications for MADV_DONTNEED
Reported-by: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 711c9c034f madvise.2: NOTES: Remove crufty text about "command" versus "advice"
The point made in this fairly ancient text is more or less evident
from the DESCRIPTION, and it's not clear what "standard" is being
referred to.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk fb2bb886b8 madvise.2: Note that some Linux-specific 'advice' change memory-access semantics
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 95467f1d34 madvise.2: Minor fixes: miscellaneous wfix/tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk a727d7cc36 madvise.2: Minor fixups
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 5575818dbf madvise.2: Minor change: reorder some paragraphs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk deb9964960 madvise.2: Tweaks to Jan Chaloupka's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Jan Chaloupka f7282b7bbf madvise.2: Starting with Linux 3.5, more file systems support MADV_REMOVE
As from upstream commit:

commit 3f31d07571eeea18a7d34db9af21d2285b807a17
Author: Hugh Dickins <hughd@google.com>
Date:   Tue May 29 15:06:40 2012 -0700

     mm/fs: route MADV_REMOVE to FALLOC_FL_PUNCH_HOLE

     Now tmpfs supports hole-punching via fallocate(), switch madvise_remove()
     to use do_fallocate() instead of vmtruncate_range(): which extends
     madvise(,,MADV_REMOVE) support from tmpfs to ext4, ocfs2 and xfs.

madvise(,,MADV_REMOVE) support was extended by ext4, ocfs2 and xfs.

bug report: https://bugzilla.redhat.com/show_bug.cgi?id=1120294

Justification from Rafael Aquini:
Well, that code is committed in kernel since v3.5 (2012) and it
surely is the expected behaviour since. It seems to me that
madvise(2) man page text for MADV_REMOVE just got out-of-date in
that regard.

This patch mentions this support in madvise.2 man page.

Reworded and corrected by Michael Kerrisk and Hugh Dickins. Thank you.

Signed-off-by: Jan Chaloupka <jchaloup@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk bc6eb5efef madvise.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:15 +01:00
Michael Kerrisk 49170db521 madvise.2: Explain MADV_REMOVE in terms of file hole punching
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk c73c7130f7 madvise.2: Note that madvise() is nonstandard, but widespread
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 35187e77e7 madvise.2: srcfix: remove FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 96d4e25250 madvise.2: Clarify that MADV_DONTNEED has effect on pages only if it succeeds
Reported-by: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 9c0b66ebde madvise.2: ERRORS: add EPERM error case for MADV_HWPOISON
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 7208ad0a3d madvise.2: MADV_REMOVE can be applied only to shared writable mappings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 4335648dd1 madvise.2: MADV_REMOVE cannot be applied to locked or Huge TLB pages
See mm/madvise.c::madvise_remove()

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk aeb0944caa madvise.2: MADV_DONTNEED cannot be applied to Huge TLB or locked pages
See mm/madvise.c::madvise_dontneed()

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk a0c69e52d5 madvise.2: Note Huge TLB as a cause of EINVAL for MADV_DONTNEED
Reported-by: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 5c5df6bf9b madvise.2: Remove mention of "shared pages" as a cause of EINVAL for MADV_DONTNEED
Reported-by: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk ac95034e8a madvise.2: Split EINVAL error into separate cases
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 845c8bea2d madvise.2: Recast discussion of 'advice' into two groups of values
madvise() is one of those system calls that has congealed over
time, as has the man page. It's helpful to split the discussion
of 'advice' into those flags into two groups:

* Those flags that are (1) widespread across implementations;
  (2) have counterparts in posix_madvise(3); and (3) were present
  in the initial Linux madvise implementation.
* The rest, which are values that (1) may not have counterparts
  in other implementations; (2) have no counterparts in
  posix_madvise(3); and (3) were added to Linux in more recent
  times.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk bdfe6b8f8e madvise.2: Remove "POSIX.1b" from CONFORMING TO
I can find no evidence that madvise() was in POSIX.1b.
Certainly, it's not mentioned in Bill Gallmeister's
POSIX.4 book (O'Reilly).

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk c608a033d9 madvise.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk b4c1dae966 madvise.2: Move mention of posix_fadvise() from CONFORMING TO to SEE ALSO
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 05fde7dd42 madvise.2: Mention POSIX.1-2008 addition of POSIX_MADV_NOREUSE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 90f406fb12 madvise.2: ffix: Add some paragraph breaks in descriptions of 'advice'
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk b7bc9bfd17 madvise.2: Explicitly list the five flags provided by posix_fadvise()
Over time, bit rot has afflicted this page. Since the original
text was written many new Linux-specific flags have been added.
So, now it's better to explicitly list the flags that
correspond to the POSIX analog of madvise().

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 498f9213f3 madvise.2: srcfix: add commit hashes for various flags
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk d4e320965d ioctl_fat.2: Minor fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Heinrich Schuchardt 432cdf0d7c ioctl_fat.2: d_ino, d_off, return value explained
The fields d_ino and d_off of structure __fat_dirent are explained.

The different return values of VFAT_IOCTL_READDIR_BOTH and
VFAT_IOCTL_READDIR_SHORT are explained.

The usage of the return value in the example is corrected.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 3b4f95709f ioctl_fat.2: Use "exit()" rather than "return" to terminate main()
For consistency with other pages.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 3a6b94457d ioctl_fat.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 11a86b155d ioctl_fat.2: Tweak some pieces in EXAMPLE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 3289445e96 ioctl_fat.2: Add kernel version numbers for some ioctl() commands
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk f54da10e44 ioctl_fat.2: Tweaks to Heinrich's new page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:14 +01:00
Michael Kerrisk 68232827ac ioctl.2: SEE ALSO: add ioctl_fat(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk eeed01713b ioctl_fat.2: Rename from ioctl-fat.2
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Heinrich Schuchardt a1cd6a8ff6 ioctl-fat.2: New man page for the ioctl(2) FAT API
The ioctl(2) system call may be used to retrieve information about
the FAT file system and to set file attributes.

Signed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 6da93ae616 modify_ldt.2: Minor fixups
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Andy Lutomirski f89f50fa38 modify_ldt.2: Clarify the lm bit's behavior
The lm bit should never have existed in the first place.  Sigh.

Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk ed26cc5a2e set_thread_area.2: Tweaks after feedback from Andy Lutomirski
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk ef8db991f1 arch_prctl.2: Tweaks after feedback from Andy Lutomirski
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk c79a3031bb modify_ldt.2: Tweaks after feedback from Andy Lutomirski
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 520789667e set_thread_area.2: Various fixes for Andy Lutomirski's patch
Notably, various info about get_thread_area() got dropped
during the merge of the two pages.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 5c3f9e21f1 arch_prctl.2: Minor tweaks to Andy Lutomirski's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 7acf749e4f modify_ldt.2: Minor tweaks to Andy Lutomirski's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Andy Lutomirski 14620a2531 arch_prctl.2, set_thread_area.2, get_thread_area.2: Improve TLS documentation
The documentation for set_thread_area was very vague.  This
improves it, accounts for recent kernel changes, and merges
it with get_thread_area.2.

get_thread_area.2 now becomes a link.

While I'm at it, clarify the related arch_prctl.2 man page.

Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Andy Lutomirski 38f7c37983 modify_ldt.2: Overhaul the documentation
This clarifies the behavior and documents all four functions.

Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Akihiro Motoki 97c0185b99 restart_syscall.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 1fbe05e023 stat.2: NOTES: add "C library/kernel ABI differences" subheading
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 858f88b8a6 wait.2: Note that waitpid() is a wrapper for wait4()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 3e5977d606 getpid.2: NOTES: add "C library/kernel ABI differences" subheading
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk a99f81e6b6 nice.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk b8c523866d wait4.2: NOTES: add "C library/kernel ABI differences" subheading
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 5c68d6c79b killpg.2: NOTES: add "C library/kernel ABI differences" subheading
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 7704b6a995 wait.2: Note that wait() is a library function implemented via wait4()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk ae6e18f4b7 fork.2: NOTES: add "C library/kernel ABI differences" subheading
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Vince Weaver 50e4319c2a perf_event_open.2: Clarify PERF_EVENT_IOC_REFRESH behavior
Currently the PERF_EVENT_IOC_REFRESH ioctl, when applied to a group
leader, will refresh all children.  Also if a refresh value of 0
is chosen then the refresh becomes infinite (never runs out).
Back in 2011 PAPI was relying on these behaviors but I was told
that both were unsupported and subject to being removed at any time.
(See https://lkml.org/lkml/2011/5/24/337 )
However the behavior has not been changed.

This patch updates the manpage to still list the behavior as
unsupported, but removes the inaccurate description of it
only being a problem with 2.6 kernels.

Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Heinrich Schuchardt 7f810a615d fork.2: Child and parent run in separate memory spaces
fork.2 should clearly point out that child and parent
process run in separate memory spaces.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:13 +01:00
Michael Kerrisk 53cdec414b ptrace.2: Minor tweaks to Denys Vlasenko's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:12 +01:00
Denys Vlasenko 28e2ca574f ptrace.2: Add information on PTRACE_SEIZE versus PTRACE_ATTACH differences
Extend description of PTRACE_SEIZE with the short summary of its
differences from PTRACE_ATTACH.

The following paragraph:

PTRACE_EVENT_STOP
       Stop induced by PTRACE_INTERRUPT command, or group-stop, or ini-
       tial  ptrace-stop when a new child is attached (only if attached
       using PTRACE_SEIZE), or PTRACE_EVENT_STOP if PTRACE_SEIZE was used.

has an editing error (the part after last comma makes no sense).
Removing it.

Mention that legacy post-execve SIGTRAP is disabled by PTRACE_SEIZE.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:12 +01:00
Michael Kerrisk 0e48cd5a7c getxattr.2: Add pointer to example in listxattr(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:12 +01:00
Michael Kerrisk a8215524ac listxattr.2: Add note on handling increases in sizes of keys or values
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:12 +01:00
Michael Kerrisk 9c321ba20b listxattr.2: Minor fixups
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:12 +01:00
Heinrich Schuchardt 636a38776c listxattr.2: Provide example program
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Michael Kerrisk 0f2ea061ef capget.2: Rewrite discussion of kernel versions that support file capabilities
File capabilities ceased to be optional in Linux 2.6.33.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Michael Kerrisk 1872536844 capget.2: tfix 2015-02-21 08:32:11 +01:00
Michael Kerrisk 58bdfd464d capget.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Michael Kerrisk 5d33c0808b capget.2: Document V3 capabilities constants
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Michael Kerrisk 487c2f050d mmap.2: grfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
James Hunt 674f11ecbc ptrace.2: Explain behaviour should ptrace tracer call execve(2)
This behaviour was verified by reading the kernel source and
confirming the behaviour using a test program.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Eric Wong 7b6a329977 sendfile.2: Caution against modifying sent pages
The following program illustrates the difference between TCP
and Unix stream sockets doing sendfile.  Since TCP implements
zero-copy, the new modifications to the file transferred is
seen upon reading despite the modifications happening after
sendfile was last called.

Unix stream sockets do not implement zero-copy (as of
Linux 3.15), so readers continue to see the contents of the
file at the time it was sent, not as they are at the time of
reading.

----------------- sendfile-mod.c ---------------
	#define _GNU_SOURCE
	#include <sys/ioctl.h>
	#include <sys/types.h>
	#include <sys/socket.h>
	#include <sys/sendfile.h>
	#include <arpa/inet.h>
	#include <stdio.h>
	#include <errno.h>
	#include <string.h>
	#include <unistd.h>
	#include <assert.h>
	#include <fcntl.h>

static void tcp_socketpair(int sv[2])
{
	struct sockaddr_in addr;
	socklen_t addrlen = sizeof(addr);
	int l = socket(PF_INET, SOCK_STREAM, 0);
	int c = socket(PF_INET, SOCK_STREAM, 0);
	int a;
	int val = 1;

	addr.sin_family = AF_INET;
	addr.sin_addr.s_addr = INADDR_ANY;
	addr.sin_port = 0;
	assert(0 == bind(l, (struct sockaddr*)&addr, addrlen));
	assert(0 == listen(l, 1024));
	assert(0 == getsockname(l, (struct sockaddr *)&addr, &addrlen));
	assert(0 == connect(c, (struct sockaddr *)&addr, addrlen));
	a = accept4(l, NULL, NULL, SOCK_NONBLOCK);
	assert(a >= 0);
	close(l);
	assert(0 == ioctl(c, FIONBIO, &val));
	sv[0] = a;
	sv[1] = c;
}

int main(int argc, char *argv[])
{
	int pair[2];
	FILE *tmp = tmpfile();
	int tfd;
	char buf[16384];
	ssize_t w, r;
	size_t i;
	const size_t n = 2048;
	off_t off = 0;
	char expect[4096];
	int flags = SOCK_STREAM|SOCK_NONBLOCK;

	tfd = fileno(tmp);
	assert(tfd >= 0);

	/* prepare the tempfile */
	memset(buf, 'a', sizeof(buf));
	for (i = 0; i < n; i++)
		assert(sizeof(buf) == write(tfd, buf, sizeof(buf)));

	if (argc == 2 && strcmp(argv[1], "unix") == 0)
		assert(0 == socketpair(AF_UNIX, flags, 0, pair));
	else if (argc == 2 && strcmp(argv[1], "pipe") == 0)
		assert(0 == pipe2(pair, O_NONBLOCK));
	else
		tcp_socketpair(pair);

	/* fill up the socket buffer */
	for (;;) {
		w = sendfile(pair[1], tfd, &off, n);
		if (w > 0)
			continue;
		if (w < 0 && errno == EAGAIN)
			break;
		assert(0 && "unhandled error" && w && errno);
	}
	printf("wrote off=%lld\n", (long long)off);

	/* rewrite the tempfile */
	memset(buf, 'A', sizeof(buf));
	assert(0 == lseek(tfd, 0, SEEK_SET));
	for (i = 0; i < n; i++)
		assert(sizeof(buf) == write(tfd, buf, sizeof(buf)));

	/* we should be reading 'a's, not 'A's */
	memset(expect, 'a', sizeof(expect));
	do {
		r = read(pair[0], buf, sizeof(expect));

		/* TCP fails here since it is zero copy (on Linux 3.15.5) */
		if (r > 0)
			assert(memcmp(buf, expect, r) == 0);
	} while (r > 0);

	return 0;
}

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Peng Haitao 87ab04792c clone.2: Fix description of CLONE_PARENT_SETTID
CLONE_PARENT_SETTID only stores child thread ID in parent memory.

Signed-off-by: Peng Haitao <penght@cn.fujitsu.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Kevin Easton 8a76b19ecd clone.2, execve.2: Document interaction of execve(2) with CLONE_FILES
This patch the fact that a successful execve(2) in a process that
is sharing a file descriptor table results in unsharing the table.

I discovered this through testing and verified it by source
inspection - there is a call to unshare_files() early in
do_execve_common().

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Jan Stancek 3d350ba3c9 migrate_pages.2: Document EFAULT and EINVAL errors
I encountered these errors while writing testcase for migrate_pages
syscall for LTP (Linux test project).

I checked stable kernel tree 3.5 to see which paths return these.
Both can be returned from get_nodes(), which is called from:
SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsigned long, maxnode,
                const unsigned long __user *, old_nodes,
                const unsigned long __user *, new_nodes)

The testcase does following:
EFAULT
a) old_nodes/new_nodes is area mmaped with PROT_NONE
b) old_nodes/new_nodes is area not mmapped in process address
   space, -1 or area that has been just munmmaped

EINVAL
a) maxnodes overflows kernel limit
b) new_nodes contain node, which has no memory or does not exist
   or is not returned for get_mempolicy(MPOL_F_MEMS_ALLOWED).

Signed-off-by: Jan Stancek <jstancek@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:11 +01:00
Michael Kerrisk 7949b871f5 cacheflush.2: Refer reader to BUGS in discussion of EINVAL error
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:10 +01:00
Ralf Baechle 7bbc267ac3 cacheflush.2: Update some portability details and bugs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:32:10 +01:00
Mark Seaborn b22b377bd4 mprotect.2: mention effect of READ_IMPLIES_EXEC personality flag
I puzzled over mprotect()'s effect on /proc/*/maps for a while
yesterday -- it was setting "x" without PROT_EXEC being specified.
Here is a patch to add some explanation.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 08:31:58 +01:00
Michael Kerrisk cae279c4d5 access.2: Tweaks to Denys Vlasenko's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Denys Vlasenko 062d1cb332 access.2: Explain how access() check treats capabilities
We have users who are terribly confused why their binaries
with CAP_DAC_OVERRIDE capability see EACCESS from access() calls,
but are able to read the file.

The reason is access() isn't the "can I read/write/execute this
file?" question, it is the "(assuming that I'm a setuid binary,)
can *the user who invoked me* read/write/execute this file?"
question.

That's why it uses real UIDs as documented, and why it ignores
capabilities when capability-endorsed binaries are run by non-root
(this patch adds this information).

To make users more likely to notice this less-known detail,
the patch expands the explanation with rationale for this logic
into a separate paragraph.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
CC: linux-man@vger.kernel.org
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michael Kerrisk 4b081d8d9d sched_setattr.2: SYNOPSIS: remove 'const' from 'attr' sched_getattr() argument
Reported-by: Christophe Blaess <Christophe@blaess.fr>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michael Kerrisk 723560ba1c mlock.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michael Kerrisk cd6e402be4 pciconfig_read.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michal Hocko 17ad768d41 fork.2: EAGAIN is not reported when task allocation fails
I am not sure why we have:

   "EAGAIN fork() cannot allocate sufficient memory to copy
    the parent's page tables and allocate a task structure
    or the child."

The text seems to be there from the time when man-pages
were moved to git so there is no history for it.

And it doesn't reflect reality: the kernel reports both
dup_task_struct and dup_mm failures as ENOMEM to the
userspace. This seems to be the case from early 2.x times
so let's simply remove this part.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michael Kerrisk 98f792f704 semop.2: Note defaults for SEMOPM and warn against increasing > 1000
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michael Kerrisk 8a3e6dc72f semget.2: Note default value for SEMMNI and SEMMSL
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:28 +01:00
Michael Kerrisk a75f73c22a msgget.2: Add details of MSGMNI default value
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk faeaa68cca msgop.2: Clarify wording of MSGMAX and MSGMNB limits
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 2f2a53b56e setxattr.2: ERRORS: add ENOTSUP for invalid namespace prefix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 5e73ab4bc4 setxattr.2: Remove redundant text under ENOTSUP error
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 9398702ca2 setxattr.2: Rework text describing 'flags' argument
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 60da5b89a7 setxattr.2: Note that zero-length attribute values are permitted
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 736703bde2 setxattr.2: Minor rewordings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 5232e869b2 setxattr.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 220b2331ef removexattr.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 495420ae2c removexattr.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk a4526c2f11 listxattr.2: Reword discussion of size==0 case
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk fae9230bda getxattr.2: Various rewordings plus one or two details clarified
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk f1ec5ad108 listxattr.2: Remove mention of which filesystems implement ACLs
Such a list will only become outdated (as it already was).

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 2d10343d11 listxattr.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk ee6627733a fcntl.2: Clarify cases of conflict between traditional record and OFD locks
Verified by experiment on Linux 3.15 and 3.19rc4.

Acked-by: Jeff Layton <jlayton@poochiereds.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 2d7fc98dfe prctl.2: Greatly expand discussion of "dumpable" flag
In particular, detail the interactions with
/proc/sys/fs/suid_dumpable.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 6e2bb1c2f7 prctl.2: Reorder paragraphs describing PR_SET_DUMPABLE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 0de51ed1fc prctl.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 8aad30d779 prctl.2: Mention SUID_DUMP_DISABLE and SUID_DUMP_USER under PR_SET_DUMPABLE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 840a2b86c7 prctl.2: Executing a file with capabilities also resets the parent death signal
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:27 +01:00
Michael Kerrisk 4a3713a498 prctl.2: Minor restructuring of text for PR_SET_DUMPABLE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:26 +01:00
Michael Kerrisk 13f296bcc4 prctl.2: Mention file capabilities in discussion of PR_SET_DUMPABLE
Reported-by: Bill McConnaughey <mcconnau@biochem.wustl.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-21 07:58:24 +01:00
Michael Kerrisk f55912a99f getcpu.2: tfix
Reported-by: Zbigniew Brzeziński <zbigniew.brzezinski@student.put.poznan.pl>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-04 20:26:19 +01:00
Heinrich Schuchardt 35800487b6 getrandom.2: tfix
Let's assume Michael's email address did not change.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-03 08:16:32 +01:00
Michael Kerrisk 4f69e06a2c Removed trailing white space at end of lines 2015-02-01 17:14:59 +01:00
Michael Kerrisk 9dc53e71c2 kexec_load.2, personality.2, prctl.2, reboot.2, socket.2, fflush.3, getopt.3, random.3, termios.3, random.4, passwd.5, capabilities.7, signal.7: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-01 17:14:12 +01:00
Michael Kerrisk fd4b38534c personality.2: SEE ALSO: add setarch(8)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-02-01 09:13:57 +01:00
Michael Kerrisk 3907aed3a1 getrandom.2: srcfix: Update copyright for Heinrich
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-31 14:37:52 +01:00
Michael Kerrisk f86ee883f4 getrandom.2: Add mtk to copyright
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-31 14:37:30 +01:00
Michael Kerrisk e84195de1e kexec_load.2: ERRROS: add some details to kexec_file_load ENOEXEC error
Reported-by: Scot Doyle <lkml14@scotdoyle.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-30 16:23:45 +01:00
Michael Kerrisk 077e532d80 getrandom.2: Minor tweaks
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 23:28:58 +01:00
Michael Kerrisk bfa4433525 socket.2: Tweaks to Stephan Mueller's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 23:24:57 +01:00
Stephan Mueller 31d070f8b4 socket.2: document AF_ALG
Add a reference to the AF_ALG protocol accessible via socket(2).

Signed-off-by: Stephan Mueller <stephan.mueller@atsec.com>
CC: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 23:22:59 +01:00
Michael Kerrisk 0646abd614 getrandom.2: Rework GRND_RANDOM text
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 23:12:23 +01:00
Michael Kerrisk 3426471b46 getrandom.2: Rework discussion of blocking section on interuption by signals
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 23:12:23 +01:00
Michael Kerrisk 8f891eb06d semget.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 11:12:44 +01:00
Michael Kerrisk 6b5e7695be getrandom.2: Reads from /dev/urandom can block for large request sizes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:12:48 +01:00
Michael Kerrisk 2cc7c11a89 getrandom.2: SEE ALSO: add signal(7)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:03:32 +01:00
Michael Kerrisk a66935bad6 getrandom.2: Give the reader a hint about when /dev/urandom is initialized
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:03:32 +01:00
Michael Kerrisk 2c7135dbfb getrandom.2: Minor tweaks to Heinrich's text
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:03:32 +01:00
Heinrich Schuchardt 11353d7b62 getrandom.2: Clarification of open questions
With his last patches for getrandom.2 Michael Kerrisk posed a few
questions and left some comments in the man-page. This patch
seeks to clarify the open issues.

 72 For example, if the call is interrupted by a signal handler,
 73 it may return a partially filled buffer, or fail with the error
 74 .BR EINTR .
 75 .\" Tested with buffer sizes > 256 bytes: both partial reads
 76 .\" and EINTR can occur, with the former being more frequent.
 77 .\"

Michael's observation agrees with the code.
For buffer size > 256: If the buffer is still empty EINTR occurs.
If any number of bytes has been read to the buffer, that number
is returned.  The comment can be removed.

 78 .\" mtk: In the absence of signals, in my testing, even very large reads
 79 .\" return full buffers. I found that reads of up to 33554431 always
 80 .\" returned a filled buffer. Specifying 'buflen' > 33554431 always
 81 .\" returned just 33554431 bytes. (I'm not sure where that number comes
        from.

The maximum number of bytes transferred is limited for
/dev/urandom to:

    nbytes = min_t(size_t, nbytes, INT_MAX >> (ENTROPY_SHIFT + 3));
    // <= 0x1fffff

and for /dev/random to
nbytes = min_t(size_t, nbytes, SEC_XFER_SIZE); // <= 0x200

Lets put this into the NOTES section.

 224 When reading from
 225 .IR /dev/random ,
 226 blocking requests of any size can be interrupted by a signal
 227 (the call fails with the error
 228 .BR EINTR ).

Thats ok.

 82 If the pool has not yet been initialized, then the call blocks, unless
 83 .B GRND_RANDOM
 84 is specified in
 85 .IR flags .
 86 .\" FIXME We need a bit more information here.
 87 .\"       The reader will ask: when is /dev/urandom initialized?
 88 .\"       There should be some text here to explain that.

Entropy is collected from different sources, e.g.
 - time of reaping a thread
 - MAC address of a network interfaces
 - Allwinner security ID
 - ROM content of a firewire device
 - ...

When more than 128 bits have been collected, the pool is set
to initialized.

I suggest that detailed information about the initialization
should be provided on the random.4 page.

I added a paragraph in the NOTES section.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 053e5e6914 getrandom.2: Enhance discussion of /dev/urandom reads in DESCRIPTION
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 652febf0d9 getrandom.2: Clarify interaction of GRND_RANDOM and signals
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 05e4d7afa9 getrandom.2: NOTES: clarify discussion of EINTR error
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 473844a13d getrandom.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk f350b993d0 getrandom.2: srcfix: add FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 973ff2fc67 getrandom.2: Clarify text with respect to GRND_NONBLOCK
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 28ef3452e4 getrandom.2: Clarify sentence on getrandom() and partial GRND_RANDOM reads
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 978323c72e getrandom.2: Reword sentence on blocked getrandom() and interruption by signals
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 81d43c5023 getrandom.2: Minor wording fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 3851c7aa65 getrandom.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Heinrich Schuchardt e14ee946e8 getrandom.2: Rework paragraphs marked with FIXME
The patch clarifies when blocking may occur while calling
getrandom().

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Heinrich Schuchardt 16199698a6 getrandom.2: Mention bug concerning treatment of interrupts
Theodore Ts'o confirmed the bug described in
https://lkml.org/lkml/2014/11/29/16

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk e8009a53e8 getrandom.2: Reword GRND_RANDOM description
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk d2a1b46b62 getrandom.2: Reword GRND_NONBLOCK description
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 7028ce50ab getrandom.2: Add a sentence to clarify the default behavior of getrandom()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk a550a24de3 getrandom.2: srcfix: added FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:41 +01:00
Michael Kerrisk 01a6407427 getrandom.2: Minor wording fixes
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:40 +01:00
Heinrich Schuchardt 18647599c7 getrandom.2: New page documenting getrandom(2)
Kernel 3.17 introduces a new system call getrandom(2).

The man page in this patch is based on the commit message by
Theodore Ts'o and suggestions by Michael Kerrisk.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-29 09:02:40 +01:00
Michael Kerrisk 91907c29c0 kexec_load.2: srcfix: add mtk to copyright list
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:38 +01:00
Michael Kerrisk 32a7f2ba0a kexec_load.2: ERRORS: add some further error cases
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:38 +01:00
Michael Kerrisk 1c720ce5e1 kexec_load.2: Edits after Q&A from Vivek Goyal
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:38 +01:00
Michael Kerrisk 443755df50 kexec_load.2: Various additions after feedback from Vivek Goyal
Cowritten-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:38 +01:00
Michael Kerrisk 13a2f9fed9 kexec_load.2: Better describe EINVAL error when nr_segments exceeds KEXEC_SEGMENT_MAX
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:38 +01:00
Michael Kerrisk a2d429c940 kexec_file_load.2: New link to kexec_load.2 2015-01-28 21:56:38 +01:00
Michael Kerrisk e328452136 kexec_load.2: Remove crufty statements that constants are not exported to glibc
With the kernel "uapi" changes of a a few releases ago, these
constants are now automatically provided to glibc.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:32 +01:00
Michael Kerrisk 36aa66d180 kexec_load.2: Move some text from NOTES to DESCRIPTION
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:32 +01:00
Michael Kerrisk bc5df8e587 kexec_load.2: SEE ALSO: add Documentation/kernel-parameters.txt
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:32 +01:00
Michael Kerrisk c328e5b3e1 kexec_load.2: SEE ALSO: add Documentation/kdump/kdump.txt
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:32 +01:00
Michael Kerrisk 2139e7cf8d kexec_load.2: Edits after review comments by Vivek Goyal
Reviewed-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:56:26 +01:00
Michael Kerrisk 57afc6dfc8 kexec_load.2: srcfix: Add Vivek Goyal to copyright notice
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 16edbdd933 kexec_load.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 6fd7d53070 kexec_load.2: Note rationale for kexec_file_load()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 2f14583867 kexec_load.2: Minor rewording
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk b1340c3041 kexec_load.2: SEE ALSO: add kexec(8)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 352e737d59 reboot.2: ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 260be1fe70 reboot.2: SEE ALSO: add kexec_load(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 00db326ac4 kexec_load.2: Add FIXMEs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 046cebb34f kexec_load.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 84953b5363 kexec_load.2: srcfix: remove a FIXME
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk a2c8cd3787 kexec_load.2: kexec_file_load() requires CONFIG_KEXEC_FILE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 75cd256427 kexec_load.2: CONFORMING TO: update for kexec_file_load()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk e19cb54662 kexec_load.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 798711f78f kexec_load.2: Note kernel version for kexec_file_load()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 89a2edf198 kexec_load.2: Tweaks to Vivek Goyal's patch
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Vivek Goyal 7ca024693a kexec_load.2: Document new kexec_file_load() system call
Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 21:45:04 +01:00
Michael Kerrisk 394a52fc0d statfs.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:25:25 +01:00
Michael Kerrisk 7f2a9e4c98 shmctl.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:23:46 +01:00
Michael Kerrisk 59363bb422 setns.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:23:14 +01:00
Michael Kerrisk d4e5193b95 select_tut.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:21:36 +01:00
Michael Kerrisk 6170255e9f perf_event_open.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:19:50 +01:00
Michael Kerrisk 2bf79fbd84 ioprio_set.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:16:45 +01:00
Michael Kerrisk 312d8fde6d execve.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:14:53 +01:00
Michael Kerrisk f6248738a2 close.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-28 10:14:15 +01:00
Michael Kerrisk 7fac71bede prctl.2: Unused arguments of PR_MPX_(EN,DIS}ABLE_MANAGEMENT must be zero
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-26 06:56:28 +01:00
Vince Weaver 747a6e7ce0 perf_event_open.2: srcfix: add git commit references
I noticed you were adding git commit references to the various
Linux version markers.

This adds git commit references for all Linux kernel version
notes in perf_event_open.2

mtk: I backed out two pieces of Vince's patch that were not
source comments. They can be dealt with as separate commits.

Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-25 20:32:43 +01:00
Michael Kerrisk 771e13d4b3 Removed trailing white space at end of lines 2015-01-22 23:36:33 +01:00
Michael Kerrisk 8392a3b33f _exit.2, dup.2, execve.2, execveat.2, fallocate.2, fcntl.2, get_robust_list.2, getrlimit.2, mbind.2, memfd_create.2, mmap.2, open.2, ptrace.2, readv.2, select.2, sigaction.2, syscall.2, syscalls.2, truncate.2, utimensat.2, write.2, errno.3, exec.3, fclose.3, fexecve.3, fmemopen.3, fopencookie.3, getgrent_r.3, getline.3, getmntent.3, getpw.3, getpwent_r.3, getspnam.3, malloc_info.3, posix_fallocate.3, putgrent.3, shm_open.3, locale.5, proc.5: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 23:29:25 +01:00
Michael Kerrisk 20889818f7 execveat.2: srcfix: Copyright
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 22:16:29 +01:00
Akihiro Motoki a1d88c4c2a sigaction.2: tfix and ffix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 20:49:14 +01:00
Akihiro Motoki 8c659c4849 fanotify_mark.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 20:48:11 +01:00
Michael Kerrisk 5a69ce9c3a perf_event_open.2: Correct the kernel version number for PERF_COUNT_HW_CACHE_NODE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 09:05:32 +01:00
Michael Kerrisk 60dafbc123 perf_event_open.2: Add some kernel version numbers to various fields and constants
And add some commit hashes in the page source.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 09:05:32 +01:00
Michael Kerrisk 3117263f1d perf_event_open.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 08:45:12 +01:00
Michael Kerrisk e41c36b29d perf_event_open.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-22 08:45:11 +01:00
Michael Kerrisk 4010bc07b3 perf_event_open.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-21 13:28:58 +01:00
Vince Weaver 21977c9d2a perf_event_open.2: Clarify description of overflow events
Update the perf_event_open manpage to be more consistent when
discussing overflow events.  It merges the discussion of
poll-type notifications with those generated by SIGIO
signal handlers.
This addresses the remaining FIXMEs is the document.

Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-21 13:28:58 +01:00
Vince Weaver 223413b769 perf_event_open.2: Remove innaccurate paragraph describing attr.config
Remove an inaccurate paragraph about values in the attr.config
field.  This information was never true in any released kernel;
it somehow snuck into the manpage because it is still described
this way in tools/perf/design.txt in the kernel source tree.

Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-21 13:28:40 +01:00
Michael Kerrisk 8b5857b0c2 readv.2: Reorder "C library/kernel ABI differences" subsections under NOTES
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 17:41:37 +01:00
Michael Kerrisk 8a930bf121 readv.2: Update details on glibc readv()/writev() wrapper behavior
And add a historical detail about Linux 2.0.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 17:37:40 +01:00
Michael Kerrisk bc9ed112b7 readv.2: Minor reformatting in ERRORS
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 16:41:45 +01:00
Michael Kerrisk 45824ece75 _exit.2: Add "C library/kernel ABI differences" for paragraph on exit_group()
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 15:55:50 +01:00
Michael Kerrisk 80a74083d9 syscalls.2: Adds390_pci_mmio_read(2) and s390_pci_mmio_write(2)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 15:18:43 +01:00
Michael Kerrisk 18eff6b944 s390_pci_mmio_write.2: Tweaks to Alexey Ishchuk's page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 15:18:43 +01:00
Michael Kerrisk c1eb8ec5f5 s390_pci_mmio_write.2: srcfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-20 15:18:43 +01:00
Michael Kerrisk a131216fd4 s390_pci_mmio_read.2: New link to new s390_pci_mmio_write(2) page
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 15:57:16 +01:00
Alexey Ishchuk a698082e6e s390_pci_mmio_write.2: New page for s390 s390_pci_mmio_write() and s390_pci_mmio_read()
New manual page for the new PCI MMIO memory access system
calls, s390_pci_mmio_write() and s390_pci_mmio_read(),
added for the s390 platform.

Signed-off-by: Alexey Ishchuk <aishchuk@linux.vnet.ibm.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 15:55:11 +01:00
Michael Kerrisk 5edd5994a4 mbind.2: Clarify EFAULT text
Reported-by: Daniel J Blueman <daniel@quora.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 15:02:13 +01:00
Michael Kerrisk c733b64158 fcntl.2: ERRORS: add EBUSY case for F_SETPIPE_SZ
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk 7570f8afad fcntl.2: ERRORS: add open file description lock error cases
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk 3edddb9e32 fcntl.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk 1030085696 fcntl.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk bb38aaab17 fcntl.2: ERRORS: add various file-sealing error cases
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk 158439352c fcntl.2: Edits and additions after review by David Herrmann
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk fbab10e5d6 fallocate.2, mmap.2, open.2, truncate.2, write.2: ERRORS: add EPERM for operation denied by file seal
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk 468326627a memfd_create.2: Edits and additions after review by David Herrmann
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk 878cc34886 memfd_create.2: Add EXAMPLE programs
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk e8a0dfae91 memfd_create.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk db61d4b2fa memfd_create.2: tfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00
Michael Kerrisk e893b61ea1 memfd_create.2: wfix
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2015-01-19 10:35:33 +01:00