From c788525612fd52a9c1b5d9a2c242f3d002b838df Mon Sep 17 00:00:00 2001 From: Michael Kerrisk Date: Sat, 19 Aug 2017 21:02:23 +0200 Subject: [PATCH] getrlimit.2, signalfd.2, statfs.2, tee.2, dlopen.3, duplocale.3, ftw.3, get_nprocs.3, mbstowcs.3, posix_spawn.3, strftime.3, full.4, fanotify.7, inotify.7, ip.7, netdevice.7, rtld-audit.7, unix.7: ffix Signed-off-by: Michael Kerrisk --- man2/getrlimit.2 | 14 ++-- man2/signalfd.2 | 2 +- man2/statfs.2 | 174 +++++++++++++++++++++++---------------------- man2/tee.2 | 2 +- man3/dlopen.3 | 2 +- man3/duplocale.3 | 1 + man3/ftw.3 | 1 + man3/get_nprocs.3 | 1 - man3/mbstowcs.3 | 1 + man3/posix_spawn.3 | 1 + man3/strftime.3 | 1 + man4/full.4 | 12 ++-- man7/fanotify.7 | 1 + man7/inotify.7 | 1 + man7/ip.7 | 3 +- man7/netdevice.7 | 2 +- man7/rtld-audit.7 | 2 +- man7/unix.7 | 1 + 18 files changed, 118 insertions(+), 104 deletions(-) diff --git a/man2/getrlimit.2 b/man2/getrlimit.2 index 01948c827..61c7b7b55 100644 --- a/man2/getrlimit.2 +++ b/man2/getrlimit.2 @@ -251,25 +251,27 @@ This limit is enforced for .BR mq_open (3). Each message queue that the user creates counts (until it is removed) against this limit according to the formula: -.EX - +.IP Since Linux 3.5: - +.IP +.EX bytes = attr.mq_maxmsg * sizeof(struct msg_msg) + min(attr.mq_maxmsg, MQ_PRIO_MAX) * sizeof(struct posix_msg_tree_node)+ /* For overhead */ attr.mq_maxmsg * attr.mq_msgsize; /* For message data */ - +.EE +.IP Linux 3.4 and earlier: - +.IP +.EX bytes = attr.mq_maxmsg * sizeof(struct msg_msg *) + /* For overhead */ attr.mq_maxmsg * attr.mq_msgsize; /* For message data */ - .EE +.IP where .I attr is the diff --git a/man2/signalfd.2 b/man2/signalfd.2 index 0459decb8..3a78a7040 100644 --- a/man2/signalfd.2 +++ b/man2/signalfd.2 @@ -197,9 +197,9 @@ struct signalfd_siginfo { uint8_t pad[\fIX\fP]; /* Pad size to 128 bytes (allow for additional fields in the future) */ }; - .EE .in +.PP Each of the fields in this structure is analogous to the similarly named field in the .I siginfo_t diff --git a/man2/statfs.2 b/man2/statfs.2 index 6af9731e8..cf67f0054 100644 --- a/man2/statfs.2 +++ b/man2/statfs.2 @@ -64,92 +64,96 @@ struct statfs { __fsword_t f_spare[xxx]; /* Padding bytes reserved for future use */ }; - +.EE +.in +.PP Filesystem types: - - ADFS_SUPER_MAGIC 0xadf5 - AFFS_SUPER_MAGIC 0xadff - AFS_SUPER_MAGIC 0x5346414f - ANON_INODE_FS_MAGIC 0x09041934 - AUTOFS_SUPER_MAGIC 0x0187 - BDEVFS_MAGIC 0x62646576 - BEFS_SUPER_MAGIC 0x42465331 - BFS_MAGIC 0x1badface - BINFMTFS_MAGIC 0x42494e4d - BPF_FS_MAGIC 0xcafe4a11 - BTRFS_SUPER_MAGIC 0x9123683e - BTRFS_TEST_MAGIC 0x73727279 - CGROUP_SUPER_MAGIC 0x27e0eb - CGROUP2_SUPER_MAGIC 0x63677270 - CIFS_MAGIC_NUMBER 0xff534d42 - CODA_SUPER_MAGIC 0x73757245 - COH_SUPER_MAGIC 0x012ff7b7 - CRAMFS_MAGIC 0x28cd3d45 - DEBUGFS_MAGIC 0x64626720 - DEVFS_SUPER_MAGIC 0x1373 - DEVPTS_SUPER_MAGIC 0x1cd1 - ECRYPTFS_SUPER_MAGIC 0xf15f - EFIVARFS_MAGIC 0xde5e81e4 - EFS_SUPER_MAGIC 0x00414a53 - EXT_SUPER_MAGIC 0x137d - EXT2_OLD_SUPER_MAGIC 0xef51 - EXT2_SUPER_MAGIC 0xef53 - EXT3_SUPER_MAGIC 0xef53 - EXT4_SUPER_MAGIC 0xef53 - F2FS_SUPER_MAGIC 0xf2f52010 - FUSE_SUPER_MAGIC 0x65735546 - FUTEXFS_SUPER_MAGIC 0xbad1dea - HFS_SUPER_MAGIC 0x4244 - HOSTFS_SUPER_MAGIC 0x00c0ffee - HPFS_SUPER_MAGIC 0xf995e849 - HUGETLBFS_MAGIC 0x958458f6 - ISOFS_SUPER_MAGIC 0x9660 - JFFS2_SUPER_MAGIC 0x72b6 - JFS_SUPER_MAGIC 0x3153464a - MINIX_SUPER_MAGIC 0x137f /* orig. minix */ - MINIX_SUPER_MAGIC2 0x138f /* 30 char minix */ - MINIX2_SUPER_MAGIC 0x2468 /* minix V2 */ - MINIX2_SUPER_MAGIC2 0x2478 /* minix V2, 30 char names */ - MINIX3_SUPER_MAGIC 0x4d5a /* minix V3 fs, 60 char names */ - MQUEUE_MAGIC 0x19800202 - MSDOS_SUPER_MAGIC 0x4d44 - MTD_INODE_FS_MAGIC 0x11307854 - NCP_SUPER_MAGIC 0x564c - NFS_SUPER_MAGIC 0x6969 - NILFS_SUPER_MAGIC 0x3434 - NSFS_MAGIC 0x6e736673 - NTFS_SB_MAGIC 0x5346544e - OCFS2_SUPER_MAGIC 0x7461636f - OPENPROM_SUPER_MAGIC 0x9fa1 - OVERLAYFS_SUPER_MAGIC 0x794c7630 - PIPEFS_MAGIC 0x50495045 - PROC_SUPER_MAGIC 0x9fa0 - PSTOREFS_MAGIC 0x6165676c - QNX4_SUPER_MAGIC 0x002f - QNX6_SUPER_MAGIC 0x68191122 - RAMFS_MAGIC 0x858458f6 - REISERFS_SUPER_MAGIC 0x52654973 - ROMFS_MAGIC 0x7275 - SECURITYFS_MAGIC 0x73636673 - SELINUX_MAGIC 0xf97cff8c - SMACK_MAGIC 0x43415d53 - SMB_SUPER_MAGIC 0x517b - SOCKFS_MAGIC 0x534f434b - SQUASHFS_MAGIC 0x73717368 - SYSFS_MAGIC 0x62656572 - SYSV2_SUPER_MAGIC 0x012ff7b6 - SYSV4_SUPER_MAGIC 0x012ff7b5 - TMPFS_MAGIC 0x01021994 - TRACEFS_MAGIC 0x74726163 - UDF_SUPER_MAGIC 0x15013346 - UFS_MAGIC 0x00011954 - USBDEVICE_SUPER_MAGIC 0x9fa2 - V9FS_MAGIC 0x01021997 - VXFS_SUPER_MAGIC 0xa501fcf5 - XENFS_SUPER_MAGIC 0xabba1974 - XENIX_SUPER_MAGIC 0x012ff7b4 - XFS_SUPER_MAGIC 0x58465342 - _XIAFS_SUPER_MAGIC 0x012fd16d +.PP +.in +4n +.EX +ADFS_SUPER_MAGIC 0xadf5 +AFFS_SUPER_MAGIC 0xadff +AFS_SUPER_MAGIC 0x5346414f +ANON_INODE_FS_MAGIC 0x09041934 +AUTOFS_SUPER_MAGIC 0x0187 +BDEVFS_MAGIC 0x62646576 +BEFS_SUPER_MAGIC 0x42465331 +BFS_MAGIC 0x1badface +BINFMTFS_MAGIC 0x42494e4d +BPF_FS_MAGIC 0xcafe4a11 +BTRFS_SUPER_MAGIC 0x9123683e +BTRFS_TEST_MAGIC 0x73727279 +CGROUP_SUPER_MAGIC 0x27e0eb +CGROUP2_SUPER_MAGIC 0x63677270 +CIFS_MAGIC_NUMBER 0xff534d42 +CODA_SUPER_MAGIC 0x73757245 +COH_SUPER_MAGIC 0x012ff7b7 +CRAMFS_MAGIC 0x28cd3d45 +DEBUGFS_MAGIC 0x64626720 +DEVFS_SUPER_MAGIC 0x1373 +DEVPTS_SUPER_MAGIC 0x1cd1 +ECRYPTFS_SUPER_MAGIC 0xf15f +EFIVARFS_MAGIC 0xde5e81e4 +EFS_SUPER_MAGIC 0x00414a53 +EXT_SUPER_MAGIC 0x137d +EXT2_OLD_SUPER_MAGIC 0xef51 +EXT2_SUPER_MAGIC 0xef53 +EXT3_SUPER_MAGIC 0xef53 +EXT4_SUPER_MAGIC 0xef53 +F2FS_SUPER_MAGIC 0xf2f52010 +FUSE_SUPER_MAGIC 0x65735546 +FUTEXFS_SUPER_MAGIC 0xbad1dea +HFS_SUPER_MAGIC 0x4244 +HOSTFS_SUPER_MAGIC 0x00c0ffee +HPFS_SUPER_MAGIC 0xf995e849 +HUGETLBFS_MAGIC 0x958458f6 +ISOFS_SUPER_MAGIC 0x9660 +JFFS2_SUPER_MAGIC 0x72b6 +JFS_SUPER_MAGIC 0x3153464a +MINIX_SUPER_MAGIC 0x137f /* orig. minix */ +MINIX_SUPER_MAGIC2 0x138f /* 30 char minix */ +MINIX2_SUPER_MAGIC 0x2468 /* minix V2 */ +MINIX2_SUPER_MAGIC2 0x2478 /* minix V2, 30 char names */ +MINIX3_SUPER_MAGIC 0x4d5a /* minix V3 fs, 60 char names */ +MQUEUE_MAGIC 0x19800202 +MSDOS_SUPER_MAGIC 0x4d44 +MTD_INODE_FS_MAGIC 0x11307854 +NCP_SUPER_MAGIC 0x564c +NFS_SUPER_MAGIC 0x6969 +NILFS_SUPER_MAGIC 0x3434 +NSFS_MAGIC 0x6e736673 +NTFS_SB_MAGIC 0x5346544e +OCFS2_SUPER_MAGIC 0x7461636f +OPENPROM_SUPER_MAGIC 0x9fa1 +OVERLAYFS_SUPER_MAGIC 0x794c7630 +PIPEFS_MAGIC 0x50495045 +PROC_SUPER_MAGIC 0x9fa0 +PSTOREFS_MAGIC 0x6165676c +QNX4_SUPER_MAGIC 0x002f +QNX6_SUPER_MAGIC 0x68191122 +RAMFS_MAGIC 0x858458f6 +REISERFS_SUPER_MAGIC 0x52654973 +ROMFS_MAGIC 0x7275 +SECURITYFS_MAGIC 0x73636673 +SELINUX_MAGIC 0xf97cff8c +SMACK_MAGIC 0x43415d53 +SMB_SUPER_MAGIC 0x517b +SOCKFS_MAGIC 0x534f434b +SQUASHFS_MAGIC 0x73717368 +SYSFS_MAGIC 0x62656572 +SYSV2_SUPER_MAGIC 0x012ff7b6 +SYSV4_SUPER_MAGIC 0x012ff7b5 +TMPFS_MAGIC 0x01021994 +TRACEFS_MAGIC 0x74726163 +UDF_SUPER_MAGIC 0x15013346 +UFS_MAGIC 0x00011954 +USBDEVICE_SUPER_MAGIC 0x9fa2 +V9FS_MAGIC 0x01021997 +VXFS_SUPER_MAGIC 0xa501fcf5 +XENFS_SUPER_MAGIC 0xabba1974 +XENIX_SUPER_MAGIC 0x012ff7b4 +XFS_SUPER_MAGIC 0x58465342 +_XIAFS_SUPER_MAGIC 0x012fd16d .EE .in .PP diff --git a/man2/tee.2 b/man2/tee.2 index 9e10455b9..3e6001cb7 100644 --- a/man2/tee.2 +++ b/man2/tee.2 @@ -148,8 +148,8 @@ Tue Oct 28 10:06:00 CET 2014 .EE .in .SS Program source +\& .EX - #define _GNU_SOURCE #include #include diff --git a/man3/dlopen.3 b/man3/dlopen.3 index 1f2baf6e3..636eee16c 100644 --- a/man3/dlopen.3 +++ b/man3/dlopen.3 @@ -528,8 +528,8 @@ $ \fB./a.out\fP .EE .in .SS Program source +\& .EX - #include #include #include diff --git a/man3/duplocale.3 b/man3/duplocale.3 index 8cc87ad97..03dba25d1 100644 --- a/man3/duplocale.3 +++ b/man3/duplocale.3 @@ -134,6 +134,7 @@ ABC .EE .in .SS Program source +\& .EX #define _XOPEN_SOURCE 700 #include diff --git a/man3/ftw.3 b/man3/ftw.3 index eb9c352fd..65bfce625 100644 --- a/man3/ftw.3 +++ b/man3/ftw.3 @@ -426,6 +426,7 @@ control the value assigned to the \fIflags\fP argument when calling .BR nftw (). .SS Program source +\& .EX #define _XOPEN_SOURCE 500 #include diff --git a/man3/get_nprocs.3 b/man3/get_nprocs.3 index 581d6c73e..63c03bac7 100644 --- a/man3/get_nprocs.3 +++ b/man3/get_nprocs.3 @@ -1,2 +1 @@ .so man3/get_nprocs_conf.3 - diff --git a/man3/mbstowcs.3 b/man3/mbstowcs.3 index 4149eec00..6416c8862 100644 --- a/man3/mbstowcs.3 +++ b/man3/mbstowcs.3 @@ -141,6 +141,7 @@ Wide character string is: Grüße! (6 characters) .EE .in .SS Program source +\& .EX #include #include diff --git a/man3/posix_spawn.3 b/man3/posix_spawn.3 index 24ea7e6e3..ab7ffa31a 100644 --- a/man3/posix_spawn.3 +++ b/man3/posix_spawn.3 @@ -643,6 +643,7 @@ Child status: exited, status=127 .EE .in .SS Program source +\& .EX #include #include diff --git a/man3/strftime.3 b/man3/strftime.3 index d078cc4e4..79882afd8 100644 --- a/man3/strftime.3 +++ b/man3/strftime.3 @@ -618,6 +618,7 @@ Result string is " 11" .EE .in .SS Program source +\& .EX #include #include diff --git a/man4/full.4 b/man4/full.4 index 7ed255201..33115974e 100644 --- a/man4/full.4 +++ b/man4/full.4 @@ -31,11 +31,13 @@ If your system does not have .I /dev/full created already, it can be created with the following commands: -.nf - - mknod \-m 666 /dev/full c 1 7 - chown root:root /dev/full -.fi +.PP +.in +4n +.EX +mknod \-m 666 /dev/full c 1 7 +chown root:root /dev/full +.EE +.in .SH DESCRIPTION File .I /dev/full diff --git a/man7/fanotify.7 b/man7/fanotify.7 index ed2175aeb..973e86bc1 100644 --- a/man7/fanotify.7 +++ b/man7/fanotify.7 @@ -559,6 +559,7 @@ Listening for events stopped. .EE .in .SS Program source +\& .EX #define _GNU_SOURCE /* Needed to get O_LARGEFILE definition */ #include diff --git a/man7/inotify.7 b/man7/inotify.7 index 52fdd0298..163b11294 100644 --- a/man7/inotify.7 +++ b/man7/inotify.7 @@ -888,6 +888,7 @@ Listening for events stopped. .EE .in .SS Program source +\& .EX #include #include diff --git a/man7/ip.7 b/man7/ip.7 index 302d26d26..e1a94f148 100644 --- a/man7/ip.7 +++ b/man7/ip.7 @@ -725,8 +725,7 @@ control message contains a structure: .IP .in +4n -.ne 18 -.nf +.EX #define SO_EE_ORIGIN_NONE 0 #define SO_EE_ORIGIN_LOCAL 1 #define SO_EE_ORIGIN_ICMP 2 diff --git a/man7/netdevice.7 b/man7/netdevice.7 index a8f950f02..43b9906b6 100644 --- a/man7/netdevice.7 +++ b/man7/netdevice.7 @@ -116,9 +116,9 @@ T} IFF_LOWER_UP:Driver signals L1 up (since Linux 2.6.17) IFF_DORMANT:Driver signals dormant (since Linux 2.6.17) IFF_ECHO:Echo sent packets (since Linux 2.6.25) - .TE .ad +.PP Setting the active flag word is a privileged operation, but any process may read it. .TP diff --git a/man7/rtld-audit.7 b/man7/rtld-audit.7 index 4d659042d..39b36feee 100644 --- a/man7/rtld-audit.7 +++ b/man7/rtld-audit.7 @@ -355,8 +355,8 @@ depend on the hardware platform. (The appropriate definition is supplied by .IR .) Here is the definition for x86-32: +.PP .nf - .BI "Elf32_Addr la_i86_gnu_pltenter(Elf32_Sym *" sym ", unsigned int " ndx , .BI " uintptr_t *" refcook ", uintptr_t *" defcook , .BI " La_i86_regs *" regs ", unsigned int *" flags , diff --git a/man7/unix.7 b/man7/unix.7 index d4ccc3389..52b6dfed3 100644 --- a/man7/unix.7 +++ b/man7/unix.7 @@ -713,6 +713,7 @@ $ .EE .in .SS Program source +\& .EX /* * File connection.h