OSDN Git Service

LDP: Address fuzzy changes (memory)
authorAkihiro Motoki <amotoki@gmail.com>
Wed, 7 Apr 2021 11:21:28 +0000 (20:21 +0900)
committerAkihiro Motoki <amotoki@gmail.com>
Wed, 7 Apr 2021 11:21:28 +0000 (20:21 +0900)
26 files changed:
manual/LDP_man-pages/draft/man2/alloc_hugepages.2
manual/LDP_man-pages/draft/man2/fallocate.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/memfd_create.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/mlock.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/mprotect.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/msync.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/posix_fadvise.2
manual/LDP_man-pages/draft/man2/readahead.2
manual/LDP_man-pages/draft/man2/remap_file_pages.2
manual/LDP_man-pages/draft/man2/shmctl.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/shmget.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/shmop.2 [new file with mode: 0644]
manual/LDP_man-pages/draft/man2/sync_file_range.2
manual/LDP_man-pages/draft/man3/alloca.3
manual/LDP_man-pages/draft/man3/mallinfo.3
manual/LDP_man-pages/draft/man3/malloc_get_state.3
manual/LDP_man-pages/draft/man3/malloc_hook.3
manual/LDP_man-pages/draft/man3/malloc_info.3
manual/LDP_man-pages/draft/man3/malloc_trim.3
manual/LDP_man-pages/draft/man3/posix_fallocate.3
manual/LDP_man-pages/draft/man3/posix_memalign.3
manual/LDP_man-pages/draft/man3/shm_open.3 [new file with mode: 0644]
manual/LDP_man-pages/draft/man7/shm_overview.7
manual/LDP_man-pages/po4a/memory/po/ja.po
manual/LDP_man-pages/stats/memory
manual/LDP_man-pages/untrans.html

index 5a1a632..88bceba 100644 (file)
@@ -52,11 +52,9 @@ alloc_hugepages, free_hugepages \- 大きなサイズのページの割り当て
 \fBCONFIG_HUGETLB_PAGE\fP を指定してビルドされた場合に) 存在する。 Linux 2.4.20 では syscall
 番号が存在するが、 呼び出すとエラー \fBENOSYS\fP で失敗する。
 .PP
-On i386 the memory management hardware knows about ordinary pages (4\ KiB)
-and huge pages (2 or 4\ MiB).  Similarly ia64 knows about huge pages of
-several sizes.  These system calls serve to map huge pages into the
-process's memory or to free them again.  Huge pages are locked into memory,
-and are not swapped.
+i386 では、メモリー管理ハードウェアは通常のページ (4\ KiB) と 大きなサイズのページ (以下、ヒュージページ; 2MiB または 4\ MiB) を 扱うことができる。 同様に、ia64 もいくつかのサイズのヒュージページを扱うことができる。
+これらのシステムコールは、ヒュージページをプロセスのメモリーにマップしたり、 再び解放したりする。
+ヒュージページはメモリー内にロックされ、スワップされない。
 .PP
 \fIkey\fP 引き数は識別子である。 0 の場合、ページは非公開になり、子プロセスに継承されない。 正の場合、ページは同じ \fIkey\fP
 を使う他のアプリケーションと共有され、子プロセスに継承される。
@@ -84,11 +82,11 @@ and are not swapped.
 .SH ファイル
 .TP 
 \fI/proc/sys/vm/nr_hugepages\fP
-Number of configured hugetlb pages.  This can be read and written.
+設定された hugetlb ページの数。 このファイルは読み書きできる。
 .TP 
 \fI/proc/meminfo\fP
-Gives info on the number of configured hugetlb pages and on their size in
-the three variables HugePages_Total, HugePages_Free, Hugepagesize.
+設定された hugetlb ページの数と、 3 つの変数 HugePages_Total, HugePages_Free, Hugepagesize の
+サイズについての情報を提供する。
 .SH 準拠
 このシステムコールは Intel プロセッサ上の Linux に固有のものであり、 移植性が必要なプログラムで使うべきでない。
 .SH 注意
diff --git a/manual/LDP_man-pages/draft/man2/fallocate.2 b/manual/LDP_man-pages/draft/man2/fallocate.2
new file mode 100644 (file)
index 0000000..c080bcd
--- /dev/null
@@ -0,0 +1,269 @@
+.\" Copyright (c) 2007 Silicon Graphics, Inc. All Rights Reserved
+.\" Written by Dave Chinner <dgc@sgi.com>
+.\"
+.\" %%%LICENSE_START(GPLv2_ONELINE)
+.\" May be distributed as per GNU General Public License version 2.
+.\" %%%LICENSE_END
+.\"
+.\" 2011-09-19: Added FALLOC_FL_PUNCH_HOLE
+.\" 2011-09-19: Substantial restructuring of the page
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 2007  Akihiro MOTOKI
+.\"         all rights reserved.
+.\" Translated 2007-10-16, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v2.66
+.\" Updated 2008-10-13, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v3.11
+.\" Updated 2013-05-01, Akihiro MOTOKI <amotoki@gmail.com>
+.\" Updated 2013-05-07, Akihiro MOTOKI <amotoki@gmail.com>
+.\" Updated 2013-07-22, Akihiro MOTOKI <amotoki@gmail.com>
+.\"
+.TH FALLOCATE 2 2019\-11\-19 Linux "Linux Programmer's Manual"
+.SH 名前
+fallocate \- ファイル空間の操作
+.SH 書式
+.nf
+\fB#define _GNU_SOURCE\fP             /* feature_test_macros(7) 参照 */
+\fB#include <fcntl.h>\fP
+.PP
+\fBint fallocate(int \fP\fIfd\fP\fB, int \fP\fImode\fP\fB, off_t \fP\fIoffset\fP\fB, off_t \fP\fIlen\fP\fB);\fP
+.fi
+.SH 説明
+このシステムコールは、移植性のない、Linux 固有のシステムコールである。 移植性が必要な場合は、ファイルに対してディスク空間を確実に確保するために、
+POSIX.1 で規定された方法である \fBposix_fallocate\fP(3)  を使うこと。
+.PP
+\fBfallocate\fP()  を使うと、 \fIfd\fP が参照するファイルに割り当てられたディスク空間を直接操作できる。 操作対象は、
+\fIoffset\fP から始まる長さ \fIlen\fP バイトの領域である。
+.PP
+\fImode\fP 引き数は、指定された領域に対して実行する操作を指定する。
+サポートされている操作の詳細は以下のサブセクションで説明する。
+.SS ディスク領域の割り当て
+\fBfallocate\fP() のデフォルトの動作 (つまり \fImode\fP が 0 の場合) は、 \fIoffset\fP と \fIlen\fP
+で指定された範囲のディスク領域の割り当てを行う。 \fIoffset\fP+\fIlen\fP がファイルサイズよりも大きかった場合、 (\fBstat\fP(2)
+で報告される) ファイルサイズが変更される。 \fIoffset\fP と \fIlen\fP で指定される範囲のサブ領域で、
+呼び出し前にデータを保持していなかった場合、そのサブ領域は 0 で初期化される。 このデフォルトの動作は、 ライブラリ関数
+\fBposix_fallocate\fP(3) の動作と非常に似ている。 これは、 このシステムコールが \fBposix_fallocate\fP(3)
+を最適に実装する手段を提供することを目的としているからである。
+.PP
+呼び出しが成功した場合、
+\fIoffset\fP と \fIlen\fP で指定された範囲へのそれ以降の書き込みでは、
+ディスクの領域不足での書き込み失敗が起こらないことが保証される。
+.PP
+\fBFALLOC_FL_KEEP_SIZE\fP フラグが \fImode\fP に指定された場合、このシステムコール
+の動作は似ているが、 \fIoffset\fP+\fIlen\fP がファイルサイズよりも大きい場合で
+あってもファイルサイズは変更されない点が異なる。この場合のファイルの末尾
+よりも後ろの前もって割り当てられた 0 で埋められたブロックは、ファイルへの
+追記を最適化したい場合に役に立つ。
+.PP
+If the \fBFALLOC_FL_UNSHARE\fP flag is specified in \fImode\fP, shared file data
+extents will be made private to the file to guarantee that a subsequent
+write will not fail due to lack of space.  Typically, this will be done by
+performing a copy\-on\-write operation on all shared data in the file.  This
+flag may not be supported by all filesystems.
+.PP
+割り当てはブロックサイズ単位で行われるため、 \fBfallocate\fP() は指定されたより
+も大きなディスク領域を割り当てることがある。
+.SS ファイル空間の割り当て解除
+\fBFALLOC_FL_PUNCH_HOLE\fP フラグ (Linux 2.6.38 以降で利用可能) を \fImode\fP に指定すると、
+\fIoffset\fP で始まる \fIlen\fP バイトの領域の空間を解放する (ホールを作成する)。 指定された範囲のうち、
+部分的に使用しているファイルシステムブロックは 0 で埋められ、 全体を使用しているファイルシステムブロックはそのファイルから削除される。
+呼び出しが成功すると、 これ以降のこの範囲からの読み出しでは 0 を返す。
+.PP
+\fBFALLOC_FL_PUNCH_HOLE\fP フラグは \fBFALLOC_FL_KEEP_SIZE\fP と論理和 (OR) をとって \fImode\fP
+に指定しなければならない。 つまり、 ファイル末尾の punch off を行った場合でも、 (\fBstat\fP(2) で報告される)
+ファイルサイズが変化しない。
+.PP
+すべてのファイルシステムで \fBFALLOC_FL_PUNCH_HOLE\fP がサポートされているわけではない。
+ファイルシステムがこの操作をサポートしていない場合は、 エラーが返る。 この操作は少なくとも以下のファイルシステムでサポートされている。
+.IP * 3
+XFS (Linux 2.6.38 以降)
+.IP *
+.\" commit a4bb6b64e39abc0e41ca077725f2a72c868e7622
+ext4 (Linux 3.0 以降)
+.IP *
+Btrfs (Linux 3.7 以降)
+.IP *
+.\" commit 83e4fa9c16e4af7122e31be3eca5d57881d236fe
+\fBtmpfs\fP(5)  (Linux 3.5 以降)
+.IP *
+.\" commit 4e56a6411fbce6f859566e17298114c2434391a4
+\fBgfs2\fP(5)  (Linux 4.16 以降)
+.SS ファイル空間の一部削除
+.\" commit 00f5e61998dd17f5375d9dfc01331f104b83f841
+\fBFALLOC_FL_COLLAPSE_RANGE\fP フラグ (Linux 3.15 以降で利用可能) を \fImode\fP に指定すると、
+指定したバイト範囲をファイルから削除する。 その際、ホールを残さない。 削除されるバイト範囲は \fIoffset\fP から始まる \fIlen\fP
+バイトの範囲である。 操作が完了すると、 ファイルの \fIoffset+len\fP の位置から始まる内容が \fIoffset\fP の位置に見えるようになり、
+ファイルのサイズは \fIlen\fP バイトだけ小さくなる。
+.PP
+効率的に動作する実装にするため、ファイルシステムはこの操作の粒度に制限を設けることがある。 通常は \fIoffset\fP と \fIlen\fP
+はファイルシステムの論理ブロックサイズの倍数でなければならない。 論理ブロックサイズはファイルシステムの種類や設定により様々である。
+ファイルシステムにこのような要求条件がある場合、 その要求条件が満たされていなければ、 \fBfallocate\fP はエラー \fBEINVAL\fP
+で失敗する。
+.PP
+\fIoffset\fP と \fIlen\fP で指定された範囲がファイルの末尾かそれより先まで達している場合、 エラーが返される。
+代わりに、ファイルの切り詰めを行う \fBftruncate\fP(2) を使用すること。
+.PP
+\fBFALLOC_FL_COLLAPSE_RANGE\fP と他のフラグを同時に \fImode\fP に指定することはできない。
+.PP
+.\" commit 9eb79482a97152930b113b51dff530aba9e28c8e
+.\" commit e1d8fb88a64c1f8094b9f6c3b6d2d9e6719c970d
+Linux 3.15 時点では \fBFALLOC_FL_COLLAPSE_RANGE\fP は ext4 (エクステントベースのファイル) と XFS
+でサポートされている。
+.SS ファイル空間のゼロ埋め
+.\" commit 409332b65d3ed8cfa7a8030f1e9d52f372219642
+\fBFALLOC_FL_ZERO_RANGE\fP フラグ (Linux 3.15 以降で利用可能) を \fImode\fP に指定すると、 \fIoffset\fP
+で始まる \fIlen\fP バイト範囲の空間をゼロ埋めする。
+指定された範囲の中では、ブロックは、そのファイル内のホールが広がる領域にあらかじめ割り当てられたものである。 呼び出しが成功すると、
+これ以降のこの範囲からの読み出しでは 0 を返す。
+.PP
+ゼロ埋めは、ファイルシステム内部では、指定された範囲を書き込みを伴わないエクステントに変換する方法をできるだけ使って行われる。
+この方法は、指定された範囲について物理的にゼロ埋めしたデータがデバイスに書き込まれるのではないことを意味する
+(例外は指定された範囲の端の部分的に使用しているブロックである)。 (これ以外で) I/O が必要なのはメタデータの更新だけである。
+.PP
+\fBFALLOC_FL_KEEP_SIZE\fP フラグが \fImode\fP に追加で指定された場合、 このシステムコールの動作は似ているが、
+\fIoffset\fP+\fIlen\fP がファイルサイズよりも大きい場合であってもファイルサイズは変更されない点が異なる。 この動作は
+\fBFALLOC_FL_KEEP_SIZE\fP を指定してスペースを前もって割り当てた場合と同じである。
+.PP
+すべてのファイルシステムで \fBFALLOC_FL_ZERO_RANGE\fP がサポートされているわけではない。
+ファイルシステムがこの操作をサポートしていない場合は、 エラーが返る。 この操作は少なくとも以下のファイルシステムでサポートされている。
+.IP * 3
+.\" commit 376ba313147b4172f3e8cf620b9fb591f3e8cdfa
+XFS (Linux 3.15 以降)
+.IP *
+.\" commit b8a8684502a0fc852afa0056c6bb2a9273f6fcc0
+ext4 のエクステントベースのファイル (Linux 3.15 以降)
+.IP *
+.\" commit 30175628bf7f521e9ee31ac98fa6d6fe7441a556
+SMB3 (Linux 3.17 以降)
+.IP *
+.\" commit f27451f229966874a8793995b8e6b74326d125df
+Btrfs (Linux 4.16 以降)
+.SS "Increasing file space"
+.\" commit dd46c787788d5bf5b974729d43e4c405814a4c7d
+Specifying the \fBFALLOC_FL_INSERT_RANGE\fP flag (available since Linux 4.1)
+in \fImode\fP increases the file space by inserting a hole within the file size
+without overwriting any existing data.  The hole will start at \fIoffset\fP and
+continue for \fIlen\fP bytes.  When inserting the hole inside file, the
+contents of the file starting at \fIoffset\fP will be shifted upward (i.e., to
+a higher file offset) by \fIlen\fP bytes.  Inserting a hole inside a file
+increases the file size by \fIlen\fP bytes.
+.PP
+This mode has the same limitations as \fBFALLOC_FL_COLLAPSE_RANGE\fP regarding
+the granularity of the operation.  If the granularity requirements are not
+met, \fBfallocate\fP()  fails with the error \fBEINVAL\fP.  If the \fIoffset\fP is
+equal to or greater than the end of file, an error is returned.  For such
+operations (i.e., inserting a hole at the end of file), \fBftruncate\fP(2)
+should be used.
+.PP
+\fBFALLOC_FL_INSERT_RANGE\fP と他のフラグを同時に \fImode\fP に指定することはできない。
+.PP
+.\" commit a904b1ca5751faf5ece8600e18cd3b674afcca1b
+.\" commit 331573febb6a224bc50322e3670da326cb7f4cfc
+.\" f2fs also has support since Linux 4.2
+.\"     commit f62185d0e283e9d311e3ac1020f159d95f0aab39
+\fBFALLOC_FL_INSERT_RANGE\fP requires filesystem support.  Filesystems that
+support this operation include XFS (since Linux 4.1)  and ext4 (since Linux
+4.2).
+.SH 返り値
+成功の場合、 \fBfallocate\fP() は 0 を返す。 エラーの場合、\-1 を返し、 \fIerrno\fP にエラーを示す値を設定する。
+.SH エラー
+.TP 
+\fBEBADF\fP
+\fIfd\fP が有効なファイルディスクリプターでないか、 書き込み用としてオープンされていない。
+.TP 
+\fBEFBIG\fP
+\fIoffset + len\fP がファイルサイズの最大値よりも大きい。
+.TP 
+\fBEFBIG\fP
+\fImode\fP is \fBFALLOC_FL_INSERT_RANGE\fP, and the current file size+\fIlen\fP
+exceeds the maximum file size.
+.TP 
+\fBEINTR\fP
+実行中にシグナルが捕捉された。 \fBsignal\fP(7) 参照。
+.TP 
+\fBEINVAL\fP
+.\" FIXME . (raise a kernel bug) Probably the len==0 case should be
+.\" a no-op, rather than an error. That would be consistent with
+.\" similar APIs for the len==0 case.
+.\" See "Re: [PATCH] fallocate.2: add FALLOC_FL_PUNCH_HOLE flag definition"
+.\" 21 Sep 2012
+.\" http://thread.gmane.org/gmane.linux.file-systems/48331/focus=1193526
+\fIoffset\fP が 0 未満だったか、 \fIlen\fP が 0 以下だった。
+.TP 
+\fBEINVAL\fP
+\fImode\fP が \fBFALLOC_FL_COLLAPSE_RANGE\fP で、 \fIoffset\fP と \fIlen\fP
+で指定された範囲がファイルの末尾かそれより先まで達している。
+.TP 
+\fBEINVAL\fP
+\fImode\fP が \fBFALLOC_FL_INSERT_RANGE\fP で、 \fIoffset\fP と \fIlen\fP
+で指定された範囲がファイルの末尾かそれより先まで達している。
+.TP 
+\fBEINVAL\fP
+\fImode\fP が \fBFALLOC_FL_COLLAPSE_RANGE\fP か \fBFALLOC_FL_INSERT_RANGE\fP だが、
+\fIoffset\fP か \fIlen\fP のいずれかがファイルシステムのブロックサイズの倍数ではない。
+.TP 
+\fBEINVAL\fP
+\fImode\fP contains one of \fBFALLOC_FL_COLLAPSE_RANGE\fP or
+\fBFALLOC_FL_INSERT_RANGE\fP and also other flags; no other flags are permitted
+with \fBFALLOC_FL_COLLAPSE_RANGE\fP or \fBFALLOC_FL_INSERT_RANGE\fP.
+.TP 
+\fBEINVAL\fP
+.\" There was an inconsistency in 3.15-rc1, that should be resolved so that all
+.\" filesystems use this error for this case. (Tytso says ex4 will change.)
+.\" http://thread.gmane.org/gmane.comp.file-systems.xfs.general/60485/focus=5521
+.\" From: Michael Kerrisk (man-pages <mtk.manpages@...>
+.\" Subject: Re: [PATCH v5 10/10] manpage: update FALLOC_FL_COLLAPSE_RANGE flag in fallocate
+.\" Newsgroups: gmane.linux.man, gmane.linux.file-systems
+.\" Date: 2014-04-17 13:40:05 GMT
+\fImode\fP が \fBFALLOC_FL_COLLAPSE_RANGE\fP か \fBFALLOC_FL_ZERO_RANGE\fP か
+\fBFALLOC_FL_INSERT_RANGE\fP だが、 \fIfd\fP が参照しているファイルが通常のファイルではない。
+.TP 
+\fBEIO\fP
+ファイルシステムとの読み書き中に入出力エラーが発生した。
+.TP 
+\fBENODEV\fP
+\fIfd\fP が通常のファイルかディレクトリを参照していない (\fIfd\fP がパイプや FIFO を参照している場合、別のエラーが発生する)。
+.TP 
+\fBENOSPC\fP
+\fIfd\fP が参照するファイルを含むデバイスに十分な空き領域がない。
+.TP 
+\fBENOSYS\fP
+このカーネルでは \fBfallocate\fP() は実装されていない。
+.TP 
+\fBEOPNOTSUPP\fP
+\fIfd\fP が参照するファイルを含むファイルシステムが 指定された操作を
+サポートしていない。 \fIfd\fP が参照するファイルを含むファイルシステムが
+\fImode\fP をサポートしていない。
+.TP 
+\fBEPERM\fP
+\fIfd\fP が参照するファイルに変更不可 (immutable) の属性が付いている (\fBchattr\fP(1) 参照)。
+.TP 
+\fBEPERM\fP
+\fImode\fP に \fBFALLOC_FL_PUNCH_HOLE\fP か \fBFALLOC_FL_COLLAPSE_RANGE\fP か
+\fBFALLOC_FL_INSERT_RANGE\fP が指定されたが、 \fIfd\fP が参照するファイルに追加のみ (append\-only)
+の属性が付いている (\fBchattr\fP(1) 参照)。
+.TP 
+\fBEPERM\fP
+操作が file seal により禁止されている。 \fBfcntl\fP(2) 参照。
+.TP 
+\fBESPIPE\fP
+\fIfd\fP がパイプか FIFO を参照している。
+.TP 
+\fBETXTBSY\fP
+\fImode\fP に \fBFALLOC_FL_COLLAPSE_RANGE\fP か \fBFALLOC_FL_INSERT_RANGE\fP が指定されたが、
+\fIfd\fP が参照するファイルは現在実行中である。
+.SH バージョン
+.\" See http://sourceware.org/bugzilla/show_bug.cgi?id=14964
+\fBfallocate\fP()  はカーネル 2.6.23 以降の Linux で利用可能である。 glibc での対応はバージョン 3.10
+以降で行われている。 \fBFALLOC_FL_*\fP が glibc のヘッダーファイルで定義されているのは、バージョン 2.18 以降のみである。
+.SH 準拠
+\fBfallocate\fP()  は Linux 固有である。
+.SH 関連項目
+\fBfallocate\fP(1), \fBftruncate\fP(2), \fBposix_fadvise\fP(3), \fBposix_fallocate\fP(3)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
diff --git a/manual/LDP_man-pages/draft/man2/memfd_create.2 b/manual/LDP_man-pages/draft/man2/memfd_create.2
new file mode 100644 (file)
index 0000000..2f9d852
--- /dev/null
@@ -0,0 +1,371 @@
+.\" Copyright (C) 2014 Michael Kerrisk <mtk.manpages@gmail.com>
+.\" and Copyright (C) 2014 David Herrmann <dh.herrmann@gmail.com>
+.\"
+.\" %%%LICENSE_START(GPLv2+)
+.\"
+.\" This program is free software; you can redistribute it and/or modify
+.\" it under the terms of the GNU General Public License as published by
+.\" the Free Software Foundation; either version 2 of the License, or
+.\" (at your option) any later version.
+.\"
+.\" This program is distributed in the hope that it will be useful,
+.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
+.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+.\" GNU General Public License for more details.
+.\"
+.\" You should have received a copy of the GNU General Public
+.\" License along with this manual; if not, see
+.\" <http://www.gnu.org/licenses/>.
+.\" %%%LICENSE_END
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.TH MEMFD_CREATE 2 2020\-11\-01 Linux "Linux Programmer's Manual"
+.SH 名前
+memfd_create \- 無名ファイル (anonymous file) を作成する
+.SH 書式
+.nf
+\fB#define _GNU_SOURCE\fP         /* feature_test_macros(7) 参照 */
+\fB#include <sys/mman.h>\fP
+.PP
+\fBint memfd_create(const char *\fP\fIname\fP\fB, unsigned int \fP\fIflags\fP\fB);\fP
+.fi
+.SH 説明
+.\" David Herrmann:
+.\"     memfd uses VM_NORESERVE so each page is accounted on first access.
+.\"     This means, the overcommit-limits (see __vm_enough_memory()) and the
+.\"     memory-cgroup limits (mem_cgroup_try_charge()) are applied. Note that
+.\"     those are accounted on "current" and "current->mm", that is, the
+.\"     process doing the first page access.
+\fBmemfd_create\fP() は、 無名ファイル (anonymous file) を作成し、
+そのファイルを参照するファイルディスクリプターを返す。 このファイルは通常のファイルと同様に振る舞い、 変更、切り詰め (truncate)、
+メモリーマップなどを行うことができる。 しかし、 通常のファイルとは違い、 このファイルは RAM 上に置かれ、 格納されるストレージは揮発性である。
+このファイルへの参照がすべてなくなると、 ファイルは自動的に解放される。 このファイルが置かれるページには無名メモリー (anonymous
+memory) が使用される。 したがって、 \fBmemfd_create\fP() で作成されたフィアルは、 他の無名メモリーの割り当て
+(\fBMAP_ANONYMOUS\fP フラグ付きの \fBmmap\fP(2) を使って割り当てられた無名メモリーなど) と同じ動作をする。
+.PP
+ファイルの初期サイズは 0 に設定される。 呼び出しの後に、 \fBftruncate\fP(2) を使ってファイルサイズを設定すべきである (代わりに、
+\fBwrite\fP(2) や同様の関数を呼び出してファイルにデータを書き込むこともできる)。
+.PP
+\fIname\fP に指定された名前はファイル名として使用され、 ディレクトリ \fI/proc/self/fd/\fP
+で対応するシンボリックリンクのリンク先として表示される。 表示される名前の前には常に \fImemfd:\fP が付き、
+この名前はデバッグ用途としてのみ機能する。 名前はファイルディスクリプターの動作には影響せず、 複数のファイルが同じ名前を持っても副作用はない。
+.PP
+以下の値をビット論理和で \fIflags\fP に指定して、 \fBmemfd_create\fP() の動作を変更できる。
+.TP 
+\fBMFD_CLOEXEC\fP
+新しいファイルディスクリプターに close\-on\-exec (\fBFD_CLOEXEC\fP) フラグをセットする。 これが有用な理由については
+\fBopen\fP(2) の \fBO_CLOEXEC\fP フラグの説明を参照のこと。
+.TP 
+\fBMFD_ALLOW_SEALING\fP
+.\" FIXME Why is the MFD_ALLOW_SEALING behavior not simply the default?
+.\" Is it worth adding some text explaining this?
+このファイルに対して sealing 操作を許可する。 \fBfcntl\fP(2) の \fBF_ADD_SEALS\fP と \fBF_GET_SEALS\fP
+操作の議論を参照。 下記の「注意」も参照。 初期の seal 集合は空となる。 このフラグを指定しなかった場合、 初期の seal 集合は
+\fBF_SEAL_SEAL\fP となり、 これはこのファイルには他の seal をセットできないことということである。
+.TP 
+\fBMFD_HUGETLB\fP (Linux 4.14 以降)
+.\" commit 749df87bd7bee5a79cef073f5d032ddb2b211de8
+.\" commit 47b9012ecdc747f6936395265e677d41e11a31ff
+The anonymous file will be created in the hugetlbfs filesystem using huge
+pages.  See the Linux kernel source file
+\fIDocumentation/admin\-guide/mm/hugetlbpage.rst\fP for more information about
+hugetlbfs.  Specifying both \fBMFD_HUGETLB\fP and \fBMFD_ALLOW_SEALING\fP in
+\fIflags\fP is supported since Linux 4.16.
+.TP 
+\fBMFD_HUGE_2MB\fP, \fBMFD_HUGE_1GB\fP, \fB...\fP
+Used in conjunction with \fBMFD_HUGETLB\fP to select alternative hugetlb page
+sizes (respectively, 2\ MB, 1\ GB, ...)  on systems that support multiple
+hugetlb page sizes.  Definitions for known huge page sizes are included in
+the header file \fI<linux/memfd.h>.\fP
+.IP
+For details on encoding huge page sizes not included in the header file, see
+the discussion of the similarly named constants in \fBmmap\fP(2).
+.PP
+\fIflags\fP の未使用のビットは 0 でなければならない。
+.PP
+返り値として \fBmemfd_create\fP() は、 作成したファイルを参照するのに使用できる新しいファイルディスクリプターを返す。
+このファイルディスクリプターは読み書き両用 (\fBO_RDWR\fP) でオープンされ、 \fBO_LARGEFILE\fP
+がこのファイルディスクリプターにセットされる。
+.PP
+\fBfork\fP(2) と \fBexecve\fP(2) に関しては、 \fBmemfd_create\fP()
+で作成したファイルディスクリプターについても通常の動作が適用される。 ファイルディスクリプターのコピーは \fBfork\fP(2)
+で生成される子プロセスに継承され、 同じファイルを参照する。 close\-on\-exec フラグがセットされていない限り、 \fBexecve\fP(2)
+の前後でファイルディスクリプターは保持される。
+.SH 返り値
+成功の場合、 \fBmemfd_create\fP() は新しいファイルディスクリプターを返す。 エラーの場合、\-1 を返し、 \fIerrno\fP
+にエラーを示す値を設定する。
+.SH エラー
+.TP 
+\fBEFAULT\fP
+\fIname\fP のアドレスが無効なメモリーを指している。
+.TP 
+\fBEINVAL\fP
+\fIflags\fP included unknown bits.
+.TP 
+\fBEINVAL\fP
+.\" NAME_MAX - strlen("memfd:")
+\fIname\fP was too long.  (The limit is 249 bytes, excluding the terminating
+null byte.)
+.TP 
+\fBEINVAL\fP
+Both \fBMFD_HUGETLB\fP and \fBMFD_ALLOW_SEALING\fP were specified in \fIflags\fP.
+.TP 
+\fBEMFILE\fP
+オープンされているファイルディスクリプター数のプロセス単位の上限に達した。
+.TP 
+\fBENFILE\fP
+システム全体でオープンされているファイルの総数が上限に達した。
+.TP 
+\fBENOMEM\fP
+新しい無名ファイルを作成するのに十分なメモリーがなかった。
+.SH バージョン
+\fBmemfd_create\fP() システムコールは Linux 3.17 で登場した。 glibc でのサポートは glibc バージョン 2.27
+で追加された。
+.SH 準拠
+\fBmemfd_create\fP()  システムコールは Linux 固有である。
+.SH 注意
+.\" See also http://lwn.net/Articles/593918/
+.\" and http://lwn.net/Articles/594919/ and http://lwn.net/Articles/591108/
+\fBmemfd_create\fP() システムコールは、 手動で \fBtmpfs\fP(5) ファイルシステムをマウントして、
+そのファイルシステムにファイルをオープンするという操作の、 簡単な代替手段を提供している。 \fBmemfd_create\fP() の主な目的は、
+\fBfcntl\fP(2) が提供する file\-sealing API で使用できる、
+ファイルとそれに関連付けられるファイルディスクリプターを作成することである。
+.PP
+\fBmemfd_create\fP() システムコールは、 file sealing なしでも用途がある (これが明示的に
+\fBMFD_ALLOW_SEALING\fP フラグが要求されない限り、 file\-sealing が無効になる理由である)。 特に、
+ファイルシステムに実際にファイルを残す意図がない場合、 \fItmp\fP にファイルを作成したり \fBopen\fP(2) \fBO_TMPFILE\fP
+を使ったりする際の代替手段として使用できる。
+.SS "file sealing"
+file sealing がない場合、 共有メモリー経由で通信するプロセスは、 互いに信頼するか、
+信頼していない相手が共有メモリー領域を問題がある方法で操作する可能性に対処するための対策を講じなければならない。
+例えば、 信頼していない相手は、 いつでも共有メモリーの内容を変更したり、 共有メモリー領域を縮小したりする可能性がある。 前者の場合は、
+ローカルプロセスでは、 データの確認時点と使用時点の競合条件の問題が起こり得る
+(通常はこの問題への対処は共有メモリー領域からデータをこぴーしてからデータを確認、使用することである)。 後者の場合は、 ローカルプロセスでは、
+共有メモリー領域の存在しなくなった場所にアクセスしようとした際にシグナル \fBSIGBUS\fP が発生する可能性がある (この可能性に対処するにはシグナル
+\fBSIGBUS\fP に対してハンドラーを使用する必要がある)。
+.PP
+信頼していない相手への対処により、 共有メモリーを利用するコードに余計な複雑性が増すことになる。 メモリー sealing
+により余計な複雑性をなくすことができる。 相手が望まない方法で共有メモリーを変更できないことを知っていることで、 プロセスは安全に動作できるようになる。
+.PP
+sealing 機構の使い方の例は以下のとおりである。
+.IP 1. 3
+最初のプロセスは \fBmemfd_create\fP() を使って \fBtmpfs\fP(5) ファイルを作成する。 \fBmemfd_create\fP()
+はこれ以降のステップで使用するファイルディスクリプターを返す。
+.IP 2.
+最初のプロセスは \fBftruncate\fP(2) を使って直前のステップで作成したファイルのサイズを変更し、 \fBmmap\fP(2)
+を使ってそのファイルをマッピングし、 共有メモリーに所望のデータを配置する。
+.IP 3.
+The first process uses the \fBfcntl\fP(2)  \fBF_ADD_SEALS\fP operation to place
+one or more seals on the file, in order to restrict further modifications on
+the file.  (If placing the seal \fBF_SEAL_WRITE\fP, then it will be necessary
+to first unmap the shared writable mapping created in the previous step.
+Otherwise, behavior similar to \fBF_SEAL_WRITE\fP can be achieved by using
+\fBF_SEAL_FUTURE_WRITE\fP, which will prevent future writes via \fBmmap\fP(2)  and
+\fBwrite\fP(2)  from succeeding while keeping existing shared writable
+mappings).
+.IP 4.
+二つ目のプロセスは \fBtmpfs\fP(5) ファイルのファイルディスクリプターを入手し、 そのファイルをマップする。
+以下に示す方法を使用することができる。
+.RS
+.IP * 3
+\fBmemfd_create\fP() を呼び出したプロセスは、 得られたファイルディスクリプターを二つ目のプロセスに UNIX
+ドメインソケット経由で渡すことができる (\fBunix\fP(7) と \fBcmsg\fP(3) を参照)。 それから、二つ目のプロセスは \fBmmap\fP(2)
+を使ってファイルをマップする。
+.IP *
+二つ目のプロセスを \fBfork\fP(2) を使って作成する。 そうすると、 自動的にファイルディスクリプターとマッピングが継承される。
+(この方法と次の方法では、 二つのプロセス間で自然な信頼関係が存在することになる。 なぜなら、 二つのプロセスは同じユーザー ID。
+の元で実行されているからである。 したがって、 file sealing は通常は不要であろう。)
+.IP *
+二つ目のプロセスは \fI/proc/<pid>/fd/<fd>\fP をオープンする。 \fI<pid>\fP
+は最初のプロセス (\fBmemfd_create\fP() を呼び出したプロセス) の PID で、 \fI<fd>\fP は最初のプロセスでの
+\fBmemfd_create\fP() の呼び出しで返されたファイルディスクリプター番号である。 それからこのファイルを \fBmmap\fP(2)
+を使ってマッピングする。
+.RE
+.IP 5.
+二つ目のプロセスは \fBfcntl\fP(2) の \fBF_GET_SEALS\fP 操作を使って、 そのファイルに適用されている seal
+のビットマスクを取得する。 このビットマスクを調べて、 ファイルの変更に関してどのような制限が適用されているかを知ることができる。
+(\fBF_SEAL_SEAL\fP seal がそれまでに適用されていない限りは) 必要であれば、 二つ目のプロセスはさらに seal
+を設定して追加の制限をかけることができる。
+.SH 例
+以下では \fBmemfd_create\fP() と file sealing API の使用例を示すサンプルプログラムを 2 つとりあげる。
+.PP
+最初のプログラム \fIt_memfd_create.c\fP は、 \fBmemfd_create\fP() を使って \fBtmpfs\fP(5) ファイルを作成し、
+そのファイルのサイズを設定し、 メモリーにマッピングし、 要求された場合にはそのファイルに seal を設定する。 このプログラムは最大で 3
+つのコマンドライン引き数を取り、 最初の 2 つは必須である。 最初の引き数はファイルに関連付けられる名前で、 2
+番目の引き数はファイルに設定されるサイズである。 省略可能な 3 番目の引き数は、 このファイルに設定する seal を指定する文字列である。
+.PP
+2 つめのプログラム \fIt_get_seals.c\fP を使うと、 \fBmemfd_create\fP() を使って作成された既存のファイルをオープンし、
+そのファイルに適用されている seal の集合を調査できる。
+.PP
+以下のシェルのセッションはこれらのプログラムの使用例を示したものである。 まず \fBtmpfs\fP(5) ファイルを作成し、そのファイルに seal
+をいくつか設定している。
+.PP
+.in +4n
+.EX
+$ \fB./t_memfd_create my_memfd_file 4096 sw &\fP
+[1] 11775
+PID: 11775; fd: 3; /proc/11775/fd/3
+.EE
+.in
+.PP
+この時点では、 \fIt_memfd_create\fP プログラムはバックグラウンドで動作し続ける。 もう一つのプログラムから、
+\fBmemfd_create\fP() がオープンしたファイルディスクリプターに対応する \fI/proc/[pid]/fd\fP ファイルをオープンすることで、
+\fBmemfd_create\fP() で作成されたファイルのファイルディスクリプターを取得できる。そのパス名を使って、 \fI/proc/[pid]/fd\fP
+シンボリックリンクの内容を調査し、 \fIt_get_seals\fP プログラムを使ってそのファイルに設定されている seal を見ることができる。
+.PP
+.in +4n
+.EX
+$ \fBreadlink /proc/11775/fd/3\fP
+/memfd:my_memfd_file (deleted)
+$ \fB./t_get_seals /proc/11775/fd/3\fP
+Existing seals: WRITE SHRINK
+.EE
+.in
+.SS "プログラムのソース: t_memfd_create.c"
+\&
+.EX
+#define _GNU_SOURCE
+#include <stdint.h>
+#include <sys/mman.h>
+#include <fcntl.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include <string.h>
+#include <stdio.h>
+
+#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \e
+                        } while (0)
+
+int
+main(int argc, char *argv[])
+{
+    int fd;
+    unsigned int seals;
+    char *addr;
+    char *name, *seals_arg;
+    ssize_t len;
+
+    if (argc < 3) {
+        fprintf(stderr, "%s name size [seals]\en", argv[0]);
+        fprintf(stderr, "\et\(aqseals\(aq can contain any of the "
+                "following characters:\en");
+        fprintf(stderr, "\et\etg \- F_SEAL_GROW\en");
+        fprintf(stderr, "\et\ets \- F_SEAL_SHRINK\en");
+        fprintf(stderr, "\et\etw \- F_SEAL_WRITE\en");
+        fprintf(stderr, "\et\etW \- F_SEAL_FUTURE_WRITE\en");
+        fprintf(stderr, "\et\etS \- F_SEAL_SEAL\en");
+        exit(EXIT_FAILURE);
+    }
+
+    name = argv[1];
+    len = atoi(argv[2]);
+    seals_arg = argv[3];
+
+    /* Create an anonymous file in tmpfs; allow seals to be
+       placed on the file */
+
+    fd = memfd_create(name, MFD_ALLOW_SEALING);
+    if (fd == \-1)
+        errExit("memfd_create");
+
+    /* Size the file as specified on the command line */
+
+    if (ftruncate(fd, len) == \-1)
+        errExit("truncate");
+
+    printf("PID: %jd; fd: %d; /proc/%jd/fd/%d\en",
+            (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);
+
+    /* Code to map the file and populate the mapping with data
+       omitted */
+
+    /* If a \(aqseals\(aq command\-line argument was supplied, set some
+       seals on the file */
+
+    if (seals_arg != NULL) {
+        seals = 0;
+
+        if (strchr(seals_arg, \(aqg\(aq) != NULL)
+            seals |= F_SEAL_GROW;
+        if (strchr(seals_arg, \(aqs\(aq) != NULL)
+            seals |= F_SEAL_SHRINK;
+        if (strchr(seals_arg, \(aqw\(aq) != NULL)
+            seals |= F_SEAL_WRITE;
+        if (strchr(seals_arg, \(aqW\(aq) != NULL)
+            seals |= F_SEAL_FUTURE_WRITE;
+        if (strchr(seals_arg, \(aqS\(aq) != NULL)
+            seals |= F_SEAL_SEAL;
+
+        if (fcntl(fd, F_ADD_SEALS, seals) == \-1)
+            errExit("fcntl");
+    }
+
+    /* Keep running, so that the file created by memfd_create()
+       continues to exist */
+
+    pause();
+
+    exit(EXIT_SUCCESS);
+}
+.EE
+.SS "プログラムのソース: t_get_seals.c"
+\&
+.EX
+#define _GNU_SOURCE
+#include <sys/mman.h>
+#include <fcntl.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <string.h>
+#include <stdio.h>
+
+#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \e
+                        } while (0)
+
+int
+main(int argc, char *argv[])
+{
+    int fd;
+    unsigned int seals;
+
+    if (argc != 2) {
+        fprintf(stderr, "%s /proc/PID/fd/FD\en", argv[0]);
+        exit(EXIT_FAILURE);
+    }
+
+    fd = open(argv[1], O_RDWR);
+    if (fd == \-1)
+        errExit("open");
+
+    seals = fcntl(fd, F_GET_SEALS);
+    if (seals == \-1)
+        errExit("fcntl");
+
+    printf("Existing seals:");
+    if (seals & F_SEAL_SEAL)
+        printf(" SEAL");
+    if (seals & F_SEAL_GROW)
+        printf(" GROW");
+    if (seals & F_SEAL_WRITE)
+        printf(" WRITE");
+    if (seals & F_SEAL_FUTURE_WRITE)
+        printf(" FUTURE_WRITE");
+    if (seals & F_SEAL_SHRINK)
+        printf(" SHRINK");
+    printf("\en");
+
+    /* Code to map the file and access the contents of the
+       resulting mapping omitted */
+
+    exit(EXIT_SUCCESS);
+}
+.EE
+.SH 関連項目
+\fBfcntl\fP(2), \fBftruncate\fP(2), \fBmmap\fP(2), \fBshmget\fP(2), \fBshm_open\fP(3)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
diff --git a/manual/LDP_man-pages/draft/man2/mlock.2 b/manual/LDP_man-pages/draft/man2/mlock.2
new file mode 100644 (file)
index 0000000..6461ebe
--- /dev/null
@@ -0,0 +1,289 @@
+.\" Copyright (C) Michael Kerrisk, 2004
+.\"    using some material drawn from earlier man pages
+.\"    written by Thomas Kuhn, Copyright 1996
+.\"
+.\" %%%LICENSE_START(GPLv2+_DOC_FULL)
+.\" This is free documentation; you can redistribute it and/or
+.\" modify it under the terms of the GNU General Public License as
+.\" published by the Free Software Foundation; either version 2 of
+.\" the License, or (at your option) any later version.
+.\"
+.\" The GNU General Public License's references to "object code"
+.\" and "executables" are to be interpreted as the output of any
+.\" document formatting or typesetting system, including
+.\" intermediate and printed output.
+.\"
+.\" This manual is distributed in the hope that it will be useful,
+.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
+.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+.\" GNU General Public License for more details.
+.\"
+.\" You should have received a copy of the GNU General Public
+.\" License along with this manual; if not, see
+.\" <http://www.gnu.org/licenses/>.
+.\" %%%LICENSE_END
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
+.\"         all rights reserved.
+.\" Translated 1997-02-23, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
+.\" Updated 2003-10-12, Kentaro Shirakata <argrath@ub32.org>
+.\" Updated 2004-05-23, kentaro Shirakata <argrath@ub32.org>
+.\" Updated 2005-03-29, kentaro Shirakata <argrath@ub32.org>
+.\" Updated 2005-11-04, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
+.\" Updated 2006-02-14, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
+.\" Updated 2008-11-10, Akihiro MOTOKI, LDP v3.13
+.\" Updated 2012-05-01, Akihiro MOTOKI <amotoki@gmail.com>
+.\" Updated 2013-03-26, Akihiro MOTOKI <amotoki@gmail.com>
+.\"
+.TH MLOCK 2 2020\-04\-11 Linux "Linux Programmer's Manual"
+.SH 名前
+mlock, mlock2, munlock, mlockall, munlockall \- メモリーのロックとロック解除を行う
+.SH 書式
+.nf
+\fB#include <sys/mman.h>\fP
+.PP
+\fBint mlock(const void *\fP\fIaddr\fP\fB, size_t \fP\fIlen\fP\fB);\fP
+\fBint mlock2(const void *\fP\fIaddr\fP\fB, size_t \fP\fIlen\fP\fB, int \fP\fIflags\fP\fB);\fP
+\fBint munlock(const void *\fP\fIaddr\fP\fB, size_t \fP\fIlen\fP\fB);\fP
+.PP
+\fBint mlockall(int \fP\fIflags\fP\fB);\fP
+\fBint munlockall(void);\fP
+.fi
+.SH 説明
+\fBmlock\fP() と \fBmlockall\fP() は、呼び出し元プロセスの仮想アドレス空間の一部または全部を RAM
+上にロックし、メモリーがスワップエリアにページングされるのを防ぐ。
+.PP
+\fBmunlock\fP()  と \fBmunlockall\fP()  は逆の操作で、それぞれ呼び出し元プロセスの仮想アドレス空間の一部または全部を
+ロック解除する。つまり、指定された仮想アドレス範囲のページは カーネルメモリーマネージャーから要求されればスワップアウトするようになる。
+メモリーのロックとロック解除はページ単位で行われる。
+.PP
+メモリーのロックとロック解除はページ単位で行われる。
+.SS "mlock(), mlock2(), munlock()"
+\fBmlock\fP()  は \fIaddr\fP から始まる長さ \fIlen\fP バイトのアドレス範囲のページをロックする。 呼び出しが成功した場合には、
+指定されたアドレス範囲を含む全てのページは RAM に残り続けることが保証される。 これらのページは後でロック解除されるまで RAM
+に残り続けることが保証される。
+.PP
+.\" commit a8ca5d0ecbdde5cc3d7accacbd69968b0c98764e
+.\" commit de60f5f10c58d4f34b68622442c0e04180367f3f
+.\" commit b0f205c2a3082dd9081f9a94e50658c5fa906ff1
+\fBmlock2\fP()  also locks pages in the specified range starting at \fIaddr\fP and
+continuing for \fIlen\fP bytes.  However, the state of the pages contained in
+that range after the call returns successfully will depend on the value in
+the \fIflags\fP argument.
+.PP
+The \fIflags\fP argument can be either 0 or the following constant:
+.TP 
+\fBMLOCK_ONFAULT\fP
+Lock pages that are currently resident and mark the entire range so that the
+remaining nonresident pages are locked when they are populated by a page
+fault.
+.PP
+If \fIflags\fP is 0, \fBmlock2\fP()  behaves exactly the same as \fBmlock\fP().
+.PP
+\fBmunlock\fP()  は、 \fIaddr\fP から始まる長さ \fIlen\fP バイトのアドレス範囲のページのロックを解除する。
+この呼び出しを行った後は、カーネルが、指定されたメモリー範囲を含む 全てのページを外部のスワップ空間に移動できるようになる。
+.SS "mlockall() と munlockall()"
+\fBmlockall\fP()  は呼び出し元プロセスのアドレス空間にマップされている全てのページを ロックする。これにはコード、データ、スタックの
+各セグメント、共有ライブラリ、カーネルのユーザー空間データ、 共有メモリー、メモリーマップされたファイルが含まれる。
+システムコールが成功した場合には全てのマップされたページは RAM に 残ることを保証される。 これらのページは後でロック解除されるまで RAM
+に残り続けることが保証される。
+.PP
+\fIflags\fP 引数は以下の内容の一つまたは複数のビット OR から構成される:
+.TP 
+\fBMCL_CURRENT\fP
+現在、プロセスのアドレス空間にマップされている全てのページをロックする。
+.TP 
+\fBMCL_FUTURE\fP
+将来、プロセスのアドレス空間にマップされる全てのページをロックする。 例えば、ヒープ (heap) やスタックの成長により新しく必要になったページだけで
+なく、新しくメモリーマップされたファイルや共有メモリー領域もロックされる。
+.TP 
+\fBMCL_ONFAULT\fP (Linux 4.4 以降)
+Used together with \fBMCL_CURRENT\fP, \fBMCL_FUTURE\fP, or both.  Mark all current
+(with \fBMCL_CURRENT\fP)  or future (with \fBMCL_FUTURE\fP)  mappings to lock
+pages when they are faulted in.  When used with \fBMCL_CURRENT\fP, all present
+pages are locked, but \fBmlockall\fP()  will not fault in non\-present pages.
+When used with \fBMCL_FUTURE\fP, all future mappings will be marked to lock
+pages when they are faulted in, but they will not be populated by the lock
+when the mapping is created.  \fBMCL_ONFAULT\fP must be used with either
+\fBMCL_CURRENT\fP or \fBMCL_FUTURE\fP or both.
+.PP
+\fBMCL_FUTURE\fP が指定されていると、以後のシステムコール (例えば、 \fBmmap\fP(2), \fBsbrk\fP(2),
+\fBmalloc\fP(3))  は、ロックするバイト数が許可された最大値 (下記参照) を超えた場合に 失敗する可能性がある。
+同様に、スタックの成長も失敗する可能性がある。 その場合、カーネルはスタックの拡張を拒否し、 \fBSIGSEGV\fP をプロセスに送る。
+.PP
+\fBmunlockall\fP()  は、呼び出し元プロセスのアドレス空間にマッピングされている 全てのページをロック解除する。
+.SH 返り値
+成功した場合は、これらのシステムコールはゼロを返す。 エラーの場合は \-1 が返され、 \fIerrno\fP
+が適切に設定され、プロセスのアドレス空間におけるロックは変更されない。
+.SH エラー
+.TP 
+\fBENOMEM\fP
+(Linux 2.6.9 以降) 呼び出し元は非ゼロの ソフト資源制限 \fBRLIMIT_MEMLOCK\fP
+を持つが、制限が許可している以上のメモリーをロックしようとした。 この制限は、プロセスが特権 (\fBCAP_IPC_LOCK\fP)
+を持っている場合は適用されない。
+.TP 
+\fBENOMEM\fP
+.\" In the case of mlock(), this check is somewhat buggy: it doesn't
+.\" take into account whether the to-be-locked range overlaps with
+.\" already locked pages.  Thus, suppose we allocate
+.\" (num_physpages / 4 + 1) of memory, and lock those pages once using
+.\" mlock(), and then lock the *same* page range a second time.
+.\" In the case, the second mlock() call will fail, since the check
+.\" calculates that the process is trying to lock (num_physpages / 2 + 2)
+.\" pages, which of course is not true.  (MTK, Nov 04, kernel 2.4.28)
+(Linux 2.4 以前) 呼び出し元プロセスが RAM の半分以上をロックしようとした。
+.TP 
+\fBEPERM\fP
+.\"SVr4 documents an additional EAGAIN error code.
+呼び出し側が特権を持っていないが、
+要求された操作を実行するには特権 (\fBCAP_IPC_LOCK\fP) が必要である。
+.PP
+For \fBmlock\fP(), \fBmlock2\fP(), and \fBmunlock\fP():
+.TP 
+\fBEAGAIN\fP
+指定されたアドレス範囲の一部または全てをロックすることができなかった。
+.TP 
+\fBEINVAL\fP
+\fIaddr\fP+\fIlen\fP の加算の結果が \fIaddr\fP よりも小さかった (例えば、加算でオーバーフローが発生したなど)。
+.TP 
+\fBEINVAL\fP
+(Linux ではこの意味で使われない)  \fIaddr\fP がページサイズの倍数ではない。
+.TP 
+\fBENOMEM\fP
+指定されたアドレス範囲がプロセスのアドレス空間にマップされたページと 一致しない。
+.TP 
+\fBENOMEM\fP
+.\" I.e., the number of VMAs would exceed the 64kB maximum
+Locking or unlocking a region would result in the total number of mappings
+with distinct attributes (e.g., locked versus unlocked)  exceeding the
+allowed maximum.  (For example, unlocking a range in the middle of a
+currently locked mapping would result in three mappings: two locked mappings
+at each end and an unlocked mapping in the middle.)
+.PP
+For \fBmlock2\fP():
+.TP 
+\fBEINVAL\fP
+未知の \fIflags\fP が指定された。
+.PP
+\fBmlockall\fP()  用として:
+.TP 
+\fBEINVAL\fP
+Unknown \fIflags\fP were specified or \fBMCL_ONFAULT\fP was specified without
+either \fBMCL_FUTURE\fP or \fBMCL_CURRENT\fP.
+.PP
+\fBmunlockall\fP()  用として:
+.TP 
+\fBEPERM\fP
+(Linux 2.6.8 以前) 呼び出し元が権限 (\fBCAP_IPC_LOCK\fP)  を持っていない。
+.SH バージョン
+\fBmlock2\fP()  is available since Linux 4.4; glibc support was added in
+version 2.27.
+.SH 準拠
+POSIX.1\-2001, POSIX.1\-2008, SVr4.
+.PP
+\fBmlock2\fP() は Linux 固有である。
+.PP
+\fBmlock\fP()  と \fBmunlock\fP()  が使用可能な POSIX システムでは \fB_POSIX_MEMLOCK_RANGE\fP が
+\fI<unistd.h>\fP で定義されている。 また、ページあたりのバイト数は、 \fI<limits.h>\fP
+で定義される定数 \fBPAGESIZE\fP から (定義されている場合)、もしくは \fIsysconf(_SC_PAGESIZE)\fP
+を呼び出すことで決定できる。
+.PP
+.\" POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
+.\" -1: unavailable, 0: ask using sysconf().
+.\" glibc defines it to 1.
+\fBmlockall\fP()  と \fBmunlockall\fP()  が利用可能な POSIX システムでは、 \fB_POSIX_MEMLOCK\fP は
+\fI<unistd.h>\fP で 0 より大きい値に定義されている (\fBsysconf\fP(3)  も参照のこと)。
+.SH 注意
+メモリーのロックの用途としては主に二つある: リアルタイム アルゴリズムと高いセキュリティの必要なデータ処理である。リアルタイムの
+アプリケーションは決定的なタイミングやスケジューリングを必要とするが、 ページングは予期しないプログラムの実行遅延をもたらす主要な要因となる。
+リアルタイムのアプリケーションはたいていは \fBsched_setscheduler\fP(2)  でリアルタイムスケジューラに変更される。
+暗号やセキュリティのソフトウェアはしばしばパスワードや秘密鍵のデータの ような重要なバイト列を扱う。ページングの結果、これらの秘密が
+スワップ用の固定媒体に転送されるかもしれない。そして、セキュリティ ソフトウェアが RAM 上の秘密を削除して終了したずっと後になっても、
+このスワップされたデータには敵がアクセスできる可能性がある (しかし、ラップトップといくつかのデスクトップコンピュータの サスペンドモードはシステムの
+RAM の内容をメモリーのロックに関わらず ディスクに保存することに注意)。
+.PP
+リアルタイムプロセスが \fBmlockall\fP()  を使ってページフォールトによる遅延を防ごうとする場合、
+関数呼び出しによってページフォールトが発生しないように、 時間制限の厳しい部分 (time\-critical section) に入る前に
+十分な量のロックされたスタックを確保しておく必要がある。 これを実現するには、十分な大きさの自動変数 (の配列) を確保し、
+これらのスタック用のページがメモリー上に確保されるようにこの配列に 書き込みを行う関数を用意し、これを呼び出せばよい。こうすることで、
+十分な量のページがスタックにマッピングされ、RAM にロックされる。 ダミーの書き込みを行うことによって、 時間制限の厳しい部分 (critical
+section) 内では書き込み時コピーによる ページフォールトさえも発生しないことが保証される。
+.PP
+Memory locks are not inherited by a child created via \fBfork\fP(2)  and are
+automatically removed (unlocked) during an \fBexecve\fP(2)  or when the process
+terminates.  The \fBmlockall\fP()  \fBMCL_FUTURE\fP and \fBMCL_FUTURE |
+MCL_ONFAULT\fP settings are not inherited by a child created via \fBfork\fP(2)
+and are cleared during an \fBexecve\fP(2).
+.PP
+Note that \fBfork\fP(2)  will prepare the address space for a copy\-on\-write
+operation.  The consequence is that any write access that follows will cause
+a page fault that in turn may cause high latencies for a real\-time process.
+Therefore, it is crucial not to invoke \fBfork\fP(2)  after an \fBmlockall\fP()
+or \fBmlock\fP()  operation\(emnot even from a thread which runs at a low
+priority within a process which also has a thread running at elevated
+priority.
+.PP
+あるアドレス範囲に対するメモリーロックは、そのアドレス範囲が \fBmunmap\fP(2)  によってアンマップされた場合は削除される。
+.PP
+メモリーのロックは累積しない。 すなわち複数回 \fBmlock\fP(), \fBmlock2\fP(), \fBmlockall\fP()
+を呼び出してロックされたページでも、 対応する範囲に対して \fBmunlock\fP()  を 1 回呼び出したり \fBmunlockall\fP()
+を呼び出したりするだけでロック解除される。 複数の場所や複数のプロセスにマップされているページは、少なくとも一つの場所、
+一つのプロセスでロックされている限りは RAM に残り続ける。
+.PP
+If a call to \fBmlockall\fP()  which uses the \fBMCL_FUTURE\fP flag is followed by
+another call that does not specify this flag, the changes made by the
+\fBMCL_FUTURE\fP call will be lost.
+.PP
+The \fBmlock2\fP()  \fBMLOCK_ONFAULT\fP flag and the \fBmlockall\fP()  \fBMCL_ONFAULT\fP
+flag allow efficient memory locking for applications that deal with large
+mappings where only a (small) portion of pages in the mapping are touched.
+In such cases, locking all of the pages in a mapping would incur a
+significant penalty for memory locking.
+.SS "Linux での注意"
+Linux では、 \fBmlock\fP(), \fBmlock2\fP(), \fBmunlock\fP() は自動的に \fIaddr\fP
+を端数切り捨てにより一番近いページ境界へと丸める。 しかし POSIX.1 仕様の \fBmlock\fP() と \fBmunlock\fP() は
+\fIaddr\fP がページ境界に合っていることを要求する実装も許している。 そのため移植性を意図したアプリケーションではきちんと境界に合わせた方が良い。
+.PP
+Linux 固有の \fI/proc/[pid]/status\fP ファイルの \fIVmLck\fP フィールドには、 \fBmlock\fP(),
+\fBmlock2\fP(), \fBmlockall\fP() および \fBmmap\fP(2) \fBMAP_LOCKED\fP を使って、 ID が \fIPID\fP
+のプロセスがロックしているメモリー量 (キロバイト単位) が表示される。
+.SS 制限と権限
+Linux 2.6.8 以前では、メモリーをロックするためには特権 (\fBCAP_IPC_LOCK\fP)  が必要で、 ソフト資源制限
+\fBRLIMIT_MEMLOCK\fP はプロセスがどれだけのメモリーをロックできるかの制限を定義する。
+.PP
+Linux 2.6.9 以降では、特権を持つプロセスがロックできるメモリー量は無制限となり、 代わりにソフト資源制限 \fBRLIMIT_MEMLOCK\fP
+は特権を持たないプロセスがロックできるメモリー量の制限を定義する。
+.SH バグ
+.\" commit 0cf2f6f6dc605e587d2c1120f295934c77e810e8
+In Linux 4.8 and earlier, a bug in the kernel's accounting of locked memory
+for unprivileged processes (i.e., without \fBCAP_IPC_LOCK\fP)  meant that if
+the region specified by \fIaddr\fP and \fIlen\fP overlapped an existing lock, then
+the already locked bytes in the overlapping region were counted twice when
+checking against the limit.  Such double accounting could incorrectly
+calculate a "total locked memory" value for the process that exceeded the
+\fBRLIMIT_MEMLOCK\fP limit, with the result that \fBmlock\fP()  and \fBmlock2\fP()
+would fail on requests that should have succeeded.  This bug was fixed in
+Linux 4.9.
+.PP
+2.4.17 までの 2.4 シリーズの Linux カーネルには、 \fBmlockall\fP()  \fBMCL_FUTURE\fP フラグが
+\fBfork\fP(2)  で継承されると言うバグがある。 これはカーネル 2.4.18 で修正された。
+.PP
+.\" See the following LKML thread:
+.\" http://marc.theaimsgroup.com/?l=linux-kernel&m=113801392825023&w=2
+.\" "Rationale for RLIMIT_MEMLOCK"
+.\" 23 Jan 2006
+カーネル 2.6.9 以降では、特権を持ったプロセスが \fImlockall(MCL_FUTURE)\fP を呼び出した後で、特権をなくした場合 (例えば、
+実効 UID を 0 以外の値に変更するなどにより、 \fBCAP_IPC_LOCK\fP ケーパビリティを失った場合)、リソース上限
+\fBRLIMIT_MEMLOCK\fP に達すると、それ以降のメモリー割り当て (例えば \fBmmap\fP(2), \fBbrk\fP(2))  は失敗する。
+.SH 関連項目
+\fBmincore\fP(2), \fBmmap\fP(2), \fBsetrlimit\fP(2), \fBshmctl\fP(2), \fBsysconf\fP(3),
+\fBproc\fP(5), \fBcapabilities\fP(7)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
diff --git a/manual/LDP_man-pages/draft/man2/mprotect.2 b/manual/LDP_man-pages/draft/man2/mprotect.2
new file mode 100644 (file)
index 0000000..5ec3efc
--- /dev/null
@@ -0,0 +1,283 @@
+.\" Copyright (C) 2007 Michael Kerrisk <mtk.manpages@gmail.com>
+.\" and Copyright (C) 1995 Michael Shields <shields@tembel.org>.
+.\"
+.\" %%%LICENSE_START(VERBATIM)
+.\" Permission is granted to make and distribute verbatim copies of this
+.\" manual provided the copyright notice and this permission notice are
+.\" preserved on all copies.
+.\"
+.\" Permission is granted to copy and distribute modified versions of this
+.\" manual under the conditions for verbatim copying, provided that the
+.\" entire resulting derived work is distributed under the terms of a
+.\" permission notice identical to this one.
+.\"
+.\" Since the Linux kernel and libraries are constantly changing, this
+.\" manual page may be incorrect or out-of-date.  The author(s) assume no
+.\" responsibility for errors or omissions, or for damages resulting from
+.\" the use of the information contained herein.  The author(s) may not
+.\" have taken the same level of care in the production of this manual,
+.\" which is licensed free of charge, as they might when working
+.\" professionally.
+.\"
+.\" Formatted or processed versions of this manual, if unaccompanied by
+.\" the source, must acknowledge the copyright and author of this work.
+.\" %%%LICENSE_END
+.\"
+.\" Modified 1996-10-22 by Eric S. Raymond <esr@thyrsus.com>
+.\" Modified 1997-05-31 by Andries Brouwer <aeb@cwi.nl>
+.\" Modified 2003-08-24 by Andries Brouwer <aeb@cwi.nl>
+.\" Modified 2004-08-16 by Andi Kleen <ak@muc.de>
+.\" 2007-06-02, mtk: Fairly substantial rewrites and additions, and
+.\" a much improved example program.
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
+.\"         all rights reserved.
+.\" Translated 1997-06-01, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
+.\" Updated and revised 2003-10-24, Suzuki Takashi.
+.\" Updated & Modified 2005-02-08, Yuichi SATO <ysato444@yahoo.co.jp>
+.\" Updated & Modified 2005-10-15, Yuichi SATO
+.\" Updated 2007-06-11, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v2.54
+.\"
+.TH MPROTECT 2 2020\-11\-01 Linux "Linux Programmer's Manual"
+.SH 名前
+mprotect, pkey_mprotect \- メモリー領域の保護を設定する
+.SH 書式
+.nf
+\fB#include <sys/mman.h>\fP
+.PP
+\fBint mprotect(void *\fP\fIaddr\fP\fB, size_t \fP\fIlen\fP\fB, int \fP\fIprot\fP\fB);\fP
+
+\fB#define _GNU_SOURCE\fP             /* feature_test_macros(7) 参照 */
+\fB#include <sys/mman.h>\fP
+.PP
+\fBint pkey_mprotect(void *\fP\fIaddr\fP\fB, size_t \fP\fIlen\fP\fB, int \fP\fIprot\fP\fB, int \fP\fIpkey\fP\fB);\fP
+.fi
+.SH 説明
+\fBmprotect\fP()  は、区間 [\fIaddr\fP,\ \fIaddr\fP+\fIlen\fP\-1] のアドレス範囲を含む
+呼び出し元のプロセスのメモリーページのアクセス保護を変更する。 \fIaddr\fP はページ境界に一致していなければならない。
+.PP
+呼び出し元のプロセスがアクセス保護に違反するようなメモリーアクセスを 行おうとすると、カーネルはシグナル \fBSIGSEGV\fP
+をそのプロセスに対して生成する。
+.PP
+\fIprot\fP is a combination of the following access flags: \fBPROT_NONE\fP or a
+bitwise\-or of the other values in the following list:
+.TP 
+\fBPROT_NONE\fP
+そのメモリーには全くアクセスできない。
+.TP 
+\fBPROT_READ\fP
+そのメモリーを読み取ることができる。
+.TP 
+\fBPROT_WRITE\fP
+そのメモリーを変更できる。
+.TP 
+\fBPROT_EXEC\fP
+そのメモリーは実行可能である。
+.TP 
+\fBPROT_SEM\fP (Linux 2.5.7 以降)
+The memory can be used for atomic operations.  This flag was introduced as
+part of the \fBfutex\fP(2)  implementation (in order to guarantee the ability
+to perform atomic operations required by commands such as \fBFUTEX_WAIT\fP),
+but is not currently used in on any architecture.
+.TP 
+\fBPROT_SAO\fP (Linux 2.6.26 以降)
+.\" commit aba46c5027cb59d98052231b36efcbbde9c77a1d
+.\" commit ef3d3246a0d06be622867d21af25f997aeeb105f
+The memory should have strong access ordering.  This feature is specific to
+the PowerPC architecture (version 2.06 of the architecture specification
+adds the SAO CPU feature, and it is available on POWER 7 or PowerPC A2, for
+example).
+.PP
+Additionally (since Linux 2.6.0), \fIprot\fP can have one of the following
+flags set:
+.TP 
+.\" mm/mmap.c:
+.\"    vm_flags |= calc_vm_prot_bits(prot, pkey) | calc_vm_flag_bits(flags) |
+.\"                    mm->def_flags | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC;
+.\" And calc_vm_flag_bits converts only GROWSDOWN/DENYWRITE/LOCKED.
+\fBPROT_GROWSUP\fP
+.\" The VMA is one that was marked with VM_GROWSUP by the kernel
+.\" when the stack was created. Note that (unlike VM_GROWSDOWN),
+.\" there is no mmap() flag (analogous to MAP_GROWSDOWN) for
+.\" creating a VMA that is marked VM_GROWSUP.
+Apply the protection mode up to the end of a mapping that grows upwards.
+(Such mappings are created for the stack area on architectures\(emfor
+example, HP\-PARISC\(emthat have an upwardly growing stack.)
+.TP 
+\fBPROT_GROWSDOWN\fP
+Apply the protection mode down to the beginning of a mapping that grows
+downward (which should be a stack segment or a segment mapped with the
+\fBMAP_GROWSDOWN\fP flag set).
+.PP
+Like \fBmprotect\fP(), \fBpkey_mprotect\fP()  changes the protection on the pages
+specified by \fIaddr\fP and \fIlen\fP.  The \fIpkey\fP argument specifies the
+protection key (see \fBpkeys\fP(7))  to assign to the memory.  The protection
+key must be allocated with \fBpkey_alloc\fP(2)  before it is passed to
+\fBpkey_mprotect\fP().  For an example of the use of this system call, see
+\fBpkeys\fP(7).
+.SH 返り値
+成功した場合、 \fBmprotect\fP() と \fBpkey_mprotect\fP() は 0 を返す。エラーの場合、これらのシステムコールは \-1
+を返し、 \fIerrno\fP を適切に設定する。
+.SH エラー
+.TP 
+\fBEACCES\fP
+指定されたアクセスをメモリーに設定することができない。 これは、例えば ファイルを読み取り専用で \fBmmap\fP(2)  しており、その領域に対して
+\fBmprotect\fP()  を呼び出して \fBPROT_WRITE\fP に設定しようとした場合に発生する。
+.TP 
+\fBEINVAL\fP
+\fIaddr\fP が有効なポインターでないか、 システムのページサイズの倍数でない。
+.TP 
+\fBEINVAL\fP
+(\fBpkey_mprotect\fP())  \fIpkey\fP has not been allocated with \fBpkey_alloc\fP(2)
+.TP 
+\fBEINVAL\fP
+Both \fBPROT_GROWSUP\fP and \fBPROT_GROWSDOWN\fP were specified in \fIprot\fP.
+.TP 
+\fBEINVAL\fP
+無効なフラグが \fIprot\fP に指定された。
+.TP 
+\fBEINVAL\fP
+(PowerPC architecture)  \fBPROT_SAO\fP was specified in \fIprot\fP, but SAO
+hardware feature is not available.
+.TP 
+\fBENOMEM\fP
+カーネル内部の構造体を割り当てることができなかった。
+.TP 
+\fBENOMEM\fP
+[\fIaddr\fP, \fIaddr\fP+\fIlen\fP\-1] という範囲のアドレスがプロセスのアドレス空間として不正であるか、
+その範囲のアドレスがマップされていない 1 つ以上のページを指している (カーネル 2.4.19 より前では、この状況でエラー \fBEFAULT\fP
+が間違って生成されていた)。
+.TP 
+\fBENOMEM\fP
+.\" I.e., the number of VMAs would exceed the 64 kB maximum
+Changing the protection of a memory region would result in the total number
+of mappings with distinct attributes (e.g., read versus read/write
+protection)  exceeding the allowed maximum.  (For example, making the
+protection of a range \fBPROT_READ\fP in the middle of a region currently
+protected as \fBPROT_READ|PROT_WRITE\fP would result in three mappings: two
+read/write mappings at each end and a read\-only mapping in the middle.)
+.SH バージョン
+\fBpkey_mprotect\fP() は Linux 4.9 で登場した。 ライブラリでのサポートは glibc 2.27 で追加された。
+.SH 準拠
+.\" SVr4 defines an additional error
+.\" code EAGAIN. The SVr4 error conditions don't map neatly onto Linux's.
+\fBmprotect\fP(): POSIX.1\-2001, POSIX.1\-2008, SVr4.  POSIX では、 \fBmmap\fP(2)
+経由で獲得していないメモリー領域に対して \fBmprotect\fP()  を行った場合の \fBmprotect\fP()  の動作は未定義であるとされている。
+.PP
+\fBpkey_mprotect\fP() は非標準の Linux による拡張である。
+.SH 注意
+Linux では、(カーネル vsyscall 領域以外の)  任意のプロセスアドレス空間に対して \fBmprotect\fP()
+を呼び出すことが、常に許されている。 これは特に既存のコードマッピングを書き込み可能にするために使われる。
+.PP
+Whether \fBPROT_EXEC\fP has any effect different from \fBPROT_READ\fP depends on
+processor architecture, kernel version, and process state.  If
+\fBREAD_IMPLIES_EXEC\fP is set in the process's personality flags (see
+\fBpersonality\fP(2)), specifying \fBPROT_READ\fP will implicitly add
+\fBPROT_EXEC\fP.
+.PP
+On some hardware architectures (e.g., i386), \fBPROT_WRITE\fP implies
+\fBPROT_READ\fP.
+.PP
+POSIX.1 では、 \fIprot\fP で指定されていないアクセスを許可する実装を認めている。 ただし、最低限、 \fBPROT_WRITE\fP
+がセットされている場合にのみ書き込みアクセスが許可され、 \fBPROT_NONE\fP がセットされている場合にはアクセスは許可されない点だけは
+満たす必要がある。
+.PP
+Applications should be careful when mixing use of \fBmprotect\fP()  and
+\fBpkey_mprotect\fP().  On x86, when \fBmprotect\fP()  is used with \fIprot\fP set to
+\fBPROT_EXEC\fP a pkey may be allocated and set on the memory implicitly by the
+kernel, but only when the pkey was 0 previously.
+.PP
+On systems that do not support protection keys in hardware,
+\fBpkey_mprotect\fP()  may still be used, but \fIpkey\fP must be set to \-1.  When
+called this way, the operation of \fBpkey_mprotect\fP()  is equivalent to
+\fBmprotect\fP().
+.SH 例
+.\" sigaction.2 refers to this example
+以下のプログラムは、 \fBmprotect\fP() の使用方法を示すものである。このプログラムは、メモリーページを 4つ確保し、そのうち 3番目のページを
+読み込み専用に設定する。その後で、確保した領域のアドレスの小さい方から 大きな方に向かって順番にバイト値を変更するループを実行する。
+.PP
+プログラムを実行した場合の一例を以下に示す。
+.PP
+.in +4n
+.EX
+$\fB ./a.out\fP
+Start of region:        0x804c000
+Got SIGSEGV at address: 0x804e000
+.EE
+.in
+.SS プログラムのソース
+\&
+.EX
+#include <unistd.h>
+#include <signal.h>
+#include <stdio.h>
+#include <malloc.h>
+#include <stdlib.h>
+#include <errno.h>
+#include <sys/mman.h>
+
+#define handle_error(msg) \e
+    do { perror(msg); exit(EXIT_FAILURE); } while (0)
+
+static char *buffer;
+
+static void
+handler(int sig, siginfo_t *si, void *unused)
+{
+    /* Note: calling printf() from a signal handler is not safe
+       (and should not be done in production programs), since
+       printf() is not async\-signal\-safe; see signal\-safety(7).
+       Nevertheless, we use printf() here as a simple way of
+       showing that the handler was called. */
+
+    printf("Got SIGSEGV at address: %p\en", si\->si_addr);
+    exit(EXIT_FAILURE);
+}
+
+int
+main(int argc, char *argv[])
+{
+    int pagesize;
+    struct sigaction sa;
+
+    sa.sa_flags = SA_SIGINFO;
+    sigemptyset(&sa.sa_mask);
+    sa.sa_sigaction = handler;
+    if (sigaction(SIGSEGV, &sa, NULL) == \-1)
+        handle_error("sigaction");
+
+    pagesize = sysconf(_SC_PAGE_SIZE);
+    if (pagesize == \-1)
+        handle_error("sysconf");
+
+    /* Allocate a buffer aligned on a page boundary;
+       initial protection is PROT_READ | PROT_WRITE */
+
+    buffer = memalign(pagesize, 4 * pagesize);
+    if (buffer == NULL)
+        handle_error("memalign");
+
+    printf("Start of region:        %p\en", buffer);
+
+    if (mprotect(buffer + pagesize * 2, pagesize,
+                PROT_READ) == \-1)
+        handle_error("mprotect");
+
+    for (char *p = buffer ; ; )
+        *(p++) = \(aqa\(aq;
+
+    printf("Loop completed\en");     /* Should never happen */
+    exit(EXIT_SUCCESS);
+}
+.EE
+.SH 関連項目
+\fBmmap\fP(2), \fBsysconf\fP(3), \fBpkeys\fP(7)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
diff --git a/manual/LDP_man-pages/draft/man2/msync.2 b/manual/LDP_man-pages/draft/man2/msync.2
new file mode 100644 (file)
index 0000000..e5e9f28
--- /dev/null
@@ -0,0 +1,108 @@
+.\" Copyright (C) 1996 Andries Brouwer (aeb@cwi.nl)
+.\"
+.\" %%%LICENSE_START(VERBATIM)
+.\" Permission is granted to make and distribute verbatim copies of this
+.\" manual provided the copyright notice and this permission notice are
+.\" preserved on all copies.
+.\"
+.\" Permission is granted to copy and distribute modified versions of this
+.\" manual under the conditions for verbatim copying, provided that the
+.\" entire resulting derived work is distributed under the terms of a
+.\" permission notice identical to this one.
+.\"
+.\" Since the Linux kernel and libraries are constantly changing, this
+.\" manual page may be incorrect or out-of-date.  The author(s) assume no
+.\" responsibility for errors or omissions, or for damages resulting from
+.\" the use of the information contained herein.  The author(s) may not
+.\" have taken the same level of care in the production of this manual,
+.\" which is licensed free of charge, as they might when working
+.\" professionally.
+.\"
+.\" Formatted or processed versions of this manual, if unaccompanied by
+.\" the source, must acknowledge the copyright and authors of this work.
+.\" %%%LICENSE_END
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
+.\"         all rights reserved.
+.\" Translated Sun Feb 23 19:45:43 JST 1997
+.\"         by HANATAKA Shinya <hanataka@abyss.rim.or.jp>
+.\" Updated and revised Fri Oct 24 23:34:51 JST 2003
+.\"         by Suzuki Takashi.
+.\" Updated 2007-01-01 by Kentaro Shirakata <argrath@ub32.org>
+.\"
+.TH MSYNC 2 2020\-06\-09 Linux "Linux Programmer's Manual"
+.SH 名前
+msync \- ファイルをマップしたメモリーと同期させる
+.SH 書式
+\fB#include <sys/mman.h>\fP
+.PP
+\fBint msync(void *\fP\fIaddr\fP\fB, size_t \fP\fIlength\fP\fB, int \fP\fIflags\fP\fB);\fP
+.SH 説明
+\fBmsync\fP()  は \fBmmap\fP(2)  を使ってメモリーにマップされたファイルの、
+メモリー上のコピーになされた変更をファイルシステムに反映させる。 この関数を使用しないと、 \fBmunmap\fP(2)
+が呼び出されるまで変更が書き戻される保証はない。 より正確には、ファイルのうち \fIaddr\fP から始まり長さ \fIlength\fP
+のメモリー領域に対応する部分が更新される。
+.PP
+The \fIflags\fP argument should specify exactly one of \fBMS_ASYNC\fP and
+\fBMS_SYNC\fP, and may additionally include the \fBMS_INVALIDATE\fP bit.  These
+bits have the following meanings:
+.TP 
+\fBMS_ASYNC\fP
+Specifies that an update be scheduled, but the call returns immediately.
+.TP 
+\fBMS_SYNC\fP
+Requests an update and waits for it to complete.
+.TP 
+\fBMS_INVALIDATE\fP
+.\" Since Linux 2.4, this seems to be a no-op (other than the
+.\" EBUSY check for VM_LOCKED).
+Asks to invalidate other mappings of the same file (so that they can be
+updated with the fresh values just written).
+.SH 返り値
+成功した場合、 0 が返る。エラーの場合、 \-1 が返り、 \fIerrno\fP が適切に設定される。
+.SH エラー
+.TP 
+\fBEBUSY\fP
+I flags に \fBMS_INVALIDATE\fP が指定されたが、指定されたアドレス範囲にロックが存在する。
+.TP 
+\fBEINVAL\fP
+\fIaddr\fP が PAGESIZE の倍数でない。または、 \fIflags\fP に
+\fBMS_ASYNC\fP、\fBMS_INVALIDATE\fP、\fBMS_SYNC\fP 以外のビットが設定された。 または、 \fIflags\fP に
+\fBMS_SYNC\fP と \fBMS_ASYNC\fP の両方が設定された。
+.TP 
+\fBENOMEM\fP
+指定されたメモリー (またはその一部) がマップされていない。
+.SH 準拠
+POSIX.1\-2001, POSIX.1\-2008.
+.PP
+この関数は Linux 1.3.21 で導入されたが、 \fBENOMEM\fP ではなく \fBEFAULT\fP が使われていた。 これは Linux
+2.4.19 で POSIX における値 \fBENOMEM\fP に変更された。
+.PP
+.\" POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
+.\" -1: unavailable, 0: ask using sysconf().
+.\" glibc defines them to 1.
+\fBmsync\fP()  が使用可能な POSIX システムでは \fB_POSIX_MAPPED_FILES\fP と
+\fB_POSIX_SYNCHRONIZED_IO\fP の両方が \fI<unistd.h>\fP で 0 より大きい値に定義される。
+(\fBsysconf\fP(3)  を参照すること。 )
+.SH 注意
+.\" commit 204ec841fbea3e5138168edbc3a76d46747cc987
+POSIX では \fBMS_SYNC\fP と \fBMS_ASYNC\fP のいずれかは必ず \fIflags\fP に指定しなければならないとされており、
+実際にこれらのフラグのいずれかを指定しなかった場合 \fBmsync\fP() が失敗するシステムもある。 しかし、 Linux
+ではこれらのフラグのいずれも指定せずに \fBmsync\fP() を呼び出すことができ、 その場合の動作は (現在のところ) \fBMS_ASYNC\fP
+を指定した場合と等価である。 (Linux 2.6.19 以降では \fBMS_ASYNC\fP は実際には no\-op (何もしない命令) である。
+これはカーネルが正しく dirty ページを追跡し、必要に応じてストレージにそれらをフラッシュするからである。) Linux
+の動作に関係なく、アプリケーションの移植性を考慮し、将来も確実に動くようにするには、 \fBMS_SYNC\fP か \fBMS_ASYNC\fP のいずれかを必ず
+\fIflags\fP に指定するようにすべきである。
+.SH 関連項目
+\fBmmap\fP(2)
+.PP
+B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128\(en129 and 389\(en391.
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
index c0602b2..6e47a34 100644 (file)
@@ -101,10 +101,8 @@ _POSIX_C_SOURCE\ >=\ 200112L
 例えば、これは大きなファイルをストリーミングするときに役立つ。 プログラムは、使用済みのキャッシュされたデータを解放するように、
 定期的にカーネルに要求するかもしれない。 そうすることにより、さらに有効なキャッシュされたページが、 代わりに破棄されることはない。
 .IP
-Requests to discard partial pages are ignored.  It is preferable to preserve
-needed data than discard unneeded data.  If the application requires that
-data be considered for discarding, then \fIoffset\fP and \fIlen\fP must be
-page\-aligned.
+ページの一部分の破棄要求は無視される。 不要なデータを破棄するよりも必要なデータを保持する方がよい。
+アプリケーションがデータを破棄した方がよいと思う場合は、 \fIoffset\fP と \fIlen\fP がページ境界に合っていなければならない。
 .IP
 The implementation \fImay\fP attempt to write back dirty pages in the specified
 region, but this is not guaranteed.  Any unwritten dirty pages will not be
@@ -122,9 +120,8 @@ released, it should call \fBfsync\fP(2)  or \fBfdatasync\fP(2)  first.
 .TP 
 \fBESPIPE\fP
 .\" commit 87ba81dba431232548ce29d5d224115d0c2355ac
-The specified file descriptor refers to a pipe or FIFO.  (\fBESPIPE\fP is the
-error specified by POSIX, but before kernel version 2.6.16, Linux returned
-\fBEINVAL\fP in this case.)
+指定されたファイルディスクリプターがパイプまたは FIFO を参照している (\fBESPIPE\fP は POSIX で規定されているエラーだが、
+バージョン 2.6.16 より前のカーネルでは、 この場合に \fBEINVAL\fP を返していた。)
 .SH バージョン
 .\" of fadvise64_64()
 カーネルによるサポートは Linux 2.5.60 で最初に登場し、
@@ -136,8 +133,8 @@ error specified by POSIX, but before kernel version 2.6.16, Linux returned
 Linux 3.18 以降では、対応するシステムコールのサポートは任意となり、利用できるかはカーネルが
 \fBCONFIG_ADVISE_SYSCALLS\fP オプションを有効にしてコンパイルされているかに依存する。
 .SH 準拠
-POSIX.1\-2001, POSIX.1\-2008.  Note that the type of the \fIlen\fP argument was
-changed from \fIsize_t\fP to \fIoff_t\fP in POSIX.1\-2001 TC1.
+POSIX.1\-2001, POSIX.1\-2008.  \fIlen\fP 引き数の型が POSIX.1\-2001 TC1 において \fIsize_t\fP
+から \fIoff_t\fP に変更された点に注意すること。
 .SH 注意
 Linux では、\fBPOSIX_FADV_NORMAL\fP はバッキングデバイスの デフォルトサイズに先読み (readahead)
 ウインドウを設定する。 \fBPOSIX_FADV_SEQUENTIAL\fP はこのサイズを 2 倍し、 \fBPOSIX_FADV_RANDOM\fP
@@ -150,20 +147,18 @@ The contents of the kernel buffer cache can be cleared via the
 One can obtain a snapshot of which pages of a file are resident in the
 buffer cache by opening a file, mapping it with \fBmmap\fP(2), and then
 applying \fBmincore\fP(2)  to the mapping.
-.SS "C library/kernel differences"
+.SS "C ライブラリとカーネルの違い"
 The name of the wrapper function in the C library is \fBposix_fadvise\fP().
 The underlying system call is called \fBfadvise64\fP()  (or, on some
 architectures, \fBfadvise64_64\fP()); the difference between the two is that
 the former system call assumes that the type of the \fIlen\fP argument is
 \fIsize_t\fP, while the latter expects \fIloff_t\fP there.
 .SS アーキテクチャー固有の派生バージョン
-Some architectures require 64\-bit arguments to be aligned in a suitable pair
-of registers (see \fBsyscall\fP(2)  for further detail).  On such
-architectures, the call signature of \fBposix_fadvise\fP()  shown in the
-SYNOPSIS would force a register to be wasted as padding between the \fIfd\fP
-and \fIoffset\fP arguments.  Therefore, these architectures define a version of
-the system call that orders the arguments suitably, but is otherwise exactly
-the same as \fBposix_fadvise\fP().
+いくつかのアーキテクチャーでは、 64 ビットの引き数は適切なレジスターの組に割り当てる必要がある (\fBsyscall\fP(2) 参照)。
+このようなアーキテクチャーでは、 「書式」に書かれている  \fBposix_fadvise\fP() の呼び出しシグネチャーで、 引き数 \fIfd\fP と
+\fIoffset\fP の間のパディング (詰めもの) でレジスターが一つ消費されてしまう。 そのため、
+これらのアーキテクチャーでは引き数が適切な順序になった別のシステムコールが定義されているが、 それ以外は \fBposix_fadvise\fP()
+と全く同じである。
 .PP
 例えば、 Linux 2.6.14 以降では、 ARM には以下のシステムコールが存在する。
 .PP
index 9427029..ed58954 100644 (file)
@@ -50,14 +50,11 @@ readahead \- 前もってファイルをページキャッシュに読み込む
 \fBreadahead\fP() はファイルの先読みを行い、そのファイルに対する後の読み込みがキャッシュから行われ、ディスク I/O で停止しないようにする
 (この条件を満たせるのは、先読みは十分早く行われ、システムの他の動作によりその後にキャッシュからページがフラッシュされない場合である)。
 .PP
-The \fIfd\fP argument is a file descriptor identifying the file which is to be
-read.  The \fIoffset\fP argument specifies the starting point from which data
-is to be read and \fIcount\fP specifies the number of bytes to be read.  I/O is
-performed in whole pages, so that \fIoffset\fP is effectively rounded down to a
-page boundary and bytes are read up to the next page boundary greater than
-or equal to \fI(offset+count)\fP.  \fBreadahead\fP()  does not read beyond the end
-of the file.  The file offset of the open file description referred to by
-the file descriptor \fIfd\fP is left unchanged.
+\fIfd\fP 引き数は読み込みを行うファイルを識別するファイルディスクリプターである。 \fIoffset\fP 引き数はデータの読み込み開始位置を指定し、
+\fIcount\fP は読み込むデータのバイト数を指定する。 ディスク I/O はページ単位で実行されるので、 実際には \fIoffset\fP
+はページ境界に切り下げられ、読み込みバイト数は \fI(offset+count)\fP より小さくない次のページ境界まで切り上げられる。
+\fBreadahead\fP()  はファイルの末尾を越えた範囲まで読み出しを行うことはない。ファイルディスクリプター \fIfd\fP
+で参照されたオープン済のファイル記述のファイルオフセットは 変更されない。
 .SH 返り値
 \fBreadahead\fP()  は成功すると 0 を返す。失敗した場合 \-1 を返し、 \fIerrno\fP にエラーの原因を示す値を設定する。
 .SH エラー
index 0335156..af7a19e 100644 (file)
@@ -111,11 +111,10 @@ systems.
 \fBremap_file_pages\fP()  システムコールは Linux 固有のものである。
 .SH 注意
 .\" commit 3ee6dafc677a68e461a7ddafc94a580ebab80735
-Since Linux 2.6.23, \fBremap_file_pages\fP()  creates non\-linear mappings only
-on in\-memory filesystems such as \fBtmpfs\fP(5), hugetlbfs or ramfs.  On
-filesystems with a backing store, \fBremap_file_pages\fP()  is not much more
-efficient than using \fBmmap\fP(2)  to adjust which parts of the file are
-mapped to which addresses.
+Linux 2.6.23 以降、 \fBremap_file_pages\fP() は \fBtmpfs\fP(5), hugetlbfs, ramfs
+などのインメモリーファイルシステム上にのみ非線形マッピングを作成する。 裏にデータストアを持つファイルシステム上では、
+\fBremap_file_pages\fP() は、 ファイルのどの部分がどのアドレスにマッピングされているかの調整が、 \fBmmap\fP(2)
+を使った場合ほど効率的ではない。
 .SH 関連項目
 \fBgetpagesize\fP(2), \fBmmap\fP(2), \fBmmap2\fP(2), \fBmprotect\fP(2), \fBmremap\fP(2),
 \fBmsync\fP(2)
diff --git a/manual/LDP_man-pages/draft/man2/shmctl.2 b/manual/LDP_man-pages/draft/man2/shmctl.2
new file mode 100644 (file)
index 0000000..714e929
--- /dev/null
@@ -0,0 +1,334 @@
+.\" Copyright (c) 1993 Luigi P. Bai (lpb@softint.com) July 28, 1993
+.\" and Copyright 1993 Giorgio Ciucci <giorgio@crcc.it>
+.\" and Copyright 2004, 2005 Michael Kerrisk <mtk.manpages@gmail.com>
+.\"
+.\" %%%LICENSE_START(VERBATIM)
+.\" Permission is granted to make and distribute verbatim copies of this
+.\" manual provided the copyright notice and this permission notice are
+.\" preserved on all copies.
+.\"
+.\" Permission is granted to copy and distribute modified versions of this
+.\" manual under the conditions for verbatim copying, provided that the
+.\" entire resulting derived work is distributed under the terms of a
+.\" permission notice identical to this one.
+.\"
+.\" Since the Linux kernel and libraries are constantly changing, this
+.\" manual page may be incorrect or out-of-date.  The author(s) assume no
+.\" responsibility for errors or omissions, or for damages resulting from
+.\" the use of the information contained herein.  The author(s) may not
+.\" have taken the same level of care in the production of this manual,
+.\" which is licensed free of charge, as they might when working
+.\" professionally.
+.\"
+.\" Formatted or processed versions of this manual, if unaccompanied by
+.\" the source, must acknowledge the copyright and authors of this work.
+.\" %%%LICENSE_END
+.\"
+.\" Modified 1993-07-28, Rik Faith <faith@cs.unc.edu>
+.\" Modified 1993-11-28, Giorgio Ciucci <giorgio@crcc.it>
+.\" Modified 1997-01-31, Eric S. Raymond <esr@thyrsus.com>
+.\" Modified 2001-02-18, Andries Brouwer <aeb@cwi.nl>
+.\" Modified 2002-01-05, 2004-05-27, 2004-06-17,
+.\"    Michael Kerrisk <mtk.manpages@gmail.com>
+.\" Modified 2004-10-11, aeb
+.\" Modified, Nov 2004, Michael Kerrisk <mtk.manpages@gmail.com>
+.\"    Language and formatting clean-ups
+.\"    Updated shmid_ds structure definitions
+.\"    Added information on SHM_DEST and SHM_LOCKED flags
+.\"    Noted that CAP_IPC_LOCK is not required for SHM_UNLOCK
+.\"            since kernel 2.6.9
+.\" Modified, 2004-11-25, mtk, notes on 2.6.9 RLIMIT_MEMLOCK changes
+.\" 2005-04-25, mtk -- noted aberrant Linux behavior w.r.t. new
+.\"    attaches to a segment that has already been marked for deletion.
+.\" 2005-08-02, mtk: Added IPC_INFO, SHM_INFO, SHM_STAT descriptions.
+.\" 2018-03-20, dbueso: Added SHM_STAT_ANY description.
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
+.\"         all rights reserved.
+.\" Translated 1997-03-01, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
+.\" Updated & Modified 2001-06-13, Yuichi SATO <ysato@h4.dion.ne.jp>
+.\" Updated & Modified 2005-01-05, Yuichi SATO <ysato444@yahoo.co.jp>
+.\" Updated & Modified 2005-09-06, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
+.\" Updated & Modified 2005-10-08, Akihiro MOTOKI
+.\" Updated 2006-07-21, Akihiro MOTOKI, LDP v2.36
+.\" Updated 2013-05-06, Akihiro MOTOKI <amotoki@gmail.com>
+.\"
+.TH SHMCTL 2 2020\-12\-21 Linux "Linux Programmer's Manual"
+.SH 名前
+shmctl \- System V 共有メモリー (shared memory) を制御する
+.SH 書式
+.ad l
+\fB#include <sys/ipc.h>\fP
+.br
+\fB#include <sys/shm.h>\fP
+.PP
+\fBint shmctl(int \fP\fIshmid\fP\fB, int \fP\fIcmd\fP\fB, struct shmid_ds *\fP\fIbuf\fP\fB);\fP
+.ad b
+.SH 説明
+\fBshmctl\fP()  は、識別子が \fIshmid\fP の System\ V 共有メモリーセグメントに対して \fIcmd\fP
+で指示した制御命令を実行する。
+.PP
+\fIbuf\fP 引き数は、 \fIshmid_ds\fP 構造体へのポインターである。 この構造体は \fI<sys/shm.h>\fP
+で以下のように定義されている
+.PP
+.in +4n
+.EX
+struct shmid_ds {
+    struct ipc_perm shm_perm;    /* 所有権と許可 */
+    size_t          shm_segsz;   /* セグメントのサイズ (バイト) */
+    time_t          shm_atime;   /* 最後の付加 (attach) の時刻 */
+    time_t          shm_dtime;   /* 最後の分離 (detach) の時刻 */
+    time_t          shm_ctime;   /* 作成時刻 / shmctl() による
+                                    最後の変更時刻 */
+    pid_t           shm_cpid;    /* 作成者 (creator) の PID */
+    pid_t           shm_lpid;    /* 最後の shmat(2)/shmdt(2) の PID */
+    shmatt_t        shm_nattch;  /* 現在付加されている数 */
+    ...
+};
+.EE
+.in
+.PP
+\fIshmid_ds\fP 構造体のフィールドは以下の通りである。
+.TP  12
+\fIshm_perm\fP
+This is an \fIipc_perm\fP structure (see below) that specifies the access
+permissions on the shared memory segment.
+.TP 
+\fIshm_segsz\fP
+共有メモリーセグメントのサイズ (バイト単位)。
+.TP 
+\fIshm_atime\fP
+Time of the last \fBshmat\fP(2)  system call that attached this segment.
+.TP 
+\fIshm_dtime\fP
+Time of the last \fBshmdt\fP(2)  system call that detached tgis segment.
+.TP 
+\fIshm_ctime\fP
+Time of creation of segment or time of the last \fBshmctl\fP()  \fBIPC_SET\fP
+operation.
+.TP 
+\fIshm_cpid\fP
+その共有メモリーセグメントを作成したプロセスの ID。
+.TP 
+\fIshm_lpid\fP
+ID of the last process that executed a \fBshmat\fP(2)  or \fBshmdt\fP(2)  system
+call on this segment.
+.TP 
+\fIshm_nattch\fP
+Number of processes that have this segment attached.
+.PP
+\fIipc_perm\fP 構造体は以下のように定義されている (強調されたフィールドは \fBIPC_SET\fP を使って設定可能である):
+.PP
+.in +4n
+.EX
+struct ipc_perm {
+    key_t          __key;    /* shmget(2) に与えられるキー */
+    uid_t          \fBuid\fP;      /* 所有者の実効 UID */
+    gid_t          \fBgid\fP;      /* 所有者の実効 GID */
+    uid_t          cuid;     /* 作成者の実効 UID */
+    gid_t          cgid;     /* 作成者の実効 GID */
+    unsigned short \fBmode\fP;     /* \fB許可\fP + SHM_DEST と
+                                SHM_LOCKED フラグ */
+    unsigned short __seq;    /* シーケンス番号 */
+};
+.EE
+.in
+.PP
+The least significant 9 bits of the \fImode\fP field of the \fIipc_perm\fP
+structure define the access permissions for the shared memory segment.  The
+permission bits are as follows:
+.TS
+l l.
+0400   Read by user
+0200   Write by user
+0040   Read by group
+0020   Write by group
+0004   Read by others
+0002   Write by others
+.TE
+.PP
+Bits 0100, 0010, and 0001 (the execute bits) are unused by the system.  (It
+is not necessary to have execute permission on a segment in order to perform
+a \fBshmat\fP(2)  call with the \fBSHM_EXEC\fP flag.)
+.PP
+\fIcmd\fP として有効な値は以下の通り:
+.TP 
+\fBIPC_STAT\fP
+\fIshmid\fP に関連づけられたカーネルデータ構造体の情報を \fIbuf\fP で指された \fIshmid_ds\fP 構造体にコピーする。
+呼び出し元は共有メモリーセグメントに対する 読み込み許可を持たなければならない。
+.TP 
+\fBIPC_SET\fP
+Write the values of some members of the \fIshmid_ds\fP structure pointed to by
+\fIbuf\fP to the kernel data structure associated with this shared memory
+segment, updating also its \fIshm_ctime\fP member.
+.IP
+以下のフィールドが更新される: \fIshm_perm.uid\fP, \fIshm_perm.gid\fP および \fIshm_perm.mode\fP (の下位 9
+ビット)。
+.IP
+The effective UID of the calling process must match the owner
+(\fIshm_perm.uid\fP)  or creator (\fIshm_perm.cuid\fP)  of the shared memory
+segment, or the caller must be privileged.
+.TP 
+\fBIPC_RMID\fP
+セグメントに破棄済みのマークを付ける。 セグメントは、実際には最後プロセスがセグメントを分離した (関連する \fIshmid_ds\fP 構造体の
+\fIshm_nattch\fP メンバーが 0 になった) 後でのみ破棄される。
+呼び出し元はそのセグメントの所有者か作成者であるか、特権を持たなければならない。 \fIbuf\fP 引き数は無視される。
+.IP
+セグメントに破棄のマークが付けられると、 関連するデータ構造体において \fIshm_perm.mode\fP フィールドの (標準ではない)
+\fBSHM_DEST\fP フラグが設定される。 このデータ構造体は \fBIPC_STAT\fP で取得される。
+.IP
+呼び出し元は最終的にはセグメントを忘れずに破棄\fIしなければならない\fP。 そうでなれば、フォールト (fault) されたページは メモリーかスワップ
+(swap) に残り続ける。
+.IP
+\fBproc\fP(5) の \fI/proc/sys/kernel/shm_rmid_forced\fP の説明も参照のこと。
+.TP 
+\fBIPC_INFO\fP (Linux 固有)
+システム全体での共有メモリーの制限とパラメーターに関する情報を、 \fIbuf\fP が指す構造体に入れて返す。 この構造体は \fIshminfo\fP 型である
+(そのためキャストが必要である)。 \fIshminfo\fP は \fB_GNU_SOURCE\fP 機能検査マクロが定義された場合に
+\fI<sys/shm.h>\fP で以下のように定義される:
+.IP
+.in +4n
+.EX
+struct  shminfo {
+    unsigned long shmmax; /* 最大セグメントサイズ */
+    unsigned long shmmin; /* 最小セグメントサイズ。
+                             常に 1 */
+    unsigned long shmmni; /* 最大セグメント数 */
+    unsigned long shmseg; /* プロセスが付加できる
+                             セグメントの最大数。
+                             カーネル内では未使用 */
+    unsigned long shmall; /* 共有メモリーの最大ページ数。
+                             システム全体での値 */
+};
+.EE
+.in
+.IP
+設定 \fIshmmni\fP, \fIshmmax\fP, \fIshmall\fP は \fI/proc\fP にある同じ名前のファイル経由で変更可能である。 詳しくは
+\fBproc\fP(5)  を参照。
+.TP 
+\fBSHM_INFO\fP (Linux 固有)
+共有メモリーが消費しているシステム資源に関する情報を 格納した \fIshm_info\fP 構造体を返す。 この構造体は、 \fB_GNU_SOURCE\fP
+機能検査マクロが定義された場合に \fI<sys/shm.h>\fP で以下のように定義される:
+.IP
+.in +4n
+.EX
+struct shm_info {
+    int           used_ids; /* 現在存在するセグメント数 */
+    unsigned long shm_tot;  /* 共有メモリーのページ総数 */
+    unsigned long shm_rss;  /* メモリー上にある (スワップされて
+                               いない) 共有メモリーページ数 */
+    unsigned long shm_swp;  /* スワップされている共有メモリー
+                               ページ数 */
+    unsigned long swap_attempts;
+                            /* Linux 2.4 以降では未使用 */
+    unsigned long swap_successes;
+                            /* Linux 2.4 以降では未使用 */
+};
+.EE
+.in
+.TP 
+\fBSHM_STAT\fP (Linux 固有)
+\fBIPC_STAT\fP と同じく \fIshmid_ds\fP 構造体を返す。 但し、 \fIshmid\fP
+引き数は、セグメント識別子ではなく、システム上の全ての共有メモリー セグメントに関する情報を管理するカーネルの内部配列へのインデックス である。
+.TP 
+\fBSHM_STAT_ANY\fP (Linux\-specific, Linux 4.17 以降)
+Return a \fIshmid_ds\fP structure as for \fBSHM_STAT\fP.  However,
+\fIshm_perm.mode\fP is not checked for read access for \fIshmid\fP, meaning that
+any user can employ this operation (just as any user may read
+\fI/proc/sysvipc/shm\fP to obtain the same information).
+.PP
+呼び出し元は、\fIcmd\fP に以下の値を指定することで、共有メモリーセグメントが スワップされることを防止したり、許可したりできる:
+.TP 
+\fBSHM_LOCK\fP (Linux 固有)
+共有メモリーセグメントをスワップすることを防止する。 ロックが有効になった後、呼び出し元は、
+存在することが要求された全てのページをフォールトさせなければならない。 セグメントがロックされると、 関連するデータ構造体において
+\fIshm_perm.mode\fP フィールドの (標準的ではない)  \fBSHM_LOCKED\fP フラグが設定される。 このデータ構造体は
+\fBIPC_STAT\fP で取得される。
+.TP 
+\fBSHM_UNLOCK\fP (Linux 固有)
+セグメントのロックを解除し、スワップアウトすることを可能にする。
+.PP
+.\" There was some weirdness in 2.6.9: SHM_LOCK and SHM_UNLOCK could
+.\" be applied to a segment, regardless of ownership of the segment.
+.\" This was a botch-up in the move to RLIMIT_MEMLOCK, and was fixed
+.\" in 2.6.10.  MTK, May 2005
+2.6.10 より前のカーネルでは、特権プロセスだけが \fBSHM_LOCK\fP と \fBSHM_UNLOCK\fP を利用することができた。 2.6.10
+以降のカーネルでは、非特権プロセスであっても次の条件を満たせば これらの操作を利用することができる。その条件とは、プロセスの実効 UID
+がそのセグメントの所有者もしくは作成者の UID と一致し、 (\fBSHM_LOCK\fP の場合には) ロックするメモリーの合計が
+\fBRLIMIT_MEMLOCK\fP リソース上限 (\fBsetrlimit\fP(2)  参照) の範囲内に入っていることである。
+.SH 返り値
+\fBIPC_INFO\fP と \fBSHM_INFO\fP 操作は、成功すると、全ての共有メモリーセグメントに関する情報を
+管理しているカーネルの内部配列の使用中エントリーのインデックスの うち最大値を返す (この情報は、システムの全ての共有メモリーセグメントに関する情報を
+取得するために、操作 \fBSHM_STAT\fP か \fBSHM_STAT_ANY\fP を繰り返し実行する際に使用できる)。 \fBSHM_STAT\fP
+操作は、成功すると、 \fIshmid\fP で指定されたインデックスを持つ共有メモリーセグメントの識別子を返す。 他の操作は、成功の場合 0 を返す。
+.PP
+エラーの場合は \-1 を返し、 \fIerrno\fP を適切に設定する。
+.SH エラー
+.TP 
+\fBEACCES\fP
+\fBIPC_STAT\fP or \fBSHM_STAT\fP is requested and \fIshm_perm.mode\fP does not allow
+read access for \fIshmid\fP, and the calling process does not have the
+\fBCAP_IPC_OWNER\fP capability in the user namespace that governs its IPC
+namespace.
+.TP 
+\fBEFAULT\fP
+\fIcmd\fP 引き数に \fBIPC_SET\fP か \fBIPC_STAT\fP が指定されたが \fIbuf\fP で指されているアドレスにアクセスできない。
+.TP 
+\fBEIDRM\fP
+\fIshmid\fP が削除 (remove) された識別子 (identifier) を指している。
+.TP 
+\fBEINVAL\fP
+\fIshmid\fP が有効な識別子でないか、 \fIcmd\fP が有効なコマンドでない。 もしくは、操作 \fBSHM_STAT\fP か
+\fBSHM_STAT_ANY\fP の場合に、 \fIshmid\fP で指定されたインデックス値が現在未使用の配列のスロットを参照していた。
+.TP 
+\fBENOMEM\fP
+(2.6.9 以降のカーネルにおいて)  \fBSHM_LOCK\fP が指定され、 ロックされる予定のセグメントのサイズ
+(ロックされる共有メモリーセグメントの合計バイト数) が、 呼び出したプロセスの実ユーザー ID についての制限を超えた。 この制限は
+\fBRLIMIT_MEMLOCK\fP ソフト資源制限で定義される (\fBsetrlimit\fP(2)  を参照)。
+.TP 
+\fBEOVERFLOW\fP
+\fBIPC_STAT\fP が試みられ、GID や UID の値が \fIbuf\fP で指示される構造体に格納するには大き過ぎる。
+.TP 
+\fBEPERM\fP
+\fBIPC_SET\fP か \fBIPC_RMID\fP が試みられ、 呼び出したプロセスの実効ユーザー ID が作成者 (\fIshm_perm.cuid\fP)
+でも所有者 (\fIshm_perm.uid\fP)  でもなく、プロセスが特権を持たない (Linux では \fBCAP_SYS_ADMIN\fP
+ケーパビリティを持たない)。
+.IP
+または (2.6.9 より前のカーネルで)  \fBSHM_LOCK\fP または \fBSHM_UNLOCK\fP が指定されているが、プロセスが特権を持たない
+(Linux では \fBCAP_IPC_LOCK\fP ケーパビリティを持たない)。 (Linux 2.6.9 以降では、
+\fBRLIMIT_MEMLOCK\fP が 0 で呼び出し元が特権を持たない場合にも、このエラーが起こる。)
+.SH 準拠
+.\" SVr4 documents additional error conditions EINVAL,
+.\" ENOENT, ENOSPC, ENOMEM, EEXIST.  Neither SVr4 nor SVID documents
+.\" an EIDRM error condition.
+POSIX.1\-2001, POSIX.1\-2008, SVr4.
+.SH 注意
+.\" Like Linux, the FreeBSD man pages still document
+.\" the inclusion of these header files.
+Linux や POSIX の全てのバージョンでは、 \fI<sys/types.h>\fP と \fI<sys/ipc.h>\fP
+のインクルードは必要ない。しかしながら、いくつかの古い実装ではこれらのヘッダーファイルのインクルードが必要であり、 SVID
+でもこれらのインクルードをするように記載されている。このような古いシステムへの移植性を意図したアプリケーションではこれらのファイルをインクルードする必要があるかもしれない。
+.PP
+\fBIPC_INFO\fP, \fBSHM_STAT\fP, \fBSHM_INFO\fP 操作は、 \fBipcs\fP(1)
+プログラムで割り当て済の資源に関する情報を提供するために 使用されている。将来、これらの操作は変更されたり、 \fI/proc\fP
+ファイルシステムのインターフェースに移動されるかもしれない。
+.PP
+Linux では、 \fIshmctl(IPC_RMID)\fP を使ってすでに削除マークがつけられている共有メモリーセグメントを あるプロセスが付加
+(attach)  (\fBshmat\fP(2))  することを許可している。 この機能は他の UNIX の実装では利用できない。
+移植性を考慮したアプリケーションではこれに依存しないようにすべきである。
+.PP
+\fI構造体 shmid_ds\fP 内の多くのフィールドは、 Linux 2.2 では \fIshort\fP 型だったが、Linux 2.4 では
+\fIlong\fP 型になった。 この利点を生かすには、glibc\-2.1.91 以降の環境下で 再コンパイルすれば十分である。
+カーネルは新しい形式の呼び出しと古い形式の呼び出しを \fIcmd\fP 内の \fBIPC_64\fP フラグで区別する。
+.SH 関連項目
+\fBmlock\fP(2), \fBsetrlimit\fP(2), \fBshmget\fP(2), \fBshmop\fP(2), \fBcapabilities\fP(7),
+\fBsysvipc\fP(7)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
diff --git a/manual/LDP_man-pages/draft/man2/shmget.2 b/manual/LDP_man-pages/draft/man2/shmget.2
new file mode 100644 (file)
index 0000000..3b5b990
--- /dev/null
@@ -0,0 +1,262 @@
+.\" Copyright (c) 1993 Luigi P. Bai (lpb@softint.com) July 28, 1993
+.\"
+.\" %%%LICENSE_START(VERBATIM)
+.\" Permission is granted to make and distribute verbatim copies of this
+.\" manual provided the copyright notice and this permission notice are
+.\" preserved on all copies.
+.\"
+.\" Permission is granted to copy and distribute modified versions of this
+.\" manual under the conditions for verbatim copying, provided that the
+.\" entire resulting derived work is distributed under the terms of a
+.\" permission notice identical to this one.
+.\"
+.\" Since the Linux kernel and libraries are constantly changing, this
+.\" manual page may be incorrect or out-of-date.  The author(s) assume no
+.\" responsibility for errors or omissions, or for damages resulting from
+.\" the use of the information contained herein.  The author(s) may not
+.\" have taken the same level of care in the production of this manual,
+.\" which is licensed free of charge, as they might when working
+.\" professionally.
+.\"
+.\" Formatted or processed versions of this manual, if unaccompanied by
+.\" the source, must acknowledge the copyright and authors of this work.
+.\" %%%LICENSE_END
+.\"
+.\" Modified Wed Jul 28 10:57:35 1993, Rik Faith <faith@cs.unc.edu>
+.\" Modified Sun Nov 28 16:43:30 1993, Rik Faith <faith@cs.unc.edu>
+.\"          with material from Giorgio Ciucci <giorgio@crcc.it>
+.\" Portions Copyright 1993 Giorgio Ciucci <giorgio@crcc.it>
+.\" Modified Tue Oct 22 22:03:17 1996 by Eric S. Raymond <esr@thyrsus.com>
+.\" Modified, 8 Jan 2003, Michael Kerrisk, <mtk.manpages@gmail.com>
+.\"    Removed EIDRM from errors - that can't happen...
+.\" Modified, 27 May 2004, Michael Kerrisk <mtk.manpages@gmail.com>
+.\"     Added notes on capability requirements
+.\" Modified, 11 Nov 2004, Michael Kerrisk <mtk.manpages@gmail.com>
+.\"    Language and formatting clean-ups
+.\"    Added notes on /proc files
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
+.\"         all rights reserved.
+.\" Translated 1997-03-01, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
+.\" Updated & Modified 2001-06-03, Yuichi SATO <ysato@h4.dion.ne.jp>
+.\" Updated 2001-12-22, Kentaro Shirakata <argrath@ub32.org>
+.\" Updated 2002-10-16, Kentaro Shirakata <argrath@ub32.org>
+.\" Updated 2003-02-23, Kentaro Shirakata <argrath@ub32.org>
+.\" Updated 2005-03-02, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
+.\" Updated 2005-11-04, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
+.\" Updated 2006-07-21, Akihiro MOTOKI, LDP v2.36
+.\" Updated 2013-05-06, Akihiro MOTOKI <amotoki@gmail.com>
+.\" Updated 2013-07-24, Akihiro MOTOKI <amotoki@gmail.com>
+.\"
+.TH SHMGET 2 2020\-04\-11 Linux "Linux Programmer's Manual"
+.SH 名前
+shmget \- System V 共有メモリーセグメントを割り当てる
+.SH 書式
+.ad l
+\fB#include <sys/ipc.h>\fP
+.br
+\fB#include <sys/shm.h>\fP
+.PP
+\fBint shmget(key_t \fP\fIkey\fP\fB, size_t \fP\fIsize\fP\fB, int \fP\fIshmflg\fP\fB);\fP
+.ad b
+.SH 説明
+\fBshmget\fP()  returns the identifier of the System\ V shared memory segment
+associated with the value of the argument \fIkey\fP.  It may be used either to
+obtain the identifier of a previously created shared memory segment (when
+\fIshmflg\fP is zero and \fIkey\fP does not have the value \fBIPC_PRIVATE\fP), or to
+create a new set.
+.PP
+\fIkey\fP の値が \fBIPC_PRIVATE\fP の場合、もしくは \fIkey\fP に対応する共有メモリーセグメントが存在せず、 \fIshmflg\fP に
+\fBIPC_CREAT\fP が指定されていた場合、 新しい共有メモリーセグメントを作成する。 作成される共有メモリーセグメントは、 \fIsize\fP
+引き数の値を \fBPAGE_SIZE\fP の倍数へと切り上げた (round up) 大きさとなる。
+.PP
+\fIshmflg\fP に \fBIPC_CREAT\fP と \fBIPC_EXCL\fP の両方が指定された場合、 \fIkey\fP
+に対応する共有メモリーセグメントが既に存在すると、 \fBshmget\fP()  は失敗し、 \fIerrno\fP に \fBEEXIST\fP が設定される
+(これは \fBopen\fP(2)  に \fBO_CREAT | O_EXCL\fP を指定した場合の動作と同じである)。
+.PP
+\fIshmflg\fP は以下の内容から構成される:
+.TP 
+\fBIPC_CREAT\fP
+新しいセグメントを作成する。このフラグが指定されなかった場合、 \fBshmget\fP()  は \fIkey\fP に対応するセグメントを探し、
+ユーザーがそのセグメントにアクセスする許可があるかどうかをチェックする。
+.TP 
+\fBIPC_EXCL\fP
+このフラグは \fBIPC_CREAT\fP とともに使用し、 この呼び出しで確実にセグメントが作成されるようにする。 セグメントが既に存在した場合には、
+呼び出しは失敗する。
+.TP 
+\fBSHM_HUGETLB\fP (Linux 2.6 以降)
+"ヒュージページ (huge page)" を使うセグメントを割り当てる。詳細な情報は、Linux カーネルソースのファイル
+\fIDocumentation/admin\-guide/vm/hugetlbpage.rst\fP を参照。
+.TP 
+\fBSHM_HUGE_2MB\fP, \fBSHM_HUGE_1GB\fP (Linux 3.8 以降)
+.\" See https://lwn.net/Articles/533499/
+Used in conjunction with \fBSHM_HUGETLB\fP to select alternative hugetlb page
+sizes (respectively, 2\ MB and 1\ GB)  on systems that support multiple
+hugetlb page sizes.
+.IP
+More generally, the desired huge page size can be configured by encoding the
+base\-2 logarithm of the desired page size in the six bits at the offset
+\fBSHM_HUGE_SHIFT\fP.  Thus, the above two constants are defined as:
+.IP
+.in +4n
+.EX
+#define SHM_HUGE_2MB    (21 << SHM_HUGE_SHIFT)
+#define SHM_HUGE_1GB    (30 << SHM_HUGE_SHIFT)
+.EE
+.in
+.IP
+For some additional details, see the discussion of the similarly named
+constants in \fBmmap\fP(2).
+.TP 
+\fBSHM_NORESERVE\fP (Linux 2.6.15 以降)
+.\" As at 2.6.17-rc2, this flag has no effect if SHM_HUGETLB was also
+.\" specified.
+このフラグは、 \fBmmap\fP(2)  の \fBMAP_NORESERVE\fP フラグと同じ役割を果たす。
+このセグメントに対するスワップ空間の予約を行わない。 スワップ空間を予約した場合は、そのセグメントの変更が必ず成功することが
+保証される。スワップ空間の予約を行わなかった場合は、物理メモリーに空きが ないと書き込み時に \fBSIGSEGV\fP を受け取る可能性がある。
+\fBproc\fP(5)  にある \fI/proc/sys/vm/overcommit_memory\fP ファイルに関する議論も参照のこと。
+.PP
+上記のフラグに加えて、 \fIshmflg\fP の下位 9 ビットは、所有者、グループ、その他への許可を指定する。 これらのビットは \fBopen\fP(2)
+の \fImode\fP 引き数と同じ形式で同じ意味を持つ。 今のところ、システムは実行 (execute) 許可を参照しない。
+.PP
+共有メモリーセグメントが新たに作成される際、 共有メモリーセグメントの内容は 0 で初期化され、 関連情報を保持するデータ構造体 \fIshmid_ds\fP
+は以下のように初期化される。
+.IP \(bu 2
+\fIshm_perm.cuid\fP と \fIshm_perm.uid\fP に呼び出し元プロセスの実効 (effective) ユーザーID を設定する。
+.IP \(bu
+\fIshm_perm.cgid\fP と \fIshm_perm.gid\fP に呼び出し元プロセスの実効グループID を設定する。
+.IP \(bu
+\fIshm_perm.mode\fP の下位 9 ビットに \fIshmflg\fP の下位 9 ビットを設定する。
+.IP \(bu
+\fIshm_segsz\fP に \fIsize\fP の値を設定する。
+.IP \(bu
+\fIshm_lpid\fP, \fIshm_nattch\fP, \fIshm_atime\fP, \fIshm_dtime\fP に 0 を設定する。
+.IP \(bu
+\fIshm_ctime\fP に現在の時刻を設定する。
+.PP
+共有メモリーセグメントが既に存在する場合、アクセス許可の検査と、 破壊 (destruction) マークがつけられていないかのチェックが行われる。
+.SH 返り値
+成功の場合、有効な共有メモリーセグメントの識別子が返される。 エラーの場合、 \-1 が返り、 \fIerrno\fP にエラーを示す値が設定される。
+.SH エラー
+失敗した場合は \fIerrno\fP が以下のどれかに設定される:
+.TP 
+\fBEACCES\fP
+The user does not have permission to access the shared memory segment, and
+does not have the \fBCAP_IPC_OWNER\fP capability in the user namespace that
+governs its IPC namespace.
+.TP 
+\fBEEXIST\fP
+\fBIPC_CREAT\fP と \fBIPC_EXCL\fP が \fIshmflg\fP に指定されたが、 \fIkey\fP
+に対応する共有メモリーセグメントはすでに存在する。
+.TP 
+\fBEINVAL\fP
+新しいセグメントを作成しようとしたが、 \fIsize\fP が \fBSHMMIN\fP より小さいか \fBSHMMAX\fP よりも大きかった。
+.TP 
+\fBEINVAL\fP
+指定された \fIkey\fP に対応するセグメントが既に存在するが、 \fIsize\fP がそのセグメントのサイズよりも大きかった。
+.TP 
+\fBENFILE\fP
+.\" [2.6.7] shmem_zero_setup()-->shmem_file_setup()-->get_empty_filp()
+システム全体でオープンされているファイルの総数が上限に達した。
+.TP 
+\fBENOENT\fP
+指定された \fIkey\fP に対応するセグメントが存在せず、 \fBIPC_CREAT\fP も指定されていなかった。
+.TP 
+\fBENOMEM\fP
+セグメントの管理情報 (overhead) に割り当てるメモリーがなかった。
+.TP 
+\fBENOSPC\fP
+システム全体の共有メモリーセグメント数の制限 (\fBSHMMNI\fP)  に達した、または要求された \fIsize\fP のセグメントの割り当てが
+システム全体の共有メモリーサイズの制限 (\fBSHMALL\fP)  を超過した。
+.TP 
+\fBEPERM\fP
+\fBSHM_HUGETLB\fP フラグが指定されたが、呼び出し元には権限がなかった (\fBCAP_IPC_LOCK\fP ケーパビリティを持っていなかった)。
+.SH 準拠
+.\" SVr4 documents an additional error condition EEXIST.
+POSIX.1\-2001, POSIX.1\-2008, SVr4.
+.PP
+\fBSHM_HUGETLB\fP と \fBSHM_NORESERVE\fP は Linux での拡張である。
+.SH 注意
+.\" Like Linux, the FreeBSD man pages still document
+.\" the inclusion of these header files.
+Linux や POSIX の全てのバージョンでは、 \fI<sys/types.h>\fP と \fI<sys/ipc.h>\fP
+のインクルードは必要ない。しかしながら、いくつかの古い実装ではこれらのヘッダーファイルのインクルードが必要であり、 SVID
+でもこれらのインクルードをするように記載されている。このような古いシステムへの移植性を意図したアプリケーションではこれらのファイルをインクルードする必要があるかもしれない。
+.PP
+.\"
+\fBIPC_PRIVATE\fP はフラグではなく \fIkey_t\fP 型である。 この特別な値が \fIkey\fP に使用された場合は、 \fBshmget\fP()
+は \fIshmflg\fP の下位 9 ビットを除いた全てを無視し、 新しい共有メモリーセグメントを作成する。
+.SS 共有メモリーの上限
+\fBshmget\fP()  コールに影響する共有メモリーセグメント資源の制限は以下の通りである:
+.TP 
+\fBSHMALL\fP
+共有メモリーの全使用量のシステム全体での上限値。 システムページサイズが単位である。
+.IP
+.\" commit 060028bac94bf60a65415d1d55a359c3a17d5c31
+Linux では、この上限値は \fI/proc/sys/kernel/shmall\fP 経由で参照したり、変更したりできる。 Linux 3.16
+以降では、 この上限値のデフォルト値は以下のとおりである。
+.IP
+    ULONG_MAX \- 2^24
+.IP
+この値は割り当てに関する上限としては適用されない (なお、この値は 32 ビットシステムにも 64 ビットシステムにも適したものになっている)。
+\fBULONG_MAX\fP ではなく、この値が選ばれたのは、
+古いアプリケーションが最初に現在の値を確認せずに既存の上限をそのまま増やしてしまっても問題が起こらないようなデフォルト値を選んだからである。
+このようなアプリケーションでは、 上限を \fBULONG_MAX\fP に設定すると値がオーバーフローしてしまうことになる。
+.IP
+Linux 2.4 から Linux 3.15 では、この上限のデフォルト値は以下であった。
+.IP
+    SHMMAX / PAGE_SIZE * (SHMMNI / 16)
+.IP
+\fBSHMMAX\fP と \fBSHMMNI\fP が変更されないとすると、 この式の結果に (バイト単位の値を得るために) ページサイズを掛け算すると、
+全ての共有メモリーセグメントで使用される全メモリーの上限として、 8\ GB という値が得られる。
+.TP 
+\fBSHMMAX\fP
+1 つの共有メモリーセグメントの最大サイズ (バイト数)。
+.IP
+.\" commit 060028bac94bf60a65415d1d55a359c3a17d5c31
+Linux では、この上限値は \fI/proc/sys/kernel/shmmax\fP 経由で参照したり、変更したりできる。 Linux 3.16
+以降では、 この上限値のデフォルト値は以下のとおりである。
+.IP
+    ULONG_MAX \- 2^24
+.IP
+この値は割り当てに関する上限としては適用されない (なお、この値は 32 ビットシステムにも 64 ビットシステムにも適したものになっている)。
+(\fBULONG_MAX\fP ではなく) このデフォルト値が使われている理由については \fBSHMALL\fP の説明を参照。
+.IP
+Linux 2.2 から Linux 3.15 までは、この上限値のデフォルト値は 0x2000000 (32\ MB) であった。
+.IP
+共有メモリーセグメントの一部分だけをマッピングすることはできないので、
+使用可能なセグメントの最大サイズには仮想メモリーの総量という別の上限が適用される。 例えば、i386
+ではマッピング可能な最大セグメントの大きさはおおよそ 2.8\ GB で、 x86\-64 では上限はおおよそ 127TB である。
+.TP 
+\fBSHMMIN\fP
+共有メモリーセグメントのバイト単位の大きさの下限: 実装依存 (現在は 1 バイトだが、実質的な最小サイズは \fBPAGE_SIZE\fP である)。
+.TP 
+\fBSHMMNI\fP
+システム全体の共有メモリーセグメント数の上限値。 この上限値のデフォルトは、 Linux 2.2 以降では 128、 Linux 2.4 以降で
+4096 である。
+.IP
+.\" Kernels between 2.4.x and 2.6.8 had an off-by-one error that meant
+.\" that we could create one more segment than SHMMNI -- MTK
+.\" This /proc file is not available in Linux 2.2 and earlier -- MTK
+Linux では、この上限値は \fI/proc/sys/kernel/shmmni\fP 経由で参照したり、変更したりできる。
+.PP
+プロセス当りの共有メモリーセグメントの個数の最大値 (\fBSHMSEG\fP)  に関する実装上の制限はない。
+.SS "Linux での注意"
+バージョン 2.3.30 までは、Linux は 削除が予定されている共有メモリーセグメントに対して \fBshmget\fP()  が行われると
+\fBEIDRM\fP を返していた。
+.SH バグ
+\fBIPC_PRIVATE\fP という名前を選んだのはおそらく失敗であろう。 \fBIPC_NEW\fP の方がより明確にその機能を表しているだろう。
+.SH 例
+\fBshmop\fP(2) を参照。
+.SH 関連項目
+\fBmemfd_create\fP(2), \fBshmat\fP(2), \fBshmctl\fP(2), \fBshmdt\fP(2), \fBftok\fP(3),
+\fBcapabilities\fP(7), \fBshm_overview\fP(7), \fBsysvipc\fP(7)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
diff --git a/manual/LDP_man-pages/draft/man2/shmop.2 b/manual/LDP_man-pages/draft/man2/shmop.2
new file mode 100644 (file)
index 0000000..d3afba1
--- /dev/null
@@ -0,0 +1,389 @@
+.\" Copyright 1993 Giorgio Ciucci (giorgio@crcc.it)
+.\" and Copyright 2020 Michael Kerrisk <mtk.manpages@gmail.com>
+.\"
+.\" %%%LICENSE_START(VERBATIM)
+.\" Permission is granted to make and distribute verbatim copies of this
+.\" manual provided the copyright notice and this permission notice are
+.\" preserved on all copies.
+.\"
+.\" Permission is granted to copy and distribute modified versions of this
+.\" manual under the conditions for verbatim copying, provided that the
+.\" entire resulting derived work is distributed under the terms of a
+.\" permission notice identical to this one.
+.\"
+.\" Since the Linux kernel and libraries are constantly changing, this
+.\" manual page may be incorrect or out-of-date.  The author(s) assume no
+.\" responsibility for errors or omissions, or for damages resulting from
+.\" the use of the information contained herein.  The author(s) may not
+.\" have taken the same level of care in the production of this manual,
+.\" which is licensed free of charge, as they might when working
+.\" professionally.
+.\"
+.\" Formatted or processed versions of this manual, if unaccompanied by
+.\" the source, must acknowledge the copyright and authors of this work.
+.\" %%%LICENSE_END
+.\"
+.\" Modified Sun Nov 28 17:06:19 1993, Rik Faith (faith@cs.unc.edu)
+.\"          with material from Luigi P. Bai (lpb@softint.com)
+.\" Portions Copyright 1993 Luigi P. Bai
+.\" Modified Tue Oct 22 22:04:23 1996 by Eric S. Raymond <esr@thyrsus.com>
+.\" Modified, 5 Jan 2002, Michael Kerrisk <mtk.manpages@gmail.com>
+.\" Modified, 19 Sep 2002, Michael Kerrisk <mtk.manpages@gmail.com>
+.\"    Added SHM_REMAP flag description
+.\" Modified, 27 May 2004, Michael Kerrisk <mtk.manpages@gmail.com>
+.\"     Added notes on capability requirements
+.\" Modified, 11 Nov 2004, Michael Kerrisk <mtk.manpages@gmail.com>
+.\"    Language and formatting clean-ups
+.\"    Changed wording and placement of sentence regarding attachment
+.\"            of segments marked for destruction
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
+.\"         all rights reserved.
+.\" Translated 1999-08-15, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
+.\" Updated & Modified 2002-05-07, Yuichi SATO <ysato@h4.dion.ne.jp>
+.\" Updated & Modified 2003-01-18, Yuichi SATO <ysato444@yahoo.co.jp>
+.\" Updated & Modified 2005-01-07, Yuichi SATO
+.\" Updated 2005-12-05, Akihiro MOTOKI, Catch up to LDP man-pages 2.16
+.\" Updated 2006-04-14, Akihiro MOTOKI, Catch up to LDP man-pages 2.29
+.\" Updated 2013-03-26, Akihiro MOTOKI <amotoki@gmail.com>
+.\" Updated 2013-05-01, Akihiro MOTOKI <amotoki@gmail.com>
+.\" Updated 2013-07-24, Akihiro MOTOKI <amotoki@gmail.com>
+.\"
+.TH SHMOP 2 2020\-04\-11 Linux "Linux Programmer's Manual"
+.SH 名前
+shmat, shmdt \- System V 共有メモリー (shared memory) の操作
+.SH 書式
+.nf
+\fB#include <sys/types.h>\fP
+\fB#include <sys/shm.h>\fP
+.PP
+\fBvoid *shmat(int \fP\fIshmid\fP\fB, const void *\fP\fIshmaddr\fP\fB, int \fP\fIshmflg\fP\fB);\fP
+.PP
+\fBint shmdt(const void *\fP\fIshmaddr\fP\fB);\fP
+.fi
+.SH 説明
+.SS shmat()
+\fBshmat\fP()  は \fIshmid\fP で指定された System\ V 共有メモリーセグメント (shared memory segment)
+を コールしたプロセスのアドレス空間に付加 (attach) する。 付加するアドレスは \fIshmaddr\fP に以下のどれかの形式で指定する:
+.IP \(bu 2
+\fIshmaddr\fP が NULL ならば、システムはセグメントを付加するための 適切な (使用されていない) ページ境界のアドレスを選択する。
+.IP \(bu
+\fIshmaddr\fP が NULL でなく \fBSHM_RND\fP が \fIshmflg\fP に指定されている場合は、 \fIshmaddr\fP を
+\fBSHMLBA\fP の倍数へと切り捨てた (rounding down) のと等しいアドレスへ付加する。
+.IP \(bu
+その他の場合は \fIshmaddr\fP は付加を行なうアドレスで、ページ境界を指している必要がある。
+.PP
+\fBSHM_RND\fP に加えて、以下のフラグを \fIshmflg\fP ビットマスク引き数に指定できる。
+.TP 
+\fBSHM_EXEC\fP (Linux 固有; Linux 2.6.9 以降)
+セグメントの内容を実行できる。 呼び出し元はセグメントに対する実行許可を持っていなければならない。
+.TP 
+\fBSHM_RDONLY\fP
+セグメントを読み込み専用に付加する。 プロセスはそのセグメントへの読み込み許可を持っていなければならない。
+このフラグが指定されなかった場合、そのセグメントは読み込みと書き込みアクセスのために付加され、
+プロセスはそのセグメントに読み込みと書き込みの許可を持っていなければならない。 書き込み専用の共有メモリーセグメントという概念は存在しない。
+.TP 
+\fBSHM_REMAP\fP (Linux 固有)
+このフラグは、 セグメントのマッピングを既存のマッピングに置き換えることを指示する。 マッピングの範囲は、 \fIshmaddr\fP
+から始まりセグメントのサイズ分だけある (通常 \fBEINVAL\fP エラーは、このアドレス範囲にマッピングが既に存在するために起る)。
+このフラグを指定する場合は、 \fIshmaddr\fP が NULL であってはならない。
+.PP
+呼び出したプロセスの \fBbrk\fP(2)  の値は付加によって変化しない。 そのセグメントはプロセスが終了 (exit) したら自動的に分離
+(detach) される。 同じセグメントをプロセスのアドレス空間に、読み込み専用および読み書き両用 として付加でき、また複数回付加することもできる。
+.PP
+成功した \fBshmat\fP()  コールは共有メモリーセグメントに関連する \fIshmid_ds\fP 構造体 (\fBshmctl\fP(2)  を参照)
+のメンバーを以下のように更新する:
+.IP \(bu 2
+\fIshm_atime\fP には現在の時刻を設定する。
+.IP \(bu
+\fIshm_lpid\fP には呼び出したプロセスのプロセス ID が設定される。
+.IP \(bu
+.\"
+\fIshm_nattch\fP を 1 増加させる。
+.SS shmdt()
+\fBshmdt\fP()  は呼び出したプロセスのアドレス空間から \fIshmaddr\fP で指定されたアドレスに配置された共有メモリーセグメントを分離
+(detach) する。 分離する共有メモリーセグメントは、現在 \fIshmaddr\fP に付加されているものでなければならない。 \fIshmaddr\fP
+は、それを付加した時に \fBshmat\fP()  が返した値に等しくなければならない。
+.PP
+成功した \fBshmdt\fP()  コールはその共有メモリーセグメントに関連する \fIshmid_ds\fP 構造体のメンバーを以下のように更新する:
+.IP \(bu 2
+\fIshm_dtime\fP には現在の時刻が設定される。
+.IP \(bu
+\fIshm_lpid\fP には呼び出したプロセスのプロセス ID が設定される。
+.IP \(bu
+\fIshm_nattch\fP を 1 減少させる。 もし 0 になり、削除マークがあった場合は そのセグメントは削除される。
+.SH 返り値
+\fBshmat\fP()  は、成功した場合、 付加された共有メモリーセグメントのアドレスを返す。 エラーの場合、 \fI(void\ *)\ \-1\fP
+を返し、 \fIerrno\fP にエラーの原因を示す値を設定する。
+.PP
+\fBshmdt\fP()  は、成功すると 0 を返す。 エラーの場合、\-1 を返し、 \fIerrno\fP にエラーの原因を示す値を設定する。
+.SH エラー
+\fBshmat\fP()  が失敗した場合、 \fIerrno\fP に以下の値のどれかを設定して返す:
+.TP 
+\fBEACCES\fP
+The calling process does not have the required permissions for the requested
+attach type, and does not have the \fBCAP_IPC_OWNER\fP capability in the user
+namespace that governs its IPC namespace.
+.TP 
+\fBEIDRM\fP
+\fIshmid\fP が削除 (remove) された識別子 (identifier) を指している。
+.TP 
+\fBEINVAL\fP
+\fIshmid\fP の値が不正である。 \fIshmaddr\fP の値が境界違反 (unaligned) (つまり、ページ境界に合っておらず、
+\fBSHM_RND\fP が指定されていない) または が不正である。 \fIshmaddr\fP へのセグメントの付加に失敗した。 または
+\fBSHM_REMAP\fP が指定されているが、 \fIshmaddr\fP が NULL であった。
+.TP 
+\fBENOMEM\fP
+ディスクリプター (descriptor) やページテーブルのためのメモリーを 割り当てることができない。
+.PP
+\fBshmdt\fP()  が失敗した場合、 \fBEINVAL\fP は以下のようにセットされる:
+.TP 
+\fBEINVAL\fP
+.\" The following since 2.6.17-rc1:
+\fIshmaddr\fP に付加された共有メモリーセグメントが存在しない。 もしくは、 \fIshmaddr\fP がページ境界に合っていない。
+.SH 準拠
+.\" SVr4 documents an additional error condition EMFILE.
+POSIX.1\-2001, POSIX.1\-2008, SVr4.
+.PP
+SVID 3 で (たぶんそれより前だと思うが)  \fIshmaddr\fP 引き数の型は \fIchar\ *\fP から \fIconst void\ *\fP
+に、\fIshmat\fP() の返り値の型は \fIchar\ *\fP から \fIvoid\ *\fP に変更された。
+.SH 注意
+\fBfork\fP(2)  した後、子プロセスは付加された共有メモリーセグメントを継承する。
+.PP
+\fBexec\fP(2)  した後、全ての付加された共有メモリーセグメントはプロセスから分離される。
+.PP
+\fBexit\fP(2)  において、全ての付加された共有メモリーセグメントはプロセスから分離される。
+.PP
+共有メモリーセグメントを付加する場合の移植性の高い方法としては、 \fIshmaddr\fP を NULL にして \fBshmat\fP()
+を使用するのがよい。 このような方法で付加される共有メモリーセグメントは、 プロセスが異なれば別のアドレスに付加される、という点に注意すること。
+よって共有メモリー内で管理されるポインターは、 絶対アドレスではなく、 (一般的にはセグメントの開始アドレスからの)
+相対アドレスで作成するべきである。
+.PP
+Linux では共有メモリーセグメントに既に削除マークが付けられていても、 その共有メモリーセグメントを付加することができる。 しかし POSIX.1
+ではこのような動作を指定しておらず、 他の多くの実装もこれをサポートしていない。
+.PP
+以下のシステムパラメーターは、 \fBshmat\fP()  に影響する:
+.TP 
+\fBSHMLBA\fP
+セグメントの下限アドレス倍数 (Segment low boundary address multiple)。 \fBshmat\fP()
+の呼び出しにおいて付加するアドレスを明示的に指定する際、 呼び出し元は指定するアドレスがこの値の倍数になるように保証しなければならない。
+これはいくつかのアーキテクチャーでは必要なことで、 CPU キャッシュの性能を保証するためであったり、 同じセグメントの別の付与を CPU
+キャッシュ内部で一貫して扱えるようにするためだったりする。 \fBSHMLBA\fP は通常はシステムページサイズの倍数である (Linux
+の多くのアーキテクチャーでは \fBSHMLBA\fP はシステムページサイズと同じである)。
+.PP
+現在の実装では、プロセスごとの 共有メモリーセグメントの最大数 (\fBSHMSEG\fP)  に関する実装依存の制限はない。
+.SH 例
+The two programs shown below exchange a string using a shared memory
+segment.  Further details about the programs are given below.  First, we
+show a shell session demonstrating their use.
+.PP
+In one terminal window, we run the "reader" program, which creates a System
+V shared memory segment and a System V semaphore set.  The program prints
+out the IDs of the created objects, and then waits for the semaphore to
+change value.
+.PP
+.in +4n
+.EX
+$ \fB./svshm_string_read\fP
+shmid = 1114194; semid = 15
+.EE
+.in
+.PP
+In another terminal window, we run the "writer" program.  The "writer"
+program takes three command\-line arguments: the IDs of the shared memory
+segment and semaphore set created by the "reader", and a string.  It
+attaches the existing shared memory segment, copies the string to the shared
+memory, and modifies the semaphore value.
+.PP
+.in +4n
+.EX
+$ \fB./svshm_string_write 1114194 15 \(aqHello, world\(aq\fP
+.EE
+.in
+.PP
+Returning to the terminal where the "reader" is running, we see that the
+program has ceased waiting on the semaphore and has printed the string that
+was copied into the shared memory segment by the writer:
+.PP
+.in +4n
+.EX
+Hello, world
+.EE
+.in
+.\"
+.SS "プログラムのソース: svshm_string.h"
+The following header file is included by the "reader" and "writer" programs.
+.PP
+.in +4n
+.EX
+#include <sys/types.h>
+#include <sys/ipc.h>
+#include <sys/shm.h>
+#include <sys/sem.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \e
+                        } while (0)
+
+union semun {                   /* Used in calls to semctl() */
+    int                 val;
+    struct semid_ds *   buf;
+    unsigned short *    array;
+#if defined(__linux__)
+    struct seminfo *    __buf;
+#endif
+};
+
+#define MEM_SIZE 4096
+.EE
+.in
+.\"
+.SS "プログラムのソース: svshm_string_read.c"
+The "reader" program creates a shared memory segment and a semaphore set
+containing one semaphore.  It then attaches the shared memory object into
+its address space and initializes the semaphore value to 1.  Finally, the
+program waits for the semaphore value to become 0, and afterwards prints the
+string that has been copied into the shared memory segment by the "writer".
+.PP
+.in +4n
+.EX
+/* svshm_string_read.c
+
+   Licensed under GNU General Public License v2 or later.
+*/
+#include "svshm_string.h"
+
+int
+main(int argc, char *argv[])
+{
+    int semid, shmid;
+    union semun arg, dummy;
+    struct sembuf sop;
+    char *addr;
+
+    /* Create shared memory and semaphore set containing one
+       semaphore */
+
+    shmid = shmget(IPC_PRIVATE, MEM_SIZE, IPC_CREAT | 0600);
+    if (shmid == \-1)
+        errExit("shmget");
+
+    semid = semget(IPC_PRIVATE, 1, IPC_CREAT | 0600);
+    if (shmid == \-1)
+        errExit("shmget");
+
+    /* Attach shared memory into our address space */
+
+    addr = shmat(shmid, NULL, SHM_RDONLY);
+    if (addr == (void *) \-1)
+        errExit("shmat");
+
+    /* Initialize semaphore 0 in set with value 1 */
+
+    arg.val = 1;
+    if (semctl(semid, 0, SETVAL, arg) == \-1)
+        errExit("semctl");
+
+    printf("shmid = %d; semid = %d\en", shmid, semid);
+
+    /* Wait for semaphore value to become 0 */
+
+    sop.sem_num = 0;
+    sop.sem_op = 0;
+    sop.sem_flg = 0;
+
+    if (semop(semid, &sop, 1) == \-1)
+        errExit("semop");
+
+    /* Print the string from shared memory */
+
+    printf("%s\en", addr);
+
+    /* Remove shared memory and semaphore set */
+
+    if (shmctl(shmid, IPC_RMID, NULL) == \-1)
+        errExit("shmctl");
+    if (semctl(semid, 0, IPC_RMID, dummy) == \-1)
+        errExit("semctl");
+
+    exit(EXIT_SUCCESS);
+}
+.EE
+.in
+.\"
+.SS "プログラムのソース: svshm_string_write.c"
+The writer program takes three command\-line arguments: the IDs of the shared
+memory segment and semaphore set that have already been created by the
+"reader", and a string.  It attaches the shared memory segment into its
+address space, and then decrements the semaphore value to 0 in order to
+inform the "reader" that it can now examine the contents of the shared
+memory.
+.PP
+.in +4n
+.EX
+/* svshm_string_write.c
+
+   Licensed under GNU General Public License v2 or later.
+*/
+#include "svshm_string.h"
+
+int
+main(int argc, char *argv[])
+{
+    int semid, shmid;
+    struct sembuf sop;
+    char *addr;
+    size_t len;
+
+    if (argc != 4) {
+        fprintf(stderr, "Usage: %s shmid semid string\en", argv[0]);
+        exit(EXIT_FAILURE);
+    }
+
+    len = strlen(argv[3]) + 1;  /* +1 to include trailing \(aq\e0\(aq */
+    if (len > MEM_SIZE) {
+        fprintf(stderr, "String is too big!\en");
+        exit(EXIT_FAILURE);
+    }
+
+    /* Get object IDs from command\-line */
+
+    shmid = atoi(argv[1]);
+    semid = atoi(argv[2]);
+
+    /* Attach shared memory into our address space and copy string
+       (including trailing null byte) into memory. */
+
+    addr = shmat(shmid, NULL, 0);
+    if (addr == (void *) \-1)
+        errExit("shmat");
+
+    memcpy(addr, argv[3], len);
+
+    /* Decrement semaphore to 0 */
+
+    sop.sem_num = 0;
+    sop.sem_op = \-1;
+    sop.sem_flg = 0;
+
+    if (semop(semid, &sop, 1) == \-1)
+        errExit("semop");
+
+    exit(EXIT_SUCCESS);
+}
+.EE
+.in
+.SH 関連項目
+\fBbrk\fP(2), \fBmmap\fP(2), \fBshmctl\fP(2), \fBshmget\fP(2), \fBcapabilities\fP(7),
+\fBshm_overview\fP(7), \fBsysvipc\fP(7)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
index b52723e..dc0916d 100644 (file)
@@ -124,8 +124,7 @@ I/O エラー。
 ディスク領域不足である。
 .TP 
 \fBESPIPE\fP
-\fIfd\fP refers to something other than a regular file, a block device, or a
-directory.
+\fIfd\fP が、通常のファイル、ブロックデバイス、ディレクトリ以外のものを指している。
 .SH バージョン
 \fBsync_file_range\fP()  はカーネル 2.6.17 で Linux に登場した。
 .SH 準拠
index ce60b9d..2a0b918 100644 (file)
@@ -81,7 +81,7 @@ T{
 T}     Thread safety   MT\-Safe
 .TE
 .SH 準拠
-This function is not in POSIX.1.
+この関数は POSIX.1 にはない。
 .PP
 32V, PWB, PWB.2, 3BSD, 4BSD に \fBalloca\fP()  関数が登場した証拠がある。 4.3BSD
 には、マニュアルページがある。 Linux は、GNU 版を使っている。 この関数は POSIX.1\-2001 にはない。
index e3c659c..95cc951 100644 (file)
@@ -35,9 +35,7 @@ mallinfo \- メモリー割り当て情報を取得する
 .PP
 \fBstruct mallinfo mallinfo(void);\fP
 .SH 説明
-The \fBmallinfo\fP()  function returns a copy of a structure containing
-information about memory allocations performed by \fBmalloc\fP(3)  and related
-functions.
+\fBmallinfo\fP() 関数は、 \fBmalloc\fP(3) や一連の関数により実行されたメモリー割り当てに関する情報を格納した構造体のコピーを返す。
 .PP
 Note that not all allocations are visible to \fBmallinfo\fP(); see BUGS and
 consider using \fBmalloc_info\fP(3)  instead.
@@ -135,7 +133,7 @@ enough, others modify with non\-atomically maybe not.
 .PP
 \fImallinfo\fP 構造体の各フィールドは \fIint\fP 型である。 しかし、 いくつかの内部管理用の値は \fIlong\fP 型の場合もあるので、
 報告される値が一周してしまい、 不正確になる可能性がある。
-.SH EXAMPLES
+.SH 
 以下のプログラムは \fBmallinfo\fP() を利用して、 メモリーブロックの割り当て、解放のそれぞれ前後でメモリー割り当ての統計情報を取得する。
 統計情報は標準出力に表示される。
 .PP
index e40f725..b004982 100644 (file)
@@ -39,7 +39,7 @@ malloc_get_state, malloc_set_state \- malloc 実装の状態を保存/復元す
 \fBint malloc_set_state(void *\fP\fIstate\fP\fB);\fP
 .fi
 .SH 説明
-\fINote\fP: these function are removed in glibc version 2.25.
+\fI注意\fP: これらの関数は glibc バージョン 2.25 で削除された。
 .PP
 \fBmalloc_get_state\fP() 関数は \fBmalloc\fP(3) 内部のすべての管理用変数を記録する (ただし、 ヒープの実際の内容と
 \fBmalloc_hook\fP(3) 関数ポインターの状態は記録されない)。 状態は \fBmalloc\fP(3) で動的に確保されたシステム依存の
index b9c7eaf..611478b 100644 (file)
@@ -71,7 +71,7 @@ they are now deprecated.  From glibc 2.24 onwards, the
 \fB__malloc_initialize_hook\fP variable has been removed from the API.
 Programmers should instead preempt calls to the relevant functions by
 defining and exporting functions such as "malloc" and "free".
-.SH EXAMPLES
+.SH 
 これらの変数の使い方の簡単な例を以下に示す。
 .PP
 .EX
@@ -109,7 +109,8 @@ my_malloc_hook(size_t size, const void *caller)
     /* 現在設定されているフック (underlying hook) を保存する */
     old_malloc_hook = __malloc_hook;
 
-    /* printf() might call malloc(), so protect it too. */
+    /* printf() は malloc() を呼び出す可能性があるので
+        ここでもガードを行う (元々のフックのままにしておく) */
     printf("malloc(%zu) called from %p returns %p\en",
             size, caller, result);
 
index b544922..4f1b00b 100644 (file)
@@ -77,7 +77,7 @@ T}    Thread safety   MT\-Safe
 ファイルではなくメモリー内のバッファーに直接送ることができる。
 .PP
 \fBmalloc_info\fP() 関数は、 \fBmalloc_stats\fP(3) と \fBmallinfo\fP(3) の不備を解決するために設定された。
-.SH EXAMPLES
+.SH 
 以下のプログラムは最大で 4 つのコマンドライン引数を取り、 最初の 3 つは必須である。 最初の引数は、このプログラムが生成するスレッド数を指定する。
 メインスレッドを含む全てのスレッドが第 2 引数で指定した数のメモリーブロックの割り当てを行う。 第 3 引数は割り当てるブロックのサイズを制御する。
 メインスレッドはこのサイズのブロックを作成し、 このプログラムが生成する 2 番目のスレッドはこのサイズの 2 倍のサイズのブロックを、 3
index 6ab6668..6407158 100644 (file)
 .\"*******************************************************************
 .TH MALLOC_TRIM 3 2020\-08\-13 Linux "Linux Programmer's Manual"
 .SH 名前
-malloc_trim \- release free memory from the heap
+malloc_trim \- ヒープから未使用メモリーを解放する
 .SH 書式
 \fB#include <malloc.h>\fP
 .PP
 \fBint malloc_trim(size_t \fP\fIpad\fP\fB);\fP
 .SH 説明
-The \fBmalloc_trim\fP()  function attempts to release free memory from the heap
-(by calling \fBsbrk\fP(2)  or \fBmadvise\fP(2)  with suitable arguments).
+\fBmalloc_trim\fP() 関数は (適切な引き数で \fBsbrk\fP(2) や \fBmadvise\fP(2) を呼び出して)
+ヒープの未使用メモリーの解放を試みる。
 .PP
 \fIpad\fP 引き数は、 ヒープの一番上から切り詰める際に残す未使用領域の量を指定する。 この引き数が 0 の場合、
 ヒープの一番上の最小量のメモリーだけを維持できる (つまり 1 ページかそれ未満)。 0 以外の引き数を指定すると、
index 8b2cf23..f86d659 100644 (file)
@@ -54,11 +54,10 @@ _POSIX_C_SOURCE\ >=\ 200112L
 .RE
 .ad
 .SH 説明
-The function \fBposix_fallocate\fP()  ensures that disk space is allocated for
-the file referred to by the file descriptor \fIfd\fP for the bytes in the range
-starting at \fIoffset\fP and continuing for \fIlen\fP bytes.  After a successful
-call to \fBposix_fallocate\fP(), subsequent writes to bytes in the specified
-range are guaranteed not to fail because of lack of disk space.
+関数 \fBposix_fallocate\fP()  は、ファイルディスクリプター \fIfd\fP
+で参照されるファイルに対して、ディスクスペースを確実に確保する。 ディスクスペースは \fIoffset\fP から始まる \fIlen\fP
+バイトの範囲のバイトである。 \fBposix_fallocate\fP()  の呼び出しが成功した後、指定された範囲のバイトに対する書き込みは、
+ディスクスペースの不足で失敗しないことが保証される。
 .PP
 ファイルのサイズが \fIoffset\fP+\fIlen\fP より小さい場合、ファイルはこのサイズになるように拡大される。
 それ以外の場合、ファイルサイズは変わらない。
index 2e7c8e6..08274b9 100644 (file)
@@ -78,8 +78,8 @@ glibc 向けの機能検査マクロの要件 (\fBfeature_test_macros\fP(7)  参
 glibc 2.12 以降:
 .nf
 (_XOPEN_SOURCE\ >=\ 500) && !(_POSIX_C_SOURCE\ >=\ 200112L)
-    || /* Glibc since 2.19: */ _DEFAULT_SOURCE
-    || /* Glibc versions <= 2.19: */ _SVID_SOURCE || _BSD_SOURCE
+    || /* glibc 2.19 以降: */ _DEFAULT_SOURCE
+    || /* glibc 2.19 以前: */ _SVID_SOURCE || _BSD_SOURCE
 .br
 .fi
 .TP 
@@ -137,8 +137,7 @@ POSIX.1\-2008 TC2.
 \fBENOMEM\fP
 割り当て要求を満たすのに十分なメモリーがなかった。
 .SH バージョン
-The functions \fBmemalign\fP(), \fBvalloc\fP(), and \fBpvalloc\fP()  have been
-available since at least glibc 2.0.
+関数 \fBmemalign\fP(), \fBvalloc\fP(), \fBpvalloc\fP() は少なくとも glibc 2.0 以降で使用可能である。
 .PP
 関数 \fBaligned_alloc\fP() は glibc バージョン 2.16 で追加された。
 .PP
@@ -165,15 +164,15 @@ T}        Thread safety   MT\-Unsafe init
 .TE
 .sp 1
 .SH 準拠
-The function \fBvalloc\fP()  appeared in 3.0BSD.  It is documented as being
-obsolete in 4.3BSD, and as legacy in SUSv2.  It does not appear in POSIX.1.
+関数 \fBvalloc\fP() は 3.0BSD で登場した。4.3BSD では廃止されたと記載されており、 SUSv2
+では過去の名残だと記載されている。 POSIX.1 には存在しない。
 .PP
 関数 \fBpvalloc\fP() は GNU による拡張である。
 .PP
 関数 \fBmemalign\fP() は SunOS 4.1.3 で登場したが、4.4BSD にはない。
 .PP
-The function \fBposix_memalign\fP()  comes from POSIX.1d and is specified in
-POSIX.1\-2001 and POSIX.1\-2008.
+関数 \fBposix_memalign\fP() は POSIX.1d に由来し、 POSIX.1\-2001 と POSIX.1\-2008
+で規定されている。
 .PP
 .\"
 関数 \fIaligned_alloc\fP() は C11 標準で規定されている。
@@ -184,10 +183,9 @@ POSIX.1\-2001 and POSIX.1\-2008.
 \fI<stdlib.h>\fP で宣言されている。
 .PP
 .\" Libc4,5 and
-According to SUSv2, \fBvalloc\fP()  is declared in \fI<stdlib.h>\fP.
-Glibc declares it in \fI<malloc.h>\fP, and also in
-\fI<stdlib.h>\fP if suitable feature test macros are defined (see
-above).
+SUSv2 によると、 \fBvalloc\fP() は \fI<stdlib.h>\fP で宣言される。 glibc では
+\fI<malloc.h>\fP で宣言されており、 さらに適切な機能検査マクロが定義された場合には
+\fI<stdlib.h>\fP でも宣言される(上記を参照)。
 .SH 注意
 多くのシステムでは、アラインメントに関して制限がある。例えば、 ブロックデバイスに対するダイレクト I/O に使用するバッファーには
 アラインメントに関する制限がある。 POSIX では、どんなアラインメントが必要かを知るために
diff --git a/manual/LDP_man-pages/draft/man3/shm_open.3 b/manual/LDP_man-pages/draft/man3/shm_open.3
new file mode 100644 (file)
index 0000000..cc1f138
--- /dev/null
@@ -0,0 +1,393 @@
+.\" Copyright (C) 2002, 2020 Michael Kerrisk <mtk.manpages@gmail.com>
+.\"
+.\" %%%LICENSE_START(VERBATIM)
+.\" Permission is granted to make and distribute verbatim copies of this
+.\" manual provided the copyright notice and this permission notice are
+.\" preserved on all copies.
+.\"
+.\" Permission is granted to copy and distribute modified versions of this
+.\" manual under the conditions for verbatim copying, provided that the
+.\" entire resulting derived work is distributed under the terms of a
+.\" permission notice identical to this one.
+.\"
+.\" Since the Linux kernel and libraries are constantly changing, this
+.\" manual page may be incorrect or out-of-date.  The author(s) assume no
+.\" responsibility for errors or omissions, or for damages resulting from
+.\" the use of the information contained herein.  The author(s) may not
+.\" have taken the same level of care in the production of this manual,
+.\" which is licensed free of charge, as they might when working
+.\" professionally.
+.\"
+.\" Formatted or processed versions of this manual, if unaccompanied by
+.\" the source, must acknowledge the copyright and authors of this work.
+.\" %%%LICENSE_END
+.\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
+.\" Japanese Version Copyright (c) 2002 Akihiro MOTOKI, all rights reserved.
+.\" Translated Mon Feb  2 2003 by Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
+.\" Updated 2009-02-23, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v3.19
+.\"
+.TH SHM_OPEN 3 2020\-11\-01 Linux "Linux Programmer's Manual"
+.SH 名前
+shm_open, shm_unlink \- POSIX 共有メモリーオブジェクトの作成/オープン/削除を行う
+.SH 書式
+\fB#include <sys/mman.h>\fP
+.br
+\fB#include <sys/stat.h>\fP /* mode 定数用 */
+.br
+\fB#include <fcntl.h>\fP /* O_* 定数の定義用 */
+.PP
+\fBint shm_open(const char *\fP\fIname\fP\fB, int \fP\fIoflag\fP\fB, mode_t \fP\fImode\fP\fB);\fP
+.PP
+\fBint shm_unlink(const char *\fP\fIname\fP\fB);\fP
+.PP
+\fI\-lrt\fP でリンクする。
+.SH 説明
+\fBshm_open\fP()  は、POSIX 共有メモリーオブジェクトを新規に作成/オープンしたり、 すでに存在するオブジェクトをオープンしたりする。
+POSIX 共有メモリーオブジェクトは、実際には、関係のないプロセスが 共有メモリーの同じ領域を \fBmmap\fP(2)
+するために使用することができる手段である。 \fBshm_unlink\fP()  は、逆の操作、つまり以前に \fBshm_open\fP()
+で作成されたオブジェクトの削除を行う。
+.PP
+.\" glibc allows the initial slash to be omitted, and makes
+.\" multiple initial slashes equivalent to a single slash.
+.\" This differs from the implementation of POSIX message queues.
+.\" glibc allows subdirectory components in the name, in which
+.\" case the subdirectory must exist under /dev/shm, and allow the
+.\" required permissions if a user wants to create a shared memory
+.\" object in that subdirectory.
+\fBshm_open\fP()  の動作は \fBopen\fP(2)  とよく似ている。 \fIname\fP
+で作成したりオープンしたりする共有メモリーオブジェクトを指定する。 移植性を持たせるためには、共有メモリーオブジェクトは \fI/somename\fP
+という形式の名前で識別し、 その名前は、最大で \fBNAME_MAX\fP (すなわち 255) 文字のヌル終端された文字列で、
+スラッシュで始まり、スラッシュ以外の文字が 1 文字以上続く形式 にすべきである。
+.PP
+\fIoflag\fP はビットマスクで、 \fBO_RDONLY\fP と \fBO_RDWR\fP のいずれか一方と、以下に述べる他のフラグの論理和をとったもの
+を指定する。
+.TP 
+\fBO_RDONLY\fP
+読み出しアクセス用にオブジェクトをオープンする。 このフラグを指定してオープンされた共有メモリーオブジェクトは、 読み出し (\fBPROT_READ\fP)
+アクセスでのみ \fBmmap\fP(2)  することができる。
+.TP 
+\fBO_RDWR\fP
+読み書きアクセス用にオブジェクトをオープンする。
+.TP 
+\fBO_CREAT\fP
+.\" In truth it is actually the filesystem IDs on Linux, but these
+.\" are nearly always the same as the effective IDs.  (MTK, Jul 05)
+存在しない場合、共有メモリーオブジェクトを作成する。 オブジェクトのユーザーとグループの所有権は、 呼び出し元プロセスの対応する実効 ID が使われ、
+オブジェクトの許可ビットは \fImode\fP の下位 9 ビットに基づいて設定される。ただし、 ファイルモード作成マスク (\fBumask\fP(2)
+参照) に設定されている値は、新規オブジェクトに関してはクリアされる。 \fImode\fP を定義するために使用できるマクロ定数(群)は
+\fBopen\fP(2)  に記載されている (これらの定数のシンボル定義は \fI<sys/stat.h>\fP
+のインクルードにより得られる)。
+.IP
+新規に作成された共有メモリーオブジェクトは長さ 0 で初期化される。 オブジェクトの大きさは \fBftruncate\fP(2)  を使って設定できる。
+共有メモリーオブジェクトとして新規に確保されたバイトは自動的に 0 に初期化される。
+.TP 
+\fBO_EXCL\fP
+\fBO_CREAT\fP が一緒に指定されており、 \fIname\fP で指定された共有メモリーオブジェクトが既に存在した場合、 エラーを返す。
+オブジェクトの存在確認と、存在しなかった場合のオブジェクト作成は、 必ず一連の操作として実行される (performed atomically)。
+.TP 
+\fBO_TRUNC\fP
+共有メモリーオブジェクトがすでに存在した場合、 そのオブジェクトを 0 バイトに切り詰める。
+.PP
+これらのフラグ値の定義は \fI<fcntl.h>\fP のインクルードにより得られる。
+.PP
+成功して完了した場合、 \fBshm_open\fP()  は共有メモリーオブジェクトを参照する新しいファイルディスクリプターを返す。
+このファイルディスクリプターは、そのプロセス内で過去にオープンされていない ファイルディスクリプターの中で最も小さな数になることが保証される。
+\fBFD_CLOEXEC\fP フラグ (\fBfcntl\fP(2)  を参照) が、このファイルディスクリプターに設定される。
+.PP
+通常、これらのファイルディスクリプターは、この後続けて実行される \fBftruncate\fP(2)  (新規に作成されたオブジェクトの場合のみ) と
+\fBmmap\fP(2)  の呼び出しに使用される。 \fBmmap\fP(2)  を呼び出した後は、ファイルディスクリプターをクローズしてもよく、
+クローズしてもメモリーマッピングに影響を与えることはない。
+.PP
+\fBshm_unlink\fP()  の動作は \fBunlink\fP(2)  とよく似ている:
+共有メモリーオブジェクト名を削除し、すべてのプロセスが処理対象の オブジェクトをアンマップした時点でオブジェクトの割り当てを解除し、
+対応するメモリー領域の内容を破棄する。 \fBshm_unlink\fP()  が成功した後で、同じ \fIname\fP を持つオブジェクトに対して
+\fBshm_open\fP()  を行うと、 (\fBO_CREAT\fP が指定されていない場合) 失敗する。 (\fBO_CREAT\fP
+が指定されている場合、新しく別のオブジェクトが作成される)。
+.SH 返り値
+成功した場合、 \fBshm_open\fP()  はファイルディスクリプター (非負の整数) を返す。 失敗した場合、 \fBshm_open\fP()  は
+\-1 を返す。 \fBshm_unlink\fP()  は、成功した場合 0 を、エラーが起こった場合 \-1 を返す。
+.SH エラー
+失敗した場合、エラーの原因を示すため \fIerrno\fP が設定される。 \fIerrno\fP に設定される値は以下の通りである:
+.TP 
+\fBEACCES\fP
+共有メモリーオブジェクトを \fBshm_unlink\fP()  する権限がなかった。
+.TP 
+\fBEACCES\fP
+指定された \fImode\fP で \fIname\fP を \fBshm_open\fP()  する権限がなかった。もしくは、 \fBO_TRUNC\fP
+が指定されたが、呼び出し元にはそのオブジェクトに対する書き込み権限が なかった。
+.TP 
+\fBEEXIST\fP
+\fBO_CREAT\fP と \fBO_EXCL\fP の両方が \fBshm_open\fP()  に指定されたが、 \fIname\fP
+で指定された共有メモリーオブジェクトが既に存在した。
+.TP 
+\fBEINVAL\fP
+\fBshm_open\fP()  に与えられた \fIname\fP 引き数が不正であった。
+.TP 
+\fBEMFILE\fP
+オープンされているファイルディスクリプター数のプロセス単位の上限に達した。
+.TP 
+\fBENAMETOOLONG\fP
+\fIname\fP の長さが \fBPATH_MAX\fP を越えている。
+.TP 
+\fBENFILE\fP
+システム全体でオープンされているファイルの総数が上限に達した。
+.TP 
+\fBENOENT\fP
+存在していない \fIname\fP のオブジェクトを \fBshm_open\fP()  しようとしたが、 \fBO_CREAT\fP が指定されていなかった。
+.TP 
+\fBENOENT\fP
+存在しない \fIname\fP のオブジェクトを \fBshm_unlink\fP()  しようとした。
+.SH バージョン
+これらの関数は glibc 2.2 以降で提供されている。
+.SH 属性
+この節で使用されている用語の説明については、 \fBattributes\fP(7) を参照。
+.TS
+allbox;
+lbw24 lb lb
+l l l.
+インターフェース       属性  値
+T{
+\fBshm_open\fP(),
+\fBshm_unlink\fP()
+T}     Thread safety   MT\-Safe locale
+.TE
+.sp 1
+.SH 準拠
+POSIX.1\-2001, POSIX.1\-2008.
+.PP
+POSIX.1\-2001 says that the group ownership of a newly created shared memory
+object is set to either the calling process's effective group ID or "a
+system default group ID".  POSIX.1\-2008 says that the group ownership may be
+set to either the calling process's effective group ID or, if the object is
+visible in the filesystem, the group ID of the parent directory.
+.SH 注意
+POSIX は \fBO_RDONLY\fP と \fBO_TRUNC\fP が一緒に指定された場合の動作を未定義にしている。Linux では、
+既存の共有メモリーオブジェクトに対する切り詰め (truncate) は成功する。 しかし、他の UNIX システムでも同じであるとは限らない。
+.PP
+Linux における POSIX 共有メモリーオブジェクトの実装は専用の \fBtmpfs\fP(5) ファイルシステムを使用する。そのファイルシステムは通常
+\fI/dev/shm\fP にマウントされる。
+.SH 例
+The programs below employ POSIX shared memory and POSIX unnamed semaphores
+to exchange a piece of data.  The "bounce" program (which must be run first)
+raises the case of a string that is placed into the shared memory by the
+"send" program.  Once the data has been modified, the "send" program then
+prints the contents of the modified shared memory.  An example execution of
+the two programs is the following:
+.PP
+.in +4n
+.EX
+$ \fB./pshm_ucase_bounce /myshm &\fP
+[1] 270171
+$ \fB./pshm_ucase_send /myshm hello\fP
+HELLO
+.EE
+.in
+.PP
+.\"
+Further detail about these programs is provided below.
+.SS "プログラムのソース: pshm_ucase.h"
+The following header file is included by both programs below.  Its primary
+purpose is to define a structure that will be imposed on the memory object
+that is shared between the two programs.
+.PP
+.in +4n
+.EX
+#include <sys/mman.h>
+#include <fcntl.h>
+#include <semaphore.h>
+#include <sys/stat.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \e
+                        } while (0)
+
+#define BUF_SIZE 1024   /* Maximum size for exchanged string */
+
+/* Define a structure that will be imposed on the shared
+   memory object */
+
+struct shmbuf {
+    sem_t  sem1;            /* POSIX unnamed semaphore */
+    sem_t  sem2;            /* POSIX unnamed semaphore */
+    size_t cnt;             /* Number of bytes used in \(aqbuf\(aq */
+    char   buf[BUF_SIZE];   /* Data being transferred */
+};
+.EE
+.in
+.\"
+.SS "プログラムのソース: pshm_ucase_bounce.c"
+The "bounce" program creates a new shared memory object with the name given
+in its command\-line argument and sizes the object to match the size of the
+\fIshmbuf\fP structure defined in the header file.  It then maps the object
+into the process's address space, and initializes two POSIX semaphores
+inside the object to 0.
+.PP
+After the "send" program has posted the first of the semaphores, the
+"bounce" program upper cases the data that has been placed in the memory by
+the "send" program and then posts the second semaphore to tell the "send"
+program that it may now access the shared memory.
+.PP
+.in +4n
+.EX
+/* pshm_ucase_bounce.c
+
+   Licensed under GNU General Public License v2 or later.
+*/
+#include <ctype.h>
+#include "pshm_ucase.h"
+
+int
+main(int argc, char *argv[])
+{
+    if (argc != 2) {
+        fprintf(stderr, "Usage: %s /shm\-path\en", argv[0]);
+        exit(EXIT_FAILURE);
+    }
+
+    char *shmpath = argv[1];
+
+    /* Create shared memory object and set its size to the size
+       of our structure */
+
+    int fd = shm_open(shmpath, O_CREAT | O_EXCL | O_RDWR,
+                      S_IRUSR | S_IWUSR);
+    if (fd == \-1)
+        errExit("shm_open");
+
+    if (ftruncate(fd, sizeof(struct shmbuf)) == \-1)
+        errExit("ftruncate");
+
+    /* Map the object into the caller\(aqs address space */
+
+    struct shmbuf *shmp = mmap(NULL, sizeof(*shmp),
+                               PROT_READ | PROT_WRITE,
+                               MAP_SHARED, fd, 0);
+    if (shmp == MAP_FAILED)
+        errExit("mmap");
+
+    /* Initialize semaphores as process\-shared, with value 0 */
+
+    if (sem_init(&shmp\->sem1, 1, 0) == \-1)
+        errExit("sem_init\-sem1");
+    if (sem_init(&shmp\->sem2, 1, 0) == \-1)
+        errExit("sem_init\-sem2");
+
+    /* Wait for \(aqsem1\(aq to be posted by peer before touching
+       shared memory */
+
+    if (sem_wait(&shmp\->sem1) == \-1)
+        errExit("sem_wait");
+
+    /* Convert data in shared memory into upper case */
+
+    for (int j = 0; j < shmp\->cnt; j++)
+        shmp\->buf[j] = toupper((unsigned char) shmp\->buf[j]);
+
+    /* Post \(aqsem2\(aq to tell the to tell peer that it can now
+       access the modified data in shared memory */
+
+    if (sem_post(&shmp\->sem2) == \-1)
+        errExit("sem_post");
+
+    /* Unlink the shared memory object. Even if the peer process
+       is still using the object, this is okay. The object will
+       be removed only after all open references are closed. */
+
+    shm_unlink(shmpath);
+
+    exit(EXIT_SUCCESS);
+}
+.EE
+.in
+.\"
+.SS "プログラムのソース: pshm_ucase_send.c"
+The "send" program takes two command\-line arguments: the pathname of a
+shared memory object previously created by the "bounce" program and a string
+that is to be copied into that object.
+.PP
+The program opens the shared memory object and maps the object into its
+address space.  It then copies the data specified in its second argument
+into the shared memory, and posts the first semaphore, which tells the
+"bounce" program that it can now access that data.  After the "bounce"
+program posts the second semaphore, the "send" program prints the contents
+of the shared memory on standard output.
+.PP
+.in +4n
+.EX
+/* pshm_ucase_send.c
+
+   Licensed under GNU General Public License v2 or later.
+*/
+#include <string.h>
+#include "pshm_ucase.h"
+
+int
+main(int argc, char *argv[])
+{
+    if (argc != 3) {
+        fprintf(stderr, "Usage: %s /shm\-path string\en", argv[0]);
+        exit(EXIT_FAILURE);
+    }
+
+    char *shmpath = argv[1];
+    char *string = argv[2];
+    size_t len = strlen(string);
+
+    if (len > BUF_SIZE) {
+        fprintf(stderr, "String is too long\en");
+        exit(EXIT_FAILURE);
+    }
+
+    /* Open the existing shared memory object and map it
+       into the caller\(aqs address space */
+
+    int fd = shm_open(shmpath, O_RDWR, 0);
+    if (fd == \-1)
+        errExit("shm_open");
+
+    struct shmbuf *shmp = mmap(NULL, sizeof(*shmp),
+                               PROT_READ | PROT_WRITE,
+                               MAP_SHARED, fd, 0);
+    if (shmp == MAP_FAILED)
+        errExit("mmap");
+
+    /* Copy data into the shared memory object */
+
+    shmp\->cnt = len;
+    memcpy(&shmp\->buf, string, len);
+
+    /* Tell peer that it can now access shared memory */
+
+    if (sem_post(&shmp\->sem1) == \-1)
+        errExit("sem_post");
+
+    /* Wait until peer says that it has finished accessing
+       the shared memory */
+
+    if (sem_wait(&shmp\->sem2) == \-1)
+        errExit("sem_wait");
+
+    /* Write modified data in shared memory to standard output */
+
+    write(STDOUT_FILENO, &shmp\->buf, len);
+    write(STDOUT_FILENO, "\en", 1);
+
+    exit(EXIT_SUCCESS);
+}
+.EE
+.in
+.SH 関連項目
+\fBclose\fP(2), \fBfchmod\fP(2), \fBfchown\fP(2), \fBfcntl\fP(2), \fBfstat\fP(2),
+\fBftruncate\fP(2), \fBmemfd_create\fP(2), \fBmmap\fP(2), \fBopen\fP(2), \fBumask\fP(2),
+\fBshm_overview\fP(7)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は
+\%https://www.kernel.org/doc/man\-pages/ に書かれている。
index 1967b62..9a53b22 100644 (file)
@@ -78,10 +78,9 @@ POSIX 共有メモリーオブジェクトはカーネル内で保持される
 POSIX 共有メモリー API を使用したプログラムは \fIcc \-lrt\fP でコンパイルし、リアルタイムライブラリ \fIlibrt\fP
 とリンクしなければならない。
 .SS ファイルシステム経由での共有メモリーオブジェクトへのアクセス
-On Linux, shared memory objects are created in a (\fItmpfs\fP(5))  virtual
-filesystem, normally mounted under \fI/dev/shm\fP.  Since kernel 2.6.19, Linux
-supports the use of access control lists (ACLs)  to control the permissions
-of objects in the virtual filesystem.
+Linux では、共有メモリーオブジェクトは通常 \fI/dev/shm\fP 以下にマウントされる仮想ファイルシステム (\fBtmpfs\fP(5))
+内に作成される。 カーネル 2.6.19 以降の Linux では、 仮想ファイルシステム内のオブジェクトの許可属性の制御に、 アクセス制御リスト
+(ACL; access control lists) を使うことができる。
 .SH 注意
 通常は、共有メモリーオブジェクトにアクセスするプロセスは、 POSIX セマフォなどを使ってプロセス間で同期をとらなければならない。
 .PP
index 876069d..74b1415 100644 (file)
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "POT-Creation-Date: 2021-03-12 14:01+0900\n"
-"PO-Revision-Date: 2021-03-26 13:34+0900\n"
+"PO-Revision-Date: 2021-04-07 20:19+0900\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
 "Language: \n"
@@ -180,25 +180,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/alloc_hugepages.2:57
-#, fuzzy
-#| msgid ""
-#| "On i386 the memory management hardware knows about ordinary pages (4 "
-#| "KiB)  and huge pages (2 or 4 MiB).  Similarly ia64 knows about huge pages "
-#| "of several sizes.  These system calls serve to map huge pages into the "
-#| "process's memory or to free them again.  Huge pages are locked into "
-#| "memory, and are not swapped."
 msgid ""
 "On i386 the memory management hardware knows about ordinary pages (4\\ KiB)  "
 "and huge pages (2 or 4\\ MiB).  Similarly ia64 knows about huge pages of "
 "several sizes.  These system calls serve to map huge pages into the "
 "process's memory or to free them again.  Huge pages are locked into memory, "
 "and are not swapped."
-msgstr ""
-"i386 では、メモリー管理ハードウェアは通常のページ (4 KiB) と 大きなサイズの"
-"ページ (以下、ヒュージページ; 2MiB または 4 MiB) を 扱うことができる。 同様"
-"に、ia64 もいくつかのサイズのヒュージページを扱うことができる。 これらのシス"
-"テムコールは、ヒュージページをプロセスのメモリーにマップしたり、 再び解放した"
-"りする。 ヒュージページはメモリー内にロックされ、スワップされない。"
+msgstr "i386 では、メモリー管理ハードウェアは通常のページ (4\\ KiB) と 大きなサイズのページ (以下、ヒュージページ; 2MiB または 4\\ MiB) を 扱うことができる。 同様に、ia64 もいくつかのサイズのヒュージページを扱うことができる。 これらのシステムコールは、ヒュージページをプロセスのメモリーにマップしたり、 再び解放したりする。 ヒュージページはメモリー内にロックされ、スワップされない。"
 
 #. type: Plain text
 #: build/C/man2/alloc_hugepages.2:66
@@ -332,39 +320,25 @@ msgstr "ファイル"
 #: build/C/man2/alloc_hugepages.2:123
 #, no-wrap
 msgid "I</proc/sys/vm/nr_hugepages>"
-msgstr ""
+msgstr "I</proc/sys/vm/nr_hugepages>"
 
 #. type: Plain text
 #: build/C/man2/alloc_hugepages.2:127
-#, fuzzy
-#| msgid ""
-#| "I</proc/sys/vm/nr_hugepages> Number of configured hugetlb pages.  This "
-#| "can be read and written."
 msgid "Number of configured hugetlb pages.  This can be read and written."
-msgstr ""
-"I</proc/sys/vm/nr_hugepages> 設定された hugetlb ページの数。 このファイルは読"
-"み書きできる。"
+msgstr "設定された hugetlb ページの数。 このファイルは読み書きできる。"
 
 #. type: TP
 #: build/C/man2/alloc_hugepages.2:127
 #, no-wrap
 msgid "I</proc/meminfo>"
-msgstr ""
+msgstr "I</proc/meminfo>"
 
 #. type: Plain text
 #: build/C/man2/alloc_hugepages.2:131
-#, fuzzy
-#| msgid ""
-#| "I</proc/meminfo> Gives info on the number of configured hugetlb pages and "
-#| "on their size in the three variables HugePages_Total, HugePages_Free, "
-#| "Hugepagesize."
 msgid ""
 "Gives info on the number of configured hugetlb pages and on their size in "
 "the three variables HugePages_Total, HugePages_Free, Hugepagesize."
-msgstr ""
-"I</proc/meminfo> 設定された hugetlb ページの数と、 3 つの変数 "
-"HugePages_Total, HugePages_Free, Hugepagesize の サイズについての情報を提供す"
-"る。"
+msgstr "設定された hugetlb ページの数と、 3 つの変数 HugePages_Total, HugePages_Free, Hugepagesize の サイズについての情報を提供する。"
 
 #. type: SH
 #: build/C/man2/alloc_hugepages.2:131 build/C/man3/alloca.3:77
@@ -505,10 +479,9 @@ msgstr "ALLOCA"
 #. type: TH
 #: build/C/man3/alloca.3:43 build/C/man2/posix_fadvise.2:29
 #: build/C/man2/readahead.2:28
-#, fuzzy, no-wrap
-#| msgid "2014-03-15"
+#, no-wrap
 msgid "2019-03-06"
-msgstr "2014-03-15"
+msgstr "2019-03-06"
 
 #. type: TH
 #: build/C/man3/alloca.3:43 build/C/man3/malloc_get_state.3:25
@@ -646,10 +619,8 @@ msgstr "MT-Safe"
 
 #. type: Plain text
 #: build/C/man3/alloca.3:79
-#, fuzzy
-#| msgid "This function is not in POSIX.1-2001."
 msgid "This function is not in POSIX.1."
-msgstr "この関数は POSIX.1-2001 にはない。"
+msgstr "この関数は POSIX.1 にはない。"
 
 #. type: Plain text
 #: build/C/man3/alloca.3:85
@@ -727,19 +698,15 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/alloca.3:149
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    #ifdef  __GNUC__\n"
-#| "    #define alloca(size)   __builtin_alloca (size)\n"
-#| "    #endif\n"
+#, no-wrap
 msgid ""
 "#ifdef  __GNUC__\n"
 "#define alloca(size)   __builtin_alloca (size)\n"
 "#endif\n"
 msgstr ""
-"    #ifdef  __GNUC__\n"
-"    #define alloca(size)   __builtin_alloca (size)\n"
-"    #endif\n"
+"#ifdef  __GNUC__\n"
+"#define alloca(size)   __builtin_alloca (size)\n"
+"#endif\n"
 
 #. type: Plain text
 #: build/C/man3/alloca.3:153
@@ -836,10 +803,9 @@ msgstr "CACHEFLUSH"
 #: build/C/man2/cacheflush.2:25 build/C/man2/mmap.2:40
 #: build/C/man3/posix_memalign.3:29 build/C/man2/shmctl.2:46
 #: build/C/man2/subpage_prot.2:30
-#, fuzzy, no-wrap
-#| msgid "2014-12-31"
+#, no-wrap
 msgid "2020-12-21"
-msgstr "2014-12-31"
+msgstr "2020-12-21"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:28
@@ -860,14 +826,10 @@ msgstr "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:38
-#, fuzzy
-#| msgid "I<Note>: There is no glibc wrapper for this system call; see NOTES."
 msgid ""
 "I<Note>: On some architectures, there is no glibc wrapper for this system "
 "call; see NOTES."
-msgstr ""
-"I<注>: このシステムコールには glibc のラッパー関数は存在しない。「注意」の節"
-"を参照。"
+msgstr "I<注>: いくつかのアーキテクチャーでは、このシステムコールには glibc のラッパー関数は存在しない。「注意」の節を参照。"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:47
@@ -971,12 +933,9 @@ msgstr "B<EINVAL>"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:80
-#, fuzzy
-#| msgid "I<cache> is not one of B<ICACHE>, B<DCACHE>, or B<BCACHE>."
 msgid ""
 "I<cache> is not one of B<ICACHE>, B<DCACHE>, or B<BCACHE> (but see BUGS)."
-msgstr ""
-"I<cache> パラメーターが B<ICACHE>, B<DCACHE>, B<BCACHE> のどれでもない。"
+msgstr "I<cache> パラメーターが B<ICACHE>, B<DCACHE>, B<BCACHE> のどれでもない (ただし「バグ」を参照)。"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:86
@@ -1026,63 +985,48 @@ msgstr ""
 #: build/C/man2/cacheflush.2:102
 #, no-wrap
 msgid "M68K:"
-msgstr ""
+msgstr "M68K:"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:107
-#, fuzzy, no-wrap
-#| msgid ""
-#| "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
-#| "B<                    unsigned int >I<flags>B<);>\n"
+#, no-wrap
 msgid ""
 "B<int cacheflush(unsigned long >I<addr>B<, int >I<scope>B<, int >I<cache>B<,>\n"
 "B<               unsigned long >I<len>B<);>\n"
 msgstr ""
-"B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
-"B<                    unsigned int >I<flags>B<);>\n"
+"B<int cacheflush(unsigned long >I<addr>B<, int >I<scope>B<, int >I<cache>B<,>\n"
+"B<               unsigned long >I<len>B<);>\n"
 
 #. type: TP
 #: build/C/man2/cacheflush.2:108
 #, no-wrap
 msgid "SH:"
-msgstr ""
+msgstr "SH:"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:112
-#, fuzzy, no-wrap
-#| msgid ""
-#| "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
-#| "B<                  uint32_t *>I<map>B<);>\n"
+#, no-wrap
 msgid "B<int cacheflush(unsigned long >I<addr>B<, unsigned long >I<len>B<, int >I<op>B<);>\n"
-msgstr ""
-"B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
-"B<                  uint32_t *>I<map>B<);>\n"
+msgstr "B<int cacheflush(unsigned long >I<addr>B<, unsigned long >I<len>B<, int >I<op>B<);>\n"
 
 #. type: TP
 #: build/C/man2/cacheflush.2:113
 #, no-wrap
 msgid "NDS32:"
-msgstr ""
+msgstr "NDS32:"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:117
-#, fuzzy, no-wrap
-#| msgid "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
+#, no-wrap
 msgid "B<int cacheflush(unsigned int >I<start>B<, unsigned int >I<end>B<, int >I<cache>B<);>\n"
-msgstr "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
+msgstr "B<int cacheflush(unsigned int >I<start>B<, unsigned int >I<end>B<, int >I<cache>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:122
-#, fuzzy
-#| msgid ""
-#| "On some 32-bit architectures, the calling signature for this system call "
-#| "differs, for the reasons described in B<syscall>(2)."
 msgid ""
 "On the above architectures, glibc does not provide a wrapper for this system "
 "call; call it using B<syscall>(2)."
 msgstr ""
-"いくつかの 32 ビットアーキテクチャーでは、このシステムコールの呼び出しシグネ"
-"チャーが違っている。 理由は B<syscall>(2) で説明されている。"
 
 #. type: SS
 #: build/C/man2/cacheflush.2:122
@@ -1101,10 +1045,9 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:132
-#, fuzzy, no-wrap
-#| msgid "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
+#, no-wrap
 msgid "B<void __builtin___clear_cache(void *>I<begin>B<, void *>I<end>B<);>\n"
-msgstr "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
+msgstr "B<void __builtin___clear_cache(void *>I<begin>B<, void *>I<end>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:138
@@ -1122,17 +1065,11 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:153
-#, fuzzy
-#| msgid ""
-#| "The current implementation ignores the I<addr> and I<nbytes> arguments.  "
-#| "Therefore, the whole cache is always flushed."
 msgid ""
 "Linux kernels older than version 2.6.11 ignore the I<addr> and I<nbytes> "
 "arguments, making this function fairly expensive.  Therefore, the whole "
 "cache is always flushed."
 msgstr ""
-"現在の実装では、引き数 I<addr> と I<nbytes> は無視される。そのため、 常に全て"
-"のキャッシュがフラッシュされる。"
 
 #. type: Plain text
 #: build/C/man2/cacheflush.2:161
@@ -1152,7 +1089,7 @@ msgstr "FALLOCATE"
 #: build/C/man2/fallocate.2:11
 #, no-wrap
 msgid "2019-11-19"
-msgstr ""
+msgstr "2019-11-19"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:14
@@ -1288,14 +1225,6 @@ msgstr "ファイル空間の割り当て解除"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:111
-#, fuzzy
-#| msgid ""
-#| "Specifying the B<FALLOC_FL_PUNCH_HOLE> flag (available since Linux "
-#| "2.6.38) in I<mode> deallocates space (i.e., creates a hole)  in the byte "
-#| "range starting at I<offset> and continuing for I<len> bytes.  Within the "
-#| "specified range, partial filesystem blocks are zeroed, and whole "
-#| "filesystem blocks are removed from the file.  After a successful call, "
-#| "subsequent reads from this range will return zeroes."
 msgid ""
 "Specifying the B<FALLOC_FL_PUNCH_HOLE> flag (available since Linux 2.6.38) "
 "in I<mode> deallocates space (i.e., creates a hole)  in the byte range "
@@ -1373,18 +1302,14 @@ msgstr "Btrfs (Linux 3.7 以降)"
 #.  commit 83e4fa9c16e4af7122e31be3eca5d57881d236fe
 #. type: Plain text
 #: build/C/man2/fallocate.2:138
-#, fuzzy
-#| msgid "tmpfs (since Linux 3.5)"
 msgid "B<tmpfs>(5)  (since Linux 3.5)"
-msgstr "tmpfs (Linux 3.5 以降)"
+msgstr "B<tmpfs>(5)  (Linux 3.5 以降)"
 
 #.  commit 4e56a6411fbce6f859566e17298114c2434391a4
 #. type: Plain text
 #: build/C/man2/fallocate.2:142
-#, fuzzy
-#| msgid "Btrfs (since Linux 3.7)"
 msgid "B<gfs2>(5)  (since Linux 4.16)"
-msgstr "Btrfs (Linux 3.7 以降)"
+msgstr "B<gfs2>(5)  (Linux 4.16 以降)"
 
 #. type: SS
 #: build/C/man2/fallocate.2:142
@@ -1412,14 +1337,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:176
-#, fuzzy
-#| msgid ""
-#| "A filesystem may place limitations on the granularity of the operation, "
-#| "in order to ensure efficient implementation.  Typically, I<offset> and "
-#| "I<len> must be a multiple of the filesystem logical block size, which "
-#| "varies according to the filesystem type and configuration.  If a "
-#| "filesystem has such a requirement, B<fallocate>()  will fail with the "
-#| "error B<EINVAL> if this requirement is violated."
 msgid ""
 "A filesystem may place limitations on the granularity of the operation, in "
 "order to ensure efficient implementation.  Typically, I<offset> and I<len> "
@@ -1474,25 +1391,13 @@ msgstr "ファイル空間のゼロ埋め"
 #.  commit 409332b65d3ed8cfa7a8030f1e9d52f372219642
 #. type: Plain text
 #: build/C/man2/fallocate.2:214
-#, fuzzy
-#| msgid ""
-#| "Specifying the B<FALLOC_FL_ZERO_RANGE> flag (available since Linux 3.14)  "
-#| "in I<mode> zeroes space in the byte range starting at I<offset> and "
-#| "continuing for I<len> bytes.  Within the specified range, blocks are "
-#| "preallocated for the regions that span the holes in the file.  After a "
-#| "successful call, subsequent reads from this range will return zeroes."
 msgid ""
 "Specifying the B<FALLOC_FL_ZERO_RANGE> flag (available since Linux 3.15)  in "
 "I<mode> zeros space in the byte range starting at I<offset> and continuing "
 "for I<len> bytes.  Within the specified range, blocks are preallocated for "
 "the regions that span the holes in the file.  After a successful call, "
 "subsequent reads from this range will return zeros."
-msgstr ""
-"B<FALLOC_FL_ZERO_RANGE> フラグ (Linux 3.14 以降で利用可能) を I<mode> に指定"
-"すると、 I<offset> で始まる I<len> バイト範囲の空間をゼロ埋めする。 指定され"
-"た範囲の中では、ブロックは、そのファイル内のホールが広がる領域にあらかじめ割"
-"り当てられたものである。 呼び出しが成功すると、 これ以降のこの範囲からの読み"
-"出しでは 0 を返す。"
+msgstr "B<FALLOC_FL_ZERO_RANGE> フラグ (Linux 3.15 以降で利用可能) を I<mode> に指定すると、 I<offset> で始まる I<len> バイト範囲の空間をゼロ埋めする。 指定された範囲の中では、ブロックは、そのファイル内のホールが広がる領域にあらかじめ割り当てられたものである。 呼び出しが成功すると、 これ以降のこの範囲からの読み出しでは 0 を返す。"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:220
@@ -1537,34 +1442,26 @@ msgstr ""
 #.  commit 376ba313147b4172f3e8cf620b9fb591f3e8cdfa
 #. type: Plain text
 #: build/C/man2/fallocate.2:240
-#, fuzzy
-#| msgid "XFS (since Linux 3.14)"
 msgid "XFS (since Linux 3.15)"
-msgstr "XFS (Linux 3.14 以降)"
+msgstr "XFS (Linux 3.15 以降)"
 
 #.  commit b8a8684502a0fc852afa0056c6bb2a9273f6fcc0
 #. type: Plain text
 #: build/C/man2/fallocate.2:243
-#, fuzzy
-#| msgid "ext4, for extent-based files (since Linux 3.14)"
 msgid "ext4, for extent-based files (since Linux 3.15)"
-msgstr "ext4 のエクステントベースのファイル (Linux 3.14 以降)"
+msgstr "ext4 のエクステントベースのファイル (Linux 3.15 以降)"
 
 #.  commit 30175628bf7f521e9ee31ac98fa6d6fe7441a556
 #. type: Plain text
 #: build/C/man2/fallocate.2:246
-#, fuzzy
-#| msgid "XFS (since Linux 3.14)"
 msgid "SMB3 (since Linux 3.17)"
-msgstr "XFS (Linux 3.14 以降)"
+msgstr "SMB3 (Linux 3.17 以降)"
 
 #.  commit f27451f229966874a8793995b8e6b74326d125df
 #. type: Plain text
 #: build/C/man2/fallocate.2:249
-#, fuzzy
-#| msgid "Btrfs (since Linux 3.7)"
 msgid "Btrfs (since Linux 4.16)"
-msgstr "Btrfs (Linux 3.7 以降)"
+msgstr "Btrfs (Linux 4.16 以降)"
 
 #. type: SS
 #: build/C/man2/fallocate.2:249
@@ -1613,16 +1510,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:291
-#, fuzzy
-#| msgid ""
-#| "No other flags may be specified in I<mode> in conjunction with "
-#| "B<FALLOC_FL_COLLAPSE_RANGE>."
 msgid ""
 "No other flags may be specified in I<mode> in conjunction with "
 "B<FALLOC_FL_INSERT_RANGE>."
-msgstr ""
-"B<FALLOC_FL_COLLAPSE_RANGE> と他のフラグを同時に I<mode> に指定することはでき"
-"ない。"
+msgstr "B<FALLOC_FL_INSERT_RANGE> と他のフラグを同時に I<mode> に指定することはできない。"
 
 #.  commit a904b1ca5751faf5ece8600e18cd3b674afcca1b
 #.  commit 331573febb6a224bc50322e3670da326cb7f4cfc
@@ -1694,10 +1585,8 @@ msgstr "B<EINTR>"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:327
-#, fuzzy
-#| msgid "A signal was caught during execution."
 msgid "A signal was caught during execution; see B<signal>(7)."
-msgstr "実行中にシグナルが捕捉された。"
+msgstr "実行中にシグナルが捕捉された。 B<signal>(7) 参照。"
 
 #.  FIXME . (raise a kernel bug) Probably the len==0 case should be
 #.  a no-op, rather than an error. That would be consistent with
@@ -1721,29 +1610,17 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:357
-#, fuzzy
-#| msgid ""
-#| "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE> and the range specified by "
-#| "I<offset> plus I<len> reaches or passes the end of the file."
 msgid ""
 "I<mode> is B<FALLOC_FL_INSERT_RANGE> and the range specified by I<offset> "
 "reaches or passes the end of the file."
-msgstr ""
-"I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> で、 I<offset> と I<len> で指定された"
-"範囲がファイルの末尾かそれより先まで達している。"
+msgstr "I<mode> が B<FALLOC_FL_INSERT_RANGE> で、 I<offset> と I<len> で指定された範囲がファイルの末尾かそれより先まで達している。"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:369
-#, fuzzy
-#| msgid ""
-#| "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE>, but either I<offset> or I<len> is "
-#| "not a multiple of the filesystem block size."
 msgid ""
 "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE> or B<FALLOC_FL_INSERT_RANGE>, but "
 "either I<offset> or I<len> is not a multiple of the filesystem block size."
-msgstr ""
-"I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> だが、 I<offset> か I<len> のいずれか"
-"がファイルシステムのブロックサイズの倍数ではない。"
+msgstr "I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> か B<FALLOC_FL_INSERT_RANGE> だが、 I<offset> か I<len> のいずれかがファイルシステムのブロックサイズの倍数ではない。"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:381
@@ -1768,17 +1645,11 @@ msgstr ""
 #.  Date: 2014-04-17 13:40:05 GMT
 #. type: Plain text
 #: build/C/man2/fallocate.2:400
-#, fuzzy
-#| msgid ""
-#| "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE> or B<FALLOC_FL_ZERO_RANGE>, but "
-#| "the file referred to by I<fd> is not a regular file."
 msgid ""
 "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE> or B<FALLOC_FL_ZERO_RANGE> or "
 "B<FALLOC_FL_INSERT_RANGE>, but the file referred to by I<fd> is not a "
 "regular file."
-msgstr ""
-"I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> か B<FALLOC_FL_ZERO_RANGE> だが、 "
-"I<fd> が参照しているファイルが通常のファイルではない。"
+msgstr "I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> か B<FALLOC_FL_ZERO_RANGE> か B<FALLOC_FL_INSERT_RANGE> だが、 I<fd> が参照しているファイルが通常のファイルではない。"
 
 #. type: TP
 #: build/C/man2/fallocate.2:400 build/C/man2/madvise.2:518
@@ -1864,19 +1735,11 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:449
-#, fuzzy
-#| msgid ""
-#| "I<mode> specifies B<FALLOC_FL_PUNCH_HOLE> or B<FALLOC_FL_COLLAPSE_RANGE> "
-#| "and the file referred to by I<fd> is marked append-only (see "
-#| "B<chattr>(1))."
 msgid ""
 "I<mode> specifies B<FALLOC_FL_PUNCH_HOLE> or B<FALLOC_FL_COLLAPSE_RANGE> or "
 "B<FALLOC_FL_INSERT_RANGE> and the file referred to by I<fd> is marked append-"
 "only (see B<chattr>(1))."
-msgstr ""
-"I<mode> に B<FALLOC_FL_PUNCH_HOLE> か B<FALLOC_FL_COLLAPSE_RANGE> が指定され"
-"たが、 I<fd> が参照するファイルに追加のみ (append-only) の属性が付いている "
-"(B<chattr>(1) 参照)。"
+msgstr "I<mode> に B<FALLOC_FL_PUNCH_HOLE> か B<FALLOC_FL_COLLAPSE_RANGE> か B<FALLOC_FL_INSERT_RANGE> が指定されたが、 I<fd> が参照するファイルに追加のみ (append-only) の属性が付いている (B<chattr>(1) 参照)。"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:453 build/C/man2/mmap.2:625
@@ -1903,16 +1766,10 @@ msgstr "B<ETXTBSY>"
 
 #. type: Plain text
 #: build/C/man2/fallocate.2:467
-#, fuzzy
-#| msgid ""
-#| "I<mode> specifies B<FALLOC_FL_COLLAPSE_RANGE>, but the file referred to "
-#| "by I<fd> is currently being executed."
 msgid ""
 "I<mode> specifies B<FALLOC_FL_COLLAPSE_RANGE> or B<FALLOC_FL_INSERT_RANGE>, "
 "but the file referred to by I<fd> is currently being executed."
-msgstr ""
-"I<mode> に B<FALLOC_FL_COLLAPSE_RANGE> が指定されたが、 I<fd> が参照するファ"
-"イルは現在実行中である。"
+msgstr "I<mode> に B<FALLOC_FL_COLLAPSE_RANGE> か B<FALLOC_FL_INSERT_RANGE> が指定されたが、 I<fd> が参照するファイルは現在実行中である。"
 
 #. type: SH
 #: build/C/man2/fallocate.2:467 build/C/man2/madvise.2:541
@@ -1962,10 +1819,9 @@ msgstr "MADVISE"
 #. type: TH
 #: build/C/man2/madvise.2:35 build/C/man2/mlock.2:26 build/C/man2/shmget.2:38
 #: build/C/man2/shmop.2:40
-#, fuzzy, no-wrap
-#| msgid "2012-04-18"
+#, no-wrap
 msgid "2020-04-11"
-msgstr "2012-04-18"
+msgstr "2020-04-11"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:38
@@ -1994,35 +1850,30 @@ msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)
 
 #. type: Plain text
 #: build/C/man2/madvise.2:49
-#, fuzzy
-#| msgid "B<posix_fadvise>():"
 msgid "B<madvise>():"
-msgstr "B<posix_fadvise>():"
+msgstr "B<madvise>():"
 
 #. type: TP
 #: build/C/man2/madvise.2:51
-#, fuzzy, no-wrap
-#| msgid "Since glibc 2.12:"
+#, no-wrap
 msgid "Since glibc 2.19:"
-msgstr "glibc 2.12 以降:"
+msgstr "glibc 2.19 以降:"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:54
 msgid "_DEFAULT_SOURCE"
-msgstr ""
+msgstr "_DEFAULT_SOURCE"
 
 #. type: TP
 #: build/C/man2/madvise.2:54
 #, no-wrap
 msgid "Up to and including glibc 2.19:"
-msgstr ""
+msgstr "glibc 2.19 以前:"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:57
-#, fuzzy
-#| msgid "B<madvise>(): _BSD_SOURCE"
 msgid "_BSD_SOURCE"
-msgstr "B<madvise>(): _BSD_SOURCE"
+msgstr "_BSD_SOURCE"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:70
@@ -2083,13 +1934,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/madvise.2:106
-#, fuzzy
-#| msgid "The advice is indicated in the I<advice> argument which can be"
 msgid ""
 "The advice is indicated in the I<advice> argument, which is one of the "
 "following:"
-msgstr ""
-"アドバイスは引き数 I<advice> によって与える。以下のいずれかを指定できる。"
+msgstr "アドバイスは引き数 I<advice> により指定する。以下のいずれかを指定できる。"
 
 #. type: TP
 #: build/C/man2/madvise.2:106
@@ -2278,13 +2126,6 @@ msgstr "B<MADV_DONTFORK> (Linux 2.6.16 以降)"
 #.  "Tweaks to madvise() and posix_fadvise()", 14 Feb 2006
 #. type: Plain text
 #: build/C/man2/madvise.2:237
-#, fuzzy
-#| msgid ""
-#| "Do not make the pages in this range available to the child after a "
-#| "B<fork>(2).  This is useful to prevent copy-on-write semantics from "
-#| "changing the physical location of a page(s) if the parent writes to it "
-#| "after a B<fork>(2).  (Such page relocations cause problems for hardware "
-#| "that DMAs into the page(s).)"
 msgid ""
 "Do not make the pages in this range available to the child after a "
 "B<fork>(2).  This is useful to prevent copy-on-write semantics from changing "
@@ -2360,20 +2201,6 @@ msgstr "B<MADV_MERGEABLE> (Linux 2.6.32 以降)"
 #.  commit f8af4da3b4c14e7267c4ffb952079af3912c51c5
 #. type: Plain text
 #: build/C/man2/madvise.2:276
-#, fuzzy
-#| msgid ""
-#| "Enable Kernel Samepage Merging (KSM) for the pages in the range specified "
-#| "by I<addr> and I<length>.  The kernel regularly scans those areas of user "
-#| "memory that have been marked as mergeable, looking for pages with "
-#| "identical content.  These are replaced by a single write-protected page "
-#| "(which is automatically copied if a process later wants to update the "
-#| "content of the page).  KSM merges only private anonymous pages (see "
-#| "B<mmap>(2)).  The KSM feature is intended for applications that generate "
-#| "many instances of the same data (e.g., virtualization systems such as "
-#| "KVM).  It can consume a lot of processing power; use with care.  See the "
-#| "Linux kernel source file I<Documentation/vm/ksm.txt> for more details.  "
-#| "The B<MADV_MERGEABLE> and B<MADV_UNMERGEABLE> operations are available "
-#| "only if the kernel was configured with B<CONFIG_KSM>."
 msgid ""
 "Enable Kernel Samepage Merging (KSM) for the pages in the range specified by "
 "I<addr> and I<length>.  The kernel regularly scans those areas of user "
@@ -2381,20 +2208,7 @@ msgid ""
 "content.  These are replaced by a single write-protected page (which is "
 "automatically copied if a process later wants to update the content of the "
 "page).  KSM merges only private anonymous pages (see B<mmap>(2))."
-msgstr ""
-"Kernel Samepage Merging (KSM; カーネルによる同じページの統合) を I<addr> と "
-"I<length> で指定された領域に対して有効にする。 カーネルは、 統合可能の印がつ"
-"いたユーザーメモリーの領域を定期的にスキャンし、内容が全く同じページを探す。 "
-"内容が全く同じページがあれば、それらのページは書き込み保護 (write-protected) "
-"がかかった一つのページで置き換えられる (プロセスが後でページの内容を更新しよ"
-"うとした際には自動的にページのコピーが行われる)。 KSM はプライベートな無名"
-"ページ (anonymous pages) だけを統合する (B<mmap>(2) 参照)。 KSM 機能は、 同じ"
-"データのインスタンスを大量に生成するアプリケーション (KVM などの仮想化システ"
-"ム) での利用を想定している。 この機能はプロセッシング能力を大量に消費する場合"
-"があり、注意して使用すること。 詳細は Linux カーネルソースファイル "
-"I<Documentation/vm/ksm.txt> を参照。 B<MADV_MERGEABLE> と "
-"B<MADV_UNMERGEABLE> は、 カーネルで B<CONFIG_KSM> オプションを有効になってい"
-"る場合にのみ利用できる。"
+msgstr "Kernel Samepage Merging (KSM; カーネルによる同じページの統合) を I<addr> と I<length> で指定された領域に対して有効にする。 カーネルは、 統合可能の印がついたユーザーメモリーの領域を定期的にスキャンし、内容が全く同じページを探す。 内容が全く同じページがあれば、それらのページは書き込み保護 (write-protected) がかかった一つのページで置き換えられる (プロセスが後でページの内容を更新しようとした際には自動的にページのコピーが行われる)。 KSM はプライベートな無名ページ (anonymous pages) だけを統合する (B<mmap>(2) 参照)。"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:283
@@ -2403,7 +2217,7 @@ msgid ""
 "the same data (e.g., virtualization systems such as KVM).  It can consume a "
 "lot of processing power; use with care.  See the Linux kernel source file "
 "I<Documentation/admin-guide/mm/ksm.rst> for more details."
-msgstr ""
+msgstr "KSM 機能は、 同じデータのインスタンスを大量に生成するアプリケーション (KVM などの仮想化システム) での利用を想定している。 この機能はプロセッシング能力を大量に消費する場合があり、注意して使用すること。 詳細は Linux カーネルソースファイル I<Documentation/vm/ksm.txt> を参照。"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:290
@@ -2444,17 +2258,6 @@ msgstr "B<MADV_SOFT_OFFLINE> (Linux 2.6.33 以降)"
 #.  commit afcf938ee0aac4ef95b1a23bac704c6fbeb26de6
 #. type: Plain text
 #: build/C/man2/madvise.2:315
-#, fuzzy
-#| msgid ""
-#| "Soft offline the pages in the range specified by I<addr> and I<length>.  "
-#| "The memory of each page in the specified range is preserved (i.e., when "
-#| "next accessed, the same content will be visible, but in a new physical "
-#| "page frame), and the original page is offlined (i.e., no longer used, and "
-#| "taken out of normal memory management).  The effect of the "
-#| "B<MADV_SOFT_OFFLINE> operation is invisible to (i.e., does not change the "
-#| "semantics of)  the calling process.  This feature is intended for testing "
-#| "of memory error-handling code; it is available only if the kernel was "
-#| "configured with B<CONFIG_MEMORY_FAILURE>."
 msgid ""
 "Soft offline the pages in the range specified by I<addr> and I<length>.  The "
 "memory of each page in the specified range is preserved (i.e., when next "
@@ -2463,15 +2266,7 @@ msgid ""
 "out of normal memory management).  The effect of the B<MADV_SOFT_OFFLINE> "
 "operation is invisible to (i.e., does not change the semantics of)  the "
 "calling process."
-msgstr ""
-"I<addr> と I<length> で指定された範囲のページをソフトオフラインにする。 指定"
-"された範囲の各ページのメモリーの内容は保持され (すなわち、次にアクセスされた"
-"際に、同じ内容が見えるが、新しい物理ページフレームになる)、 元のフレームはオ"
-"フラインになる (すなわち、 そのフレームは使用される、通常のメモリー管理からは"
-"取り除かれる)。 B<MADV_SOFT_OFFLINE> 操作の影響は呼び出したプロセスには見えな"
-"い (つまり呼び出したプロセスの動作は変化しない)。 この機能はメモリーのエラー"
-"処理コードをテストすることを目的に作られた。 カーネルで "
-"B<CONFIG_MEMORY_FAILURE> が有効になっている場合にのみ利用可能である。"
+msgstr "I<addr> と I<length> で指定された範囲のページをソフトオフラインにする。 指定された範囲の各ページのメモリーの内容は保持され (すなわち、次にアクセスされた際に、同じ内容が見えるが、新しい物理ページフレームになる)、 元のフレームはオフラインになる (すなわち、 そのフレームは使用される、通常のメモリー管理からは取り除かれる)。 B<MADV_SOFT_OFFLINE> 操作の影響は呼び出したプロセスには見えない (つまり呼び出したプロセスの動作は変化しない)。"
 
 #. type: TP
 #: build/C/man2/madvise.2:319
@@ -2589,25 +2384,13 @@ msgstr "B<MADV_DONTDUMP> (Linux 3.4 以降)"
 #.  commit accb61fe7bb0f5c2a4102239e4981650f9048519
 #. type: Plain text
 #: build/C/man2/madvise.2:391
-#, fuzzy
-#| msgid ""
-#| "Exclude from a core dump those pages in the range specified by I<addr> "
-#| "and I<length>.  This is useful in applications that have large areas of "
-#| "memory that are known not to be useful in a core dump.  The effect of "
-#| "B<MADV_DONTDUMP> takes precedence over the bit mask that is set via the "
-#| "I</proc/PID/coredump_filter> file (see B<core>(5))."
 msgid ""
 "Exclude from a core dump those pages in the range specified by I<addr> and "
 "I<length>.  This is useful in applications that have large areas of memory "
 "that are known not to be useful in a core dump.  The effect of "
 "B<MADV_DONTDUMP> takes precedence over the bit mask that is set via the I</"
 "proc/[pid]/coredump_filter> file (see B<core>(5))."
-msgstr ""
-"コアダンプから I<addr> と I<length> で指定された範囲のページを除外する。 これ"
-"は、 コアダンプに含めても役に立たないことが分かっている大きなメモリー領域があ"
-"るアプリケーションで有用である。 B<MADV_DONTDUMP> の効果は I</proc/PID/"
-"coredump_filter> ファイル経由で設定されたビットマスクよりも優先される "
-"(B<core>(5) 参照)。"
+msgstr "コアダンプから I<addr> と I<length> で指定された範囲のページを除外する。 これは、 コアダンプに含めても役に立たないことが分かっている大きなメモリー領域があるアプリケーションで有用である。 B<MADV_DONTDUMP> の効果は I</proc/[pid]/coredump_filter> ファイル経由で設定されたビットマスクよりも優先される (B<core>(5) 参照)。"
 
 #. type: TP
 #: build/C/man2/madvise.2:391
@@ -2622,10 +2405,9 @@ msgstr "以前の B<MADV_DONTDUMP> の効果を取り消す。"
 
 #. type: TP
 #: build/C/man2/madvise.2:395
-#, fuzzy, no-wrap
-#| msgid "B<MADV_REMOVE> (since Linux 2.6.16)"
+#, no-wrap
 msgid "B<MADV_FREE> (since Linux 4.5)"
-msgstr "B<MADV_REMOVE> (Linux 2.6.16 以降)"
+msgstr "B<MADV_FREE> (Linux 4.5 以降)"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:417
@@ -2656,10 +2438,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/madvise.2:428
-#, fuzzy, no-wrap
-#| msgid "B<MADV_DONTFORK> (since Linux 2.6.16)"
+#, no-wrap
 msgid "B<MADV_WIPEONFORK> (since Linux 4.14)"
-msgstr "B<MADV_DONTFORK> (Linux 2.6.16 以降)"
+msgstr "B<MADV_WIPEONFORK> (Linux 4.14 以降)"
 
 #.  commit d2cd9ede6e193dd7d88b6d27399e96229a551b19
 #. type: Plain text
@@ -2688,25 +2469,18 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/madvise.2:450
-#, fuzzy, no-wrap
-#| msgid "B<MADV_DONTFORK> (since Linux 2.6.16)"
+#, no-wrap
 msgid "B<MADV_KEEPONFORK> (since Linux 4.14)"
-msgstr "B<MADV_DONTFORK> (Linux 2.6.16 以降)"
+msgstr "B<MADV_KEEPONFORK> (Linux 4.14 以降)"
 
 #.  commit d2cd9ede6e193dd7d88b6d27399e96229a551b19
 #. type: Plain text
 #: build/C/man2/madvise.2:455
-#, fuzzy
-#| msgid "Undo the effect of an earlier B<MADV_DONTDUMP>."
 msgid "Undo the effect of an earlier B<MADV_WIPEONFORK>."
-msgstr "以前の B<MADV_DONTDUMP> の効果を取り消す。"
+msgstr "以前の B<MADV_WIPEONFORK> の効果を取り消す。"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:462
-#, fuzzy
-#| msgid ""
-#| "On success B<madvise>()  returns zero.  On error, it returns -1 and "
-#| "I<errno> is set appropriately."
 msgid ""
 "On success, B<madvise>()  returns zero.  On error, it returns -1 and "
 "I<errno> is set appropriately."
@@ -2751,17 +2525,13 @@ msgstr "指定したマップは存在するが、ファイルではないとこ
 #.  is zero,
 #. type: Plain text
 #: build/C/man2/madvise.2:483
-#, fuzzy
-#| msgid "I<addr> is not page-aligned."
 msgid "I<addr> is not page-aligned or I<length> is negative."
-msgstr "I<addr> がページ境界ではない。"
+msgstr "I<addr> ã\81\8cã\83\9aã\83¼ã\82¸å¢\83ç\95\8cã\81§ã\81¯ã\81ªã\81\84ã\80\81ã\81¾ã\81\9fã\81¯ I<length> ã\81\8cè² ã\81§ã\81\82ã\82\8bã\80\82"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:487
-#, fuzzy
-#| msgid "I<advice> is not a valid value"
 msgid "I<advice> is not a valid."
-msgstr "I<advice> ã\81\8cæ\9c\89å\8a¹ã\81ªå\80¤ã\81§ã\81ªã\81\84ã\80\82"
+msgstr "I<advice> が有効でない。"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:497
@@ -2772,16 +2542,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/madvise.2:506
-#, fuzzy
-#| msgid ""
-#| "B<MADV_MERGEABLE> or B<MADV_UNMERGEABLE> was specified in I<advice>, but "
-#| "the kernel was not configured with B<CONFIG_KSM>."
 msgid ""
 "I<advice> is B<MADV_MERGEABLE> or B<MADV_UNMERGEABLE>, but the kernel was "
 "not configured with B<CONFIG_KSM>."
-msgstr ""
-"I<advice> に B<MADV_MERGEABLE> か B<MADV_UNMERGEABLE> が指定されたが、 カーネ"
-"ルの設定が B<CONFIG_KSM> が有効になっていなかった。"
+msgstr "I<advice> が B<MADV_MERGEABLE> か B<MADV_UNMERGEABLE> だが、 カーネルの設定が B<CONFIG_KSM> が有効になっていなかった。"
 
 #. type: Plain text
 #: build/C/man2/madvise.2:518
@@ -2903,16 +2667,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/madvise.2:596
-#, fuzzy
-#| msgid ""
-#| "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
-#| "B<munmap>(2), B<prctl>(2), B<core>(5)"
 msgid ""
 "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
 "B<munmap>(2), B<prctl>(2), B<posix_madvise>(3), B<core>(5)"
-msgstr ""
-"B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
-"B<munmap>(2), B<prctl>(2), B<core>(5)"
+msgstr "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), B<munmap>(2), B<prctl>(2), B<posix_madvise>(3), B<core>(5)"
 
 #. type: TH
 #: build/C/man3/mallinfo.3:25
@@ -2928,7 +2686,7 @@ msgstr "MALLINFO"
 #: build/C/man2/membarrier.2:25
 #, no-wrap
 msgid "2020-11-01"
-msgstr ""
+msgstr "2020-11-01"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:28
@@ -2949,19 +2707,11 @@ msgstr "B<struct mallinfo mallinfo(void);>"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:39
-#, fuzzy
-#| msgid ""
-#| "The B<mallinfo>()  function returns a copy of a structure containing "
-#| "information about memory allocations performed by B<malloc>(3)  and "
-#| "related functions.  This structure is defined as follows:"
 msgid ""
 "The B<mallinfo>()  function returns a copy of a structure containing "
 "information about memory allocations performed by B<malloc>(3)  and related "
 "functions."
-msgstr ""
-"B<mallinfo>() 関数は、 B<malloc>(3) や一連の関数により実行されたメモリー\n"
-"割り当てに関する情報を格納した構造体のコピーを返す。\n"
-"この構造体は以下のように定義されている。"
+msgstr "B<mallinfo>() 関数は、 B<malloc>(3) や一連の関数により実行されたメモリー割り当てに関する情報を格納した構造体のコピーを返す。"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:45
@@ -2977,20 +2727,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:62
-#, fuzzy, no-wrap
-#| msgid ""
-#| "struct mallinfo {\n"
-#| "    int arena;     /* Non-mmapped space allocated (bytes) */\n"
-#| "    int ordblks;   /* Number of free chunks */\n"
-#| "    int smblks;    /* Number of free fastbin blocks */\n"
-#| "    int hblks;     /* Number of mmapped regions */\n"
-#| "    int hblkhd;    /* Space allocated in mmapped regions (bytes) */\n"
-#| "    int usmblks;   /* Maximum total allocated space (bytes) */\n"
-#| "    int fsmblks;   /* Space in freed fastbin blocks (bytes) */\n"
-#| "    int uordblks;  /* Total allocated space (bytes) */\n"
-#| "    int fordblks;  /* Total free space (bytes) */\n"
-#| "    int keepcost;  /* Top-most, releasable space (bytes) */\n"
-#| "};\n"
+#, no-wrap
 msgid ""
 "struct mallinfo {\n"
 "    int arena;     /* Non-mmapped space allocated (bytes) */\n"
@@ -3011,7 +2748,7 @@ msgstr ""
 "    int smblks;    /* Number of free fastbin blocks */\n"
 "    int hblks;     /* Number of mmapped regions */\n"
 "    int hblkhd;    /* Space allocated in mmapped regions (bytes) */\n"
-"    int usmblks;   /* Maximum total allocated space (bytes) */\n"
+"    int usmblks;   /* See below */\n"
 "    int fsmblks;   /* Space in freed fastbin blocks (bytes) */\n"
 "    int uordblks;  /* Total allocated space (bytes) */\n"
 "    int fordblks;  /* Total free space (bytes) */\n"
@@ -3235,8 +2972,7 @@ msgstr ""
 #: build/C/man2/shmop.2:293 build/C/man2/memfd_create.2:344
 #: build/C/man2/membarrier.2:328 build/C/man2/pkey_alloc.2:134
 #: build/C/man7/pkeys.7:165
-#, fuzzy, no-wrap
-#| msgid "EXAMPLE"
+#, no-wrap
 msgid "EXAMPLES"
 msgstr "例"
 
@@ -3389,19 +3125,15 @@ msgstr "プログラムのソース"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:247
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>malloc.hE<gt>\n"
-#| "#include E<lt>stdio.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#include E<lt>malloc.hE<gt>\n"
 "#include E<lt>stdlib.hE<gt>\n"
 "#include E<lt>string.hE<gt>\n"
 msgstr ""
 "#include E<lt>malloc.hE<gt>\n"
-"#include E<lt>stdio.hE<gt>\n"
 "#include E<lt>stdlib.hE<gt>\n"
+"#include E<lt>string.hE<gt>\n"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:252
@@ -3453,15 +3185,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:274
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "#define MAX_ALLOCS 2000000\n"
-#| "    char *alloc[MAX_ALLOCS];\n"
-#| "    int numBlocks, j, freeBegin, freeEnd, freeStep;\n"
-#| "    size_t blockSize;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -3476,16 +3200,12 @@ msgstr ""
 "{\n"
 "#define MAX_ALLOCS 2000000\n"
 "    char *alloc[MAX_ALLOCS];\n"
-"    int numBlocks, j, freeBegin, freeEnd, freeStep;\n"
+"    int numBlocks, freeBegin, freeEnd, freeStep;\n"
 "    size_t blockSize;\n"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:280
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (argc E<lt> 3 || strcmp(argv[1], \"--help\") == 0)\n"
-#| "        usageErr(\"%s num-blocks block-size [free-step [start-free \"\n"
-#| "                \"[end-free]]]\\en\", argv[0]);\n"
+#, no-wrap
 msgid ""
 "    if (argc E<lt> 3 || strcmp(argv[1], \"--help\") == 0) {\n"
 "        fprintf(stderr, \"%s num-blocks block-size [free-step \"\n"
@@ -3493,9 +3213,11 @@ msgid ""
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 msgstr ""
-"    if (argc E<lt> 3 || strcmp(argv[1], \"--help\") == 0)\n"
-"        usageErr(\"%s num-blocks block-size [free-step [start-free \"\n"
-"                \"[end-free]]]\\en\", argv[0]);\n"
+"    if (argc E<lt> 3 || strcmp(argv[1], \"--help\") == 0) {\n"
+"        fprintf(stderr, \"%s num-blocks block-size [free-step \"\n"
+"                \"[start-free [end-free]]]\\en\", argv[0]);\n"
+"        exit(EXIT_FAILURE);\n"
+"    }\n"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:286
@@ -3525,11 +3247,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:295
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (j = 0; j E<lt> numBlocks; j++) {\n"
-#| "        if (numBlocks E<gt>= MAX_ALLOCS)\n"
-#| "            fatal(\"Too many allocations\");\n"
+#, no-wrap
 msgid ""
 "    for (int j = 0; j E<lt> numBlocks; j++) {\n"
 "        if (numBlocks E<gt>= MAX_ALLOCS) {\n"
@@ -3537,18 +3255,15 @@ msgid ""
 "            exit(EXIT_FAILURE);\n"
 "        }\n"
 msgstr ""
-"    for (j = 0; j E<lt> numBlocks; j++) {\n"
-"        if (numBlocks E<gt>= MAX_ALLOCS)\n"
-"            fatal(\"Too many allocations\");\n"
+"    for (int j = 0; j E<lt> numBlocks; j++) {\n"
+"        if (numBlocks E<gt>= MAX_ALLOCS) {\n"
+"            fprintf(stderr, \"Too many allocations\\en\");\n"
+"            exit(EXIT_FAILURE);\n"
+"        }\n"
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:302
-#, fuzzy, no-wrap
-#| msgid ""
-#| "        alloc[j] = malloc(blockSize);\n"
-#| "        if (alloc[j] == NULL)\n"
-#| "            errExit(\"malloc\");\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "        alloc[j] = malloc(blockSize);\n"
 "        if (alloc[j] == NULL) {\n"
@@ -3558,8 +3273,10 @@ msgid ""
 "    }\n"
 msgstr ""
 "        alloc[j] = malloc(blockSize);\n"
-"        if (alloc[j] == NULL)\n"
-"            errExit(\"malloc\");\n"
+"        if (alloc[j] == NULL) {\n"
+"            perror(\"malloc\");\n"
+"            exit(EXIT_FAILURE);\n"
+"        }\n"
 "    }\n"
 
 #. type: Plain text
@@ -3574,15 +3291,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/mallinfo.3:308
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (j = freeBegin; j E<lt> freeEnd; j += freeStep)\n"
-#| "        free(alloc[j]);\n"
+#, no-wrap
 msgid ""
 "    for (int j = freeBegin; j E<lt> freeEnd; j += freeStep)\n"
 "        free(alloc[j]);\n"
 msgstr ""
-"    for (j = freeBegin; j E<lt> freeEnd; j += freeStep)\n"
+"    for (int j = freeBegin; j E<lt> freeEnd; j += freeStep)\n"
 "        free(alloc[j]);\n"
 
 #. type: Plain text
@@ -3642,10 +3356,9 @@ msgstr "B<#include E<lt>malloc.hE<gt>>\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_get_state.3:33
-#, fuzzy, no-wrap
-#| msgid "B<void* malloc_get_state(void);>\n"
+#, no-wrap
 msgid "B<void *malloc_get_state(void);>\n"
-msgstr "B<voidmalloc_get_state(void);>\n"
+msgstr "B<void *malloc_get_state(void);>\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_get_state.3:35
@@ -3655,10 +3368,8 @@ msgstr "B<int malloc_set_state(void *>I<state>B<);>\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_get_state.3:39
-#, fuzzy
-#| msgid "These functions are provided in glibc 2.2 and later."
 msgid "I<Note>: these function are removed in glibc version 2.25."
-msgstr "これらの関数は glibc 2.2 以降で提供されている。"
+msgstr "I<注意>: これらの関数は glibc バージョン 2.25 で削除された。"
 
 #. type: Plain text
 #: build/C/man3/malloc_get_state.3:56
@@ -3719,12 +3430,13 @@ msgstr ""
 
 #. type: tbl table
 #: build/C/man3/malloc_get_state.3:100
-#, fuzzy, no-wrap
-#| msgid "B<malloc>(3), B<mallopt>(3)"
+#, no-wrap
 msgid ""
 "B<malloc_get_state>(),\n"
 "B<malloc_set_state>()"
-msgstr "B<malloc>(3), B<mallopt>(3)"
+msgstr ""
+"B<malloc_get_state>(),\n"
+"B<malloc_set_state>()"
 
 #. type: Plain text
 #: build/C/man3/malloc_get_state.3:105 build/C/man3/malloc_hook.3:84
@@ -3852,10 +3564,9 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/malloc_hook.3:54
-#, fuzzy, no-wrap
-#| msgid "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
+#, no-wrap
 msgid "void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
-msgstr "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
+msgstr "void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_hook.3:60
@@ -4020,11 +3731,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/malloc_hook.3:135
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    /* printf() might call malloc(), so protect it too. */\n"
-#| "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
-#| "            (unsigned int) size, caller, result);\n"
+#, no-wrap
 msgid ""
 "    /* printf() might call malloc(), so protect it too. */\n"
 "    printf(\"malloc(%zu) called from %p returns %p\\en\",\n"
@@ -4032,8 +3739,8 @@ msgid ""
 msgstr ""
 "    /* printf() は malloc() を呼び出す可能性があるので\n"
 "        ここでもガードを行う (元々のフックのままにしておく) */\n"
-"    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
-"            (unsigned int) size, caller, result);\n"
+"    printf(\"malloc(%zu) called from %p returns %p\\en\",\n"
+"            size, caller, result);\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_hook.3:138
@@ -4116,10 +3823,9 @@ msgstr "B<malloc_info>() は glibc バージョン 2.10 で追加された。"
 
 #. type: tbl table
 #: build/C/man3/malloc_info.3:73
-#, fuzzy, no-wrap
-#| msgid "B<malloc>(3)"
+#, no-wrap
 msgid "B<malloc_info>()"
-msgstr "B<malloc>(3)"
+msgstr "B<malloc_info>()"
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:78 build/C/man3/malloc_stats.3:69
@@ -4357,13 +4063,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:198
-#, fuzzy, no-wrap
-#| msgid ""
-#| "static void *\n"
-#| "thread_func(void *arg)\n"
-#| "{\n"
-#| "    int j;\n"
-#| "    int tn = (int) arg;\n"
+#, no-wrap
 msgid ""
 "static void *\n"
 "thread_func(void *arg)\n"
@@ -4373,7 +4073,6 @@ msgstr ""
 "static void *\n"
 "thread_func(void *arg)\n"
 "{\n"
-"    int j;\n"
 "    int tn = (int) arg;\n"
 
 #. type: Plain text
@@ -4388,17 +4087,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:205
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (j = 0; j E<lt> numBlocks; j++)\n"
-#| "        if (malloc(blockSize * (2 + tn)) == NULL)\n"
-#| "            errExit(\"malloc-thread\");\n"
+#, no-wrap
 msgid ""
 "    for (int j = 0; j E<lt> numBlocks; j++)\n"
 "        if (malloc(blockSize * (2 + tn)) == NULL)\n"
 "            errExit(\"malloc-thread\");\n"
 msgstr ""
-"    for (j = 0; j E<lt> numBlocks; j++)\n"
+"    for (int j = 0; j E<lt> numBlocks; j++)\n"
 "        if (malloc(blockSize * (2 + tn)) == NULL)\n"
 "            errExit(\"malloc-thread\");\n"
 
@@ -4416,12 +4111,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:214
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "    int j;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -4431,7 +4121,7 @@ msgstr ""
 "int\n"
 "main(int argc, char *argv[])\n"
 "{\n"
-"    int j;\n"
+"    int sleepTime;\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:221
@@ -4467,17 +4157,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:230
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    thr = calloc(numThreads, sizeof(pthread_t));\n"
-#| "    if (thr == NULL)\n"
-#| "        errExit(\"calloc\");\n"
+#, no-wrap
 msgid ""
 "    pthread_t *thr = calloc(numThreads, sizeof(*thr));\n"
 "    if (thr == NULL)\n"
 "        errExit(\"calloc\");\n"
 msgstr ""
-"    thr = calloc(numThreads, sizeof(pthread_t));\n"
+"    pthread_t *thr = calloc(numThreads, sizeof(*thr));\n"
 "    if (thr == NULL)\n"
 "        errExit(\"calloc\");\n"
 
@@ -4499,13 +4185,7 @@ msgstr "    /* Create threads that allocate different amounts of memory */\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:241
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (tn = 0; tn E<lt> numThreads; tn++) {\n"
-#| "        errno = pthread_create(&thr[tn], NULL, thread_func,\n"
-#| "                               (void *) tn);\n"
-#| "        if (errno != 0)\n"
-#| "            errExit(\"pthread_create\");\n"
+#, no-wrap
 msgid ""
 "    for (int tn = 0; tn E<lt> numThreads; tn++) {\n"
 "        errno = pthread_create(&thr[tn], NULL, thread_func,\n"
@@ -4513,7 +4193,7 @@ msgid ""
 "        if (errno != 0)\n"
 "            errExit(\"pthread_create\");\n"
 msgstr ""
-"    for (tn = 0; tn E<lt> numThreads; tn++) {\n"
+"    for (int tn = 0; tn E<lt> numThreads; tn++) {\n"
 "        errno = pthread_create(&thr[tn], NULL, thread_func,\n"
 "                               (void *) tn);\n"
 "        if (errno != 0)\n"
@@ -4553,17 +4233,13 @@ msgstr "    /* The main thread also allocates some memory */\n"
 
 #. type: Plain text
 #: build/C/man3/malloc_info.3:256
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (j = 0; j E<lt> numBlocks; j++)\n"
-#| "        if (malloc(blockSize) == NULL)\n"
-#| "            errExit(\"malloc\");\n"
+#, no-wrap
 msgid ""
 "    for (int j = 0; j E<lt> numBlocks; j++)\n"
 "        if (malloc(blockSize) == NULL)\n"
 "            errExit(\"malloc\");\n"
 msgstr ""
-"    for (j = 0; j E<lt> numBlocks; j++)\n"
+"    for (int j = 0; j E<lt> numBlocks; j++)\n"
 "        if (malloc(blockSize) == NULL)\n"
 "            errExit(\"malloc\");\n"
 
@@ -4605,10 +4281,9 @@ msgstr "MALLOC_STATS"
 #. type: TH
 #: build/C/man3/malloc_stats.3:25 build/C/man3/malloc_trim.3:25
 #: build/C/man7/shm_overview.7:26
-#, fuzzy, no-wrap
-#| msgid "2014-08-19"
+#, no-wrap
 msgid "2020-08-13"
-msgstr "2014-08-19"
+msgstr "2020-08-13"
 
 #. type: Plain text
 #: build/C/man3/malloc_stats.3:28
@@ -4644,10 +4319,9 @@ msgstr ""
 
 #. type: tbl table
 #: build/C/man3/malloc_stats.3:64
-#, fuzzy, no-wrap
-#| msgid "B<malloc>(3)"
+#, no-wrap
 msgid "B<malloc_stats>()"
-msgstr "B<malloc>(3)"
+msgstr "B<malloc_stats>()"
 
 #. type: Plain text
 #: build/C/man3/malloc_stats.3:73
@@ -4673,10 +4347,8 @@ msgstr "MALLOC_TRIM"
 
 #. type: Plain text
 #: build/C/man3/malloc_trim.3:28
-#, fuzzy
-#| msgid "malloc_trim - release free memory from the top of the heap"
 msgid "malloc_trim - release free memory from the heap"
-msgstr "malloc_trim - ã\83\92ã\83¼ã\83\97ã\81®ä¸\80ç\95ªä¸\8aã\81\8bã\82\89æ\9cªä½¿ç\94¨ã\83¡ã\83¢ã\83ªã\83¼ã\82\92解æ\94¾ã\81\99ã\82\8b"
+msgstr "malloc_trim - ヒープから未使用メモリーを解放する"
 
 #. type: Plain text
 #: build/C/man3/malloc_trim.3:32
@@ -4685,16 +4357,10 @@ msgstr "B<int malloc_trim(size_t >I<pad>B<);>"
 
 #. type: Plain text
 #: build/C/man3/malloc_trim.3:41
-#, fuzzy
-#| msgid ""
-#| "The B<malloc_trim>()  function attempts to release free memory at the top "
-#| "of the heap (by calling B<sbrk>(2)  with a suitable argument)."
 msgid ""
 "The B<malloc_trim>()  function attempts to release free memory from the heap "
 "(by calling B<sbrk>(2)  or B<madvise>(2)  with suitable arguments)."
-msgstr ""
-"B<malloc_trim>() 関数は (適切な引き数で B<sbrk>(2) を呼び出して) ヒープの一番"
-"上の未使用メモリーの解放を試みる。"
+msgstr "B<malloc_trim>() 関数は (適切な引き数で B<sbrk>(2) や B<madvise>(2) を呼び出して) ヒープの未使用メモリーの解放を試みる。"
 
 #. type: Plain text
 #: build/C/man3/malloc_trim.3:52
@@ -4730,10 +4396,9 @@ msgstr "エラーは定義されていない。"
 
 #. type: tbl table
 #: build/C/man3/malloc_trim.3:71
-#, fuzzy, no-wrap
-#| msgid "B<malloc>(3)"
+#, no-wrap
 msgid "B<malloc_trim>()"
-msgstr "B<malloc>(3)"
+msgstr "B<malloc_trim>()"
 
 #. type: Plain text
 #: build/C/man3/malloc_trim.3:85
@@ -4819,10 +4484,9 @@ msgstr ""
 
 #. type: tbl table
 #: build/C/man3/malloc_usable_size.3:58
-#, fuzzy, no-wrap
-#| msgid "B<size_t malloc_usable_size (void *>I<ptr>B<);>"
+#, no-wrap
 msgid "B<malloc_usable_size>()"
-msgstr "B<size_t malloc_usable_size (void *>I<ptr>B<);>"
+msgstr "B<malloc_usable_size>()"
 
 #. type: Plain text
 #: build/C/man3/malloc_usable_size.3:72
@@ -4859,10 +4523,9 @@ msgstr "MALLOPT"
 #. type: TH
 #: build/C/man3/mallopt.3:25 build/C/man3/mcheck.3:25 build/C/man2/mremap.2:30
 #: build/C/man2/msync.2:25 build/C/man2/pkey_alloc.2:25 build/C/man7/pkeys.7:25
-#, fuzzy, no-wrap
-#| msgid "2010-06-10"
+#, no-wrap
 msgid "2020-06-09"
-msgstr "2010-06-10"
+msgstr "2020-06-09"
 
 #. type: Plain text
 #: build/C/man3/mallopt.3:28
@@ -4894,10 +4557,9 @@ msgstr "I<param> には以下の値を指定することができる。"
 
 #. type: TP
 #: build/C/man3/mallopt.3:46
-#, fuzzy, no-wrap
-#| msgid "B<M_MMAP_MAX>"
+#, no-wrap
 msgid "B<M_ARENA_MAX>"
-msgstr "B<M_MMAP_MAX>"
+msgstr "B<M_ARENA_MAX>"
 
 #. type: Plain text
 #: build/C/man3/mallopt.3:58
@@ -4941,7 +4603,7 @@ msgstr ""
 #: build/C/man3/mallopt.3:77
 #, no-wrap
 msgid "B<M_ARENA_TEST>"
-msgstr ""
+msgstr "B<M_ARENA_TEST>"
 
 #. type: Plain text
 #: build/C/man3/mallopt.3:85
@@ -5381,10 +5043,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man3/mallopt.3:370
-#, fuzzy, no-wrap
-#| msgid "B<MALLOC_MMAP_MAX_>"
+#, no-wrap
 msgid "B<MALLOC_ARENA_MAX>"
-msgstr "B<MALLOC_MMAP_MAX_>"
+msgstr "B<MALLOC_ARENA_MAX>"
 
 #. type: Plain text
 #: build/C/man3/mallopt.3:375
@@ -5393,10 +5054,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man3/mallopt.3:375
-#, fuzzy, no-wrap
-#| msgid "B<MALLOC_CHECK_>"
+#, no-wrap
 msgid "B<MALLOC_ARENA_TEST>"
-msgstr "B<MALLOC_CHECK_>"
+msgstr "B<MALLOC_ARENA_TEST>"
 
 #. type: Plain text
 #: build/C/man3/mallopt.3:380
@@ -5537,10 +5197,9 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/mallopt.3:479
-#, fuzzy, no-wrap
-#| msgid "    mallopt(M_MXFAST, n)\n"
+#, no-wrap
 msgid "mallopt(M_MXFAST, n)\n"
-msgstr "    mallopt(M_MXFAST, n)\n"
+msgstr "mallopt(M_MXFAST, n)\n"
 
 #.  Bins are multiples of 2 * sizeof(size_t) + sizeof(size_t)
 #. type: Plain text
@@ -5788,13 +5447,13 @@ msgstr "B<#include E<lt>mcheck.hE<gt>>\n"
 #: build/C/man3/mcheck.3:33
 #, no-wrap
 msgid "B<int mcheck(void (*>I<abortfunc>B<)(enum mcheck_status >I<mstatus>B<));>\n"
-msgstr ""
+msgstr "B<int mcheck(void (*>I<abortfunc>B<)(enum mcheck_status >I<mstatus>B<));>\n"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:35
 #, no-wrap
 msgid "B<int mcheck_pedantic(void (*>I<abortfunc>B<)(enum mcheck_status >I<mstatus>B<));>\n"
-msgstr ""
+msgstr "B<int mcheck_pedantic(void (*>I<abortfunc>B<)(enum mcheck_status >I<mstatus>B<));>\n"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:37
@@ -5874,7 +5533,7 @@ msgstr ""
 #: build/C/man3/mcheck.3:111
 #, no-wrap
 msgid "B<MCHECK_DISABLED> (B<mprobe>() only)"
-msgstr ""
+msgstr "B<MCHECK_DISABLED> (B<mprobe>() のみ)"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:116
@@ -5887,7 +5546,7 @@ msgstr ""
 #: build/C/man3/mcheck.3:116
 #, no-wrap
 msgid "B<MCHECK_OK> (B<mprobe>() only)"
-msgstr ""
+msgstr "B<MCHECK_OK> (B<mprobe>() のみ)"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:119
@@ -5948,6 +5607,8 @@ msgid ""
 "B<mcheck>(),\n"
 "B<mcheck_pedantic>(),\n"
 msgstr ""
+"B<mcheck>(),\n"
+"B<mcheck_pedantic>(),\n"
 
 #. type: tbl table
 #: build/C/man3/mcheck.3:156 build/C/man3/mcheck.3:161
@@ -5955,16 +5616,17 @@ msgstr ""
 #: build/C/man3/posix_memalign.3:207
 #, no-wrap
 msgid ".br\n"
-msgstr ""
+msgstr ".br\n"
 
 #. type: tbl table
 #: build/C/man3/mcheck.3:159
-#, fuzzy, no-wrap
-#| msgid "B<void mcheck_check_all(void);>\n"
+#, no-wrap
 msgid ""
 "B<mcheck_check_all>(),\n"
 "B<mprobe>()"
-msgstr "B<void mcheck_check_all(void);>\n"
+msgstr ""
+"B<mcheck_check_all>(),\n"
+"B<mprobe>()"
 
 #. type: tbl table
 #: build/C/man3/mcheck.3:161
@@ -5976,7 +5638,7 @@ msgstr "MT-Unsafe race:mcheck\n"
 #: build/C/man3/mcheck.3:163
 #, no-wrap
 msgid "const:malloc_hooks"
-msgstr ""
+msgstr "const:malloc_hooks"
 
 #.  But is MALLOC_CHECK_ slower?
 #. type: Plain text
@@ -6003,6 +5665,8 @@ msgid ""
 "$B< ./a.out>\n"
 "About to free\n"
 msgstr ""
+"$B< ./a.out>\n"
+"About to free\n"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:195
@@ -6032,6 +5696,8 @@ msgid ""
 "    if (mcheck(NULL) != 0) {\n"
 "        fprintf(stderr, \"mcheck() failed\\en\");\n"
 msgstr ""
+"    if (mcheck(NULL) != 0) {\n"
+"        fprintf(stderr, \"mcheck() failed\\en\");\n"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:214
@@ -6058,6 +5724,10 @@ msgid ""
 "    fprintf(stderr, \"\\enAbout to free a second time\\en\");\n"
 "    free(p);\n"
 msgstr ""
+"    fprintf(stderr, \"About to free\\en\");\n"
+"    free(p);\n"
+"    fprintf(stderr, \"\\enAbout to free a second time\\en\");\n"
+"    free(p);\n"
 
 #. type: Plain text
 #: build/C/man3/mcheck.3:229
@@ -6072,10 +5742,8 @@ msgstr "MLOCK"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:29
-#, fuzzy
-#| msgid "mlock, munlock, mlockall, munlockall - lock and unlock memory"
 msgid "mlock, mlock2, munlock, mlockall, munlockall - lock and unlock memory"
-msgstr "mlock - メモリーのロックとロック解除を行う"
+msgstr "mlock, mlock2, munlock, mlockall, munlockall - メモリーのロックとロック解除を行う"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:32 build/C/man2/mmap.2:46 build/C/man2/mmap2.2:35
@@ -6086,16 +5754,14 @@ msgstr "B<#include E<lt>sys/mman.hE<gt>>\n"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:36
-#, fuzzy, no-wrap
-#| msgid ""
-#| "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
-#| "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
+#, no-wrap
 msgid ""
 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
 "B<int mlock2(const void *>I<addr>B<, size_t >I<len>B<, int >I<flags>B<);>\n"
 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
 msgstr ""
 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
+"B<int mlock2(const void *>I<addr>B<, size_t >I<len>B<, int >I<flags>B<);>\n"
 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
 
 #. type: Plain text
@@ -6114,45 +5780,27 @@ msgid ""
 "B<mlock>(), B<mlock2>(), and B<mlockall>()  lock part or all of the calling "
 "process's virtual address space into RAM, preventing that memory from being "
 "paged to the swap area."
-msgstr ""
+msgstr "B<mlock>() と B<mlockall>() は、呼び出し元プロセスの仮想アドレス空間の一部または全部を RAM 上にロックし、メモリーがスワップエリアにページングされるのを防ぐ。"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:56
-#, fuzzy
-#| msgid ""
-#| "B<mlock>()  and B<mlockall>()  respectively lock part or all of the "
-#| "calling process's virtual address space into RAM, preventing that memory "
-#| "from being paged to the swap area.  B<munlock>()  and B<munlockall>()  "
-#| "perform the converse operation, respectively unlocking part or all of the "
-#| "calling process's virtual address space, so that pages in the specified "
-#| "virtual address range may once more to be swapped out if required by the "
-#| "kernel memory manager.  Memory locking and unlocking are performed in "
-#| "units of whole pages."
 msgid ""
 "B<munlock>()  and B<munlockall>()  perform the converse operation, unlocking "
 "part or all of the calling process's virtual address space, so that pages in "
 "the specified virtual address range may once more to be swapped out if "
 "required by the kernel memory manager."
-msgstr ""
-"B<mlock>()  と B<mlockall>()  はそれぞれ、呼び出し元プロセスの仮想アドレス空"
-"間の一部または全部を RAM 上にロックし、メモリーがスワップエリアにページングさ"
-"れるのを防ぐ。 B<munlock>()  と B<munlockall>()  は逆の操作で、それぞれ呼び出"
-"し元プロセスの仮想アドレス空間の一部または全部を ロック解除する。つまり、指定"
-"された仮想アドレス範囲のページは カーネルメモリーマネージャーから要求されれば"
-"スワップアウトするようになる。 メモリーのロックとロック解除はページ単位で行わ"
-"れる。"
+msgstr "B<munlock>()  と B<munlockall>()  は逆の操作で、それぞれ呼び出し元プロセスの仮想アドレス空間の一部または全部を ロック解除する。つまり、指定された仮想アドレス範囲のページは カーネルメモリーマネージャーから要求されればスワップアウトするようになる。 メモリーのロックとロック解除はページ単位で行われる。"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:58
 msgid "Memory locking and unlocking are performed in units of whole pages."
-msgstr ""
+msgstr "メモリーのロックとロック解除はページ単位で行われる。"
 
 #. type: SS
 #: build/C/man2/mlock.2:58
-#, fuzzy, no-wrap
-#| msgid "mlock() and munlock()"
+#, no-wrap
 msgid "mlock(), mlock2(), and munlock()"
-msgstr "mlock() と munlock()"
+msgstr "mlock(), mlock2(), munlock()"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:68
@@ -6201,10 +5849,9 @@ msgstr "I<flags> 引数は以下の内容の一つまたは複数のビット OR
 
 #. type: TP
 #: build/C/man2/mlock.2:86
-#, fuzzy, no-wrap
-#| msgid "B<EFAULT>"
+#, no-wrap
 msgid "B<MLOCK_ONFAULT>"
-msgstr "B<EFAULT>"
+msgstr "B<MLOCK_ONFAULT>"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:91
@@ -6283,12 +5930,6 @@ msgstr "B<MCL_FUTURE>"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:133
-#, fuzzy
-#| msgid ""
-#| "Lock all pages which will become mapped into the address space of the "
-#| "process in the future.  These could be for instance new pages required by "
-#| "a growing heap and stack as well as new memory-mapped files or shared "
-#| "memory regions."
 msgid ""
 "Lock all pages which will become mapped into the address space of the "
 "process in the future.  These could be, for instance, new pages required by "
@@ -6301,10 +5942,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/mlock.2:133
-#, fuzzy, no-wrap
-#| msgid "B<MAP_POPULATE> (since Linux 2.5.46)"
+#, no-wrap
 msgid "B<MCL_ONFAULT> (since Linux 4.4)"
-msgstr "B<MAP_POPULATE> (Linux 2.5.46 以降)"
+msgstr "B<MCL_ONFAULT> (Linux 4.4 以降)"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:160
@@ -6345,11 +5985,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mlock.2:183
-#, fuzzy
-#| msgid ""
-#| "On success these system calls return 0.  On error, -1 is returned, "
-#| "I<errno> is set appropriately, and no changes are made to any locks in "
-#| "the address space of the process."
 msgid ""
 "On success, these system calls return 0.  On error, -1 is returned, I<errno> "
 "is set appropriately, and no changes are made to any locks in the address "
@@ -6410,16 +6045,10 @@ msgstr "指定されたアドレス範囲の一部または全てをロックす
 
 #. type: Plain text
 #: build/C/man2/mlock.2:226
-#, fuzzy
-#| msgid ""
-#| "The result of the addition I<start>+I<len> was less than I<start> (e.g., "
-#| "the addition may have resulted in an overflow)."
 msgid ""
 "The result of the addition I<addr>+I<len> was less than I<addr> (e.g., the "
 "addition may have resulted in an overflow)."
-msgstr ""
-"I<start>+I<len> の加算の結果が I<start> よりも小さかった\n"
-"(例えば、加算でオーバーフローが発生したなど)。"
+msgstr "I<addr>+I<len> の加算の結果が I<addr> よりも小さかった (例えば、加算でオーバーフローが発生したなど)。"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:231
@@ -6500,17 +6129,13 @@ msgstr ""
 #. type: Plain text
 #: build/C/man2/mlock.2:274 build/C/man2/shmctl.2:467 build/C/man2/shmget.2:283
 #: build/C/man2/shmop.2:230
-#, fuzzy
-#| msgid "POSIX.1-2001, SVr4."
 msgid "POSIX.1-2001, POSIX.1-2008, SVr4."
-msgstr "POSIX.1-2001, SVr4."
+msgstr "POSIX.1-2001, POSIX.1-2008, SVr4."
 
 #. type: Plain text
 #: build/C/man2/mlock.2:277
-#, fuzzy
-#| msgid "B<fallocate>()  is Linux-specific."
 msgid "B<mlock2>()  is Linux specific."
-msgstr "B<fallocate>()  は Linux 固有である。"
+msgstr "B<mlock2>() は Linux 固有である。"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:289
@@ -6635,14 +6260,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mlock.2:380
-#, fuzzy
-#| msgid ""
-#| "Memory locks do not stack, that is, pages which have been locked several "
-#| "times by calls to B<mlock>()  or B<mlockall>()  will be unlocked by a "
-#| "single call to B<munlock>()  for the corresponding range or by "
-#| "B<munlockall>().  Pages which are mapped to several locations or by "
-#| "several processes stay locked into RAM as long as they are locked at "
-#| "least at one location or by at least one process."
 msgid ""
 "Memory locks do not stack, that is, pages which have been locked several "
 "times by calls to B<mlock>(), B<mlock2>(), or B<mlockall>()  will be "
@@ -6650,12 +6267,7 @@ msgid ""
 "B<munlockall>().  Pages which are mapped to several locations or by several "
 "processes stay locked into RAM as long as they are locked at least at one "
 "location or by at least one process."
-msgstr ""
-"メモリーのロックは累積しない。 すなわち複数回 B<mlock>()  や B<mlockall>()  "
-"を呼び出してロックされたページでも、 対応する範囲に対して B<munlock>()  を 1 "
-"回呼び出したり B<munlockall>()  を呼び出したりするだけでロック解除される。 複"
-"数の場所や複数のプロセスにマップされているページは、少なくとも一つの場所、 一"
-"つのプロセスでロックされている限りは RAM に残り続ける。"
+msgstr "メモリーのロックは累積しない。 すなわち複数回 B<mlock>(), B<mlock2>(), B<mlockall>()  を呼び出してロックされたページでも、 対応する範囲に対して B<munlock>()  を 1 回呼び出したり B<munlockall>()  を呼び出したりするだけでロック解除される。 複数の場所や複数のプロセスにマップされているページは、少なくとも一つの場所、 一つのプロセスでロックされている限りは RAM に残り続ける。"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:389
@@ -6677,40 +6289,21 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mlock.2:416
-#, fuzzy
-#| msgid ""
-#| "Under Linux, B<mlock>()  and B<munlock>()  automatically round I<addr> "
-#| "down to the nearest page boundary.  However, POSIX.1-2001 allows an "
-#| "implementation to require that I<addr> is page aligned, so portable "
-#| "applications should ensure this."
 msgid ""
 "Under Linux, B<mlock>(), B<mlock2>(), and B<munlock>()  automatically round "
 "I<addr> down to the nearest page boundary.  However, the POSIX.1 "
 "specification of B<mlock>()  and B<munlock>()  allows an implementation to "
 "require that I<addr> is page aligned, so portable applications should ensure "
 "this."
-msgstr ""
-"Linux では、 B<mlock>()  と B<munlock>()  は自動的に I<addr> を端数切り捨てに"
-"より一番近いページ境界へと丸める。 しかし POSIX.1-2001 は I<addr> がページ境"
-"界に合っていることを要求する実装も許している。 そのため移植性を意図したアプリ"
-"ケーションではきちんと境界に合わせた方が良い。"
+msgstr "Linux では、 B<mlock>(), B<mlock2>(), B<munlock>() は自動的に I<addr> を端数切り捨てにより一番近いページ境界へと丸める。 しかし POSIX.1 仕様の B<mlock>() と B<munlock>() は I<addr> がページ境界に合っていることを要求する実装も許している。 そのため移植性を意図したアプリケーションではきちんと境界に合わせた方が良い。"
 
 #. type: Plain text
 #: build/C/man2/mlock.2:430
-#, fuzzy
-#| msgid ""
-#| "The I<VmLck> field of the Linux-specific I</proc/PID/status> file shows "
-#| "how many kilobytes of memory the process with ID I<PID> has locked using "
-#| "B<mlock>(), B<mlockall>(), and B<mmap>(2)  B<MAP_LOCKED>."
 msgid ""
 "The I<VmLck> field of the Linux-specific I</proc/[pid]/status> file shows "
 "how many kilobytes of memory the process with ID I<PID> has locked using "
 "B<mlock>(), B<mlock2>(), B<mlockall>(), and B<mmap>(2)  B<MAP_LOCKED>."
-msgstr ""
-"Linux 固有の I</proc/PID/status> ファイルの I<VmLck> フィールドには、\n"
-"B<mlock>(), B<mlockall>() および B<mmap>(2) B<MAP_LOCKED> を使って、\n"
-"ID が I<PID> のプロセスがロックしているメモリー量 (キロバイト単位) が\n"
-"表示される。"
+msgstr "Linux 固有の I</proc/[pid]/status> ファイルの I<VmLck> フィールドには、 B<mlock>(), B<mlock2>(), B<mlockall>() および B<mmap>(2) B<MAP_LOCKED> を使って、 ID が I<PID> のプロセスがロックしているメモリー量 (キロバイト単位) が表示される。"
 
 #. type: SS
 #: build/C/man2/mlock.2:430
@@ -6787,16 +6380,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mlock.2:499
-#, fuzzy
-#| msgid ""
-#| "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5), "
-#| "B<capabilities>(7)"
 msgid ""
 "B<mincore>(2), B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), "
 "B<proc>(5), B<capabilities>(7)"
-msgstr ""
-"B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5),\n"
-"B<capabilities>(7)"
+msgstr "B<mincore>(2), B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5), B<capabilities>(7)"
 
 #. type: TH
 #: build/C/man2/mmap.2:40
@@ -6828,20 +6415,12 @@ msgstr "機能検査マクロの要件に関する情報は「注意」の節を
 
 #. type: Plain text
 #: build/C/man2/mmap.2:63
-#, fuzzy
-#| msgid ""
-#| "B<mmap>()  creates a new mapping in the virtual address space of the "
-#| "calling process.  The starting address for the new mapping is specified "
-#| "in I<addr>.  The I<length> argument specifies the length of the mapping."
 msgid ""
 "B<mmap>()  creates a new mapping in the virtual address space of the calling "
 "process.  The starting address for the new mapping is specified in I<addr>.  "
 "The I<length> argument specifies the length of the mapping (which must be "
 "greater than 0)."
-msgstr ""
-"B<mmap>()  は、新しいマッピングを呼び出し元プロセスの仮想アドレス空間に作成す"
-"る。 新しいマッピングの開始アドレスは I<addr> で指定される。マッピングの長さ"
-"は I<length> 引き数で指定される。"
+msgstr "B<mmap>()  は、新しいマッピングを呼び出し元プロセスの仮想アドレス空間に作成する。 新しいマッピングの開始アドレスは I<addr> で指定される。マッピングの長さは I<length> 引き数で指定される (正の値でなければならない)。"
 
 #.  Before Linux 2.6.24, the address was rounded up to the next page
 #.  boundary; since 2.6.24, it is rounded down!
@@ -6995,10 +6574,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/mmap.2:140
-#, fuzzy, no-wrap
-#| msgid "B<MAP_POPULATE> (since Linux 2.5.46)"
+#, no-wrap
 msgid "B<MAP_SHARED_VALIDATE> (since Linux 4.15)"
-msgstr "B<MAP_POPULATE> (Linux 2.5.46 以降)"
+msgstr "B<MAP_SHARED_VALIDATE> (Linux 4.15 以降)"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:157
@@ -7055,15 +6633,6 @@ msgstr "B<MAP_32BIT> (Linux 2.4.20, 2.6 以降)"
 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
 #. type: Plain text
 #: build/C/man2/mmap.2:193
-#, fuzzy
-#| msgid ""
-#| "Put the mapping into the first 2 Gigabytes of the process address space.  "
-#| "This flag is supported only on x86-64, for 64-bit programs.  It was added "
-#| "to allow thread stacks to be allocated somewhere in the first 2GB of "
-#| "memory, so as to improve context-switch performance on some early 64-bit "
-#| "processors.  Modern x86-64 processors no longer have this performance "
-#| "problem, so use of this flag is not required on those systems.  The "
-#| "B<MAP_32BIT> flag is ignored when B<MAP_FIXED> is set."
 msgid ""
 "Put the mapping into the first 2 Gigabytes of the process address space.  "
 "This flag is supported only on x86-64, for 64-bit programs.  It was added to "
@@ -7072,15 +6641,7 @@ msgid ""
 "processors.  Modern x86-64 processors no longer have this performance "
 "problem, so use of this flag is not required on those systems.  The "
 "B<MAP_32BIT> flag is ignored when B<MAP_FIXED> is set."
-msgstr ""
-"マッピングをプロセスのアドレス空間の先頭 2 ギガバイト以内に配置する。 このフ"
-"ラグがサポートされているのは x86-64 アーキテクチャー上の 64 ビットプログラム"
-"のみである。 このフラグが追加されたのは、スレッドのスタックをメモリーの先頭 "
-"2GB 以内の どこかに割り当てることで、初期のいくつかの 64 ビットプロセッサにお"
-"ける コンテキストスイッチの性能問題を改善するためである。 最近の x86-64 プロ"
-"セッサではこの性能問題はもはや存在せず、 そのようなシステムではこのフラグを使"
-"用する必要はない。 B<MAP_FIXED> がセットされている場合は、 B<MAP_32BIT> フラ"
-"グは無視される。"
+msgstr "マッピングをプロセスのアドレス空間の先頭 2 ギガバイト以内に配置する。 このフラグがサポートされているのは x86-64 アーキテクチャー上の 64 ビットプログラムのみである。 このフラグが追加されたのは、スレッドのスタックをメモリーの先頭 2\\ GB 以内の どこかに割り当てることで、初期のいくつかの 64 ビットプロセッサにおける コンテキストスイッチの性能問題を改善するためである。 最近の x86-64 プロセッサではこの性能問題はもはや存在せず、 そのようなシステムではこのフラグを使用する必要はない。 B<MAP_FIXED> がセットされている場合は、 B<MAP_32BIT> フラグは無視される。"
 
 #. type: TP
 #: build/C/man2/mmap.2:193
@@ -7105,14 +6666,6 @@ msgstr "B<MAP_ANONYMOUS>"
 #.  See the offset check in sys_mmap in arch/x86/kernel/sys_x86_64.c.
 #. type: Plain text
 #: build/C/man2/mmap.2:223
-#, fuzzy
-#| msgid ""
-#| "The mapping is not backed by any file; its contents are initialized to "
-#| "zero.  The I<fd> and I<offset> arguments are ignored; however, some "
-#| "implementations require I<fd> to be -1 if B<MAP_ANONYMOUS> (or "
-#| "B<MAP_ANON>)  is specified, and portable applications should ensure "
-#| "this.  The use of B<MAP_ANONYMOUS> in conjunction with B<MAP_SHARED> is "
-#| "supported on Linux only since kernel 2.4."
 msgid ""
 "The mapping is not backed by any file; its contents are initialized to "
 "zero.  The I<fd> argument is ignored; however, some implementations require "
@@ -7120,13 +6673,7 @@ msgid ""
 "portable applications should ensure this.  The I<offset> argument should be "
 "zero.  The use of B<MAP_ANONYMOUS> in conjunction with B<MAP_SHARED> is "
 "supported on Linux only since kernel 2.4."
-msgstr ""
-"マッピングはどのファイルとも関連付けされない。 マッピングの内容は 0 で初期化"
-"される。 引き数 I<fd> と I<offset> は無視される。 ただし、実装によっては "
-"B<MAP_ANONYMOUS> (もしくは B<MAP_ANON>)  が指定された場合、 I<fd> を -1 にす"
-"る必要があり、 移植性が必要なアプリケーションでは必ず I<fd> を -1 にすべきで"
-"ある。 B<MAP_ANONYMOUS> と B<MAP_SHARED> を組み合わせての利用は カーネル 2.4 "
-"以降の Linux でのみサポートされている。"
+msgstr "マッピングはどのファイルとも関連付けされない。 マッピングの内容は 0 で初期化される。 引き数 I<fd> は無視される。 ただし、実装によっては B<MAP_ANONYMOUS> (もしくは B<MAP_ANON>)  が指定された場合、 I<fd> を -1 にする必要があり、 移植性が必要なアプリケーションでは必ず I<fd> を -1 にすべきである。 I<offset> 引き数は 0 にすべきである。 B<MAP_ANONYMOUS> と B<MAP_SHARED> を組み合わせての利用は カーネル 2.4 以降の Linux でのみサポートされている。"
 
 #. type: TP
 #: build/C/man2/mmap.2:223
@@ -7137,19 +6684,11 @@ msgstr "B<MAP_DENYWRITE>"
 #.  Introduced in 1.1.36, removed in 1.3.24.
 #. type: Plain text
 #: build/C/man2/mmap.2:231
-#, fuzzy
-#| msgid ""
-#| "This flag is ignored.  (Long ago, it signaled that attempts to write to "
-#| "the underlying file should fail with B<ETXTBUSY>.  But this was a source "
-#| "of denial-of-service attacks.)"
 msgid ""
 "This flag is ignored.  (Long ago\\(emLinux 2.0 and earlier\\(emit signaled "
 "that attempts to write to the underlying file should fail with B<ETXTBSY>.  "
 "But this was a source of denial-of-service attacks.)"
-msgstr ""
-"このフラグは無視される (ずっと前は、マップ元のファイルへの書き込みを行おうと"
-"すると、エラー B<ETXTBUSY> で失敗するようにシグナルが設定されていたが、これ"
-"は denial-of-service (サービス拒否) 攻撃の原因となった)。"
+msgstr "このフラグは無視される (ずっと前は \\(em Linux 2.0 以前 \\(em 、マップ元のファイルへの書き込みを行おうとすると、エラー B<ETXTBSY> で失敗するようにシグナルが設定されていたが、これは denial-of-service (サービス拒否) 攻撃の原因となった)。"
 
 #. type: TP
 #: build/C/man2/mmap.2:231
@@ -7226,10 +6765,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/mmap.2:271
-#, fuzzy, no-wrap
-#| msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
+#, no-wrap
 msgid "B<MAP_FIXED_NOREPLACE> (since Linux 4.17)"
-msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
+msgstr "B<MAP_FIXED_NOREPLACE> (Linux 4.17 以降)"
 
 #.  commit a4ff8e8620d3f4f50ac4b41e8067b7d395056843
 #. type: Plain text
@@ -7282,24 +6820,17 @@ msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:317
-#, fuzzy
-#| msgid ""
-#| "Allocate the mapping using \"huge pages.\" See the Linux kernel source "
-#| "file I<Documentation/vm/hugetlbpage.txt> for further information."
 msgid ""
 "Allocate the mapping using \"huge pages.\" See the Linux kernel source file "
 "I<Documentation/admin-guide/mm/hugetlbpage.rst> for further information, as "
 "well as NOTES, below."
-msgstr ""
-"\"huge page\" を使ってマッピングを割り当てる。詳しい情報は、Linux カーネル"
-"ソースの I<Documentation/vm/hugetlbpage.txt> を参照。"
+msgstr "\"huge page\" を使ってマッピングを割り当てる。詳しい情報は、Linux カーネルソースの I<Documentation/admin-guide/vm/hugetlbpage.txt> を参照。下記の「注意」も参照。"
 
 #. type: TP
 #: build/C/man2/mmap.2:317
-#, fuzzy, no-wrap
-#| msgid "B<MADV_HUGEPAGE> (since Linux 2.6.38)"
+#, no-wrap
 msgid "B<MAP_HUGE_2MB>, B<MAP_HUGE_1GB> (since Linux 3.8)"
-msgstr "B<MADV_HUGEPAGE> (Linux 2.6.38 以降)"
+msgstr "B<MAP_HUGE_2MB>, B<MAP_HUGE_1GB> (Linux 3.8 以降)"
 
 #.  See https://lwn.net/Articles/533499/
 #. type: Plain text
@@ -7364,25 +6895,13 @@ msgstr "B<MAP_NONBLOCK> (Linux 2.5.46 以降)"
 #.  commit 54cb8821de07f2ffcd28c380ce9b93d5784b40d7
 #. type: Plain text
 #: build/C/man2/mmap.2:383
-#, fuzzy
-#| msgid ""
-#| "Only meaningful in conjunction with B<MAP_POPULATE>.  Don't perform read-"
-#| "ahead: create page tables entries only for pages that are already present "
-#| "in RAM.  Since Linux 2.6.23, this flag causes B<MAP_POPULATE> to do "
-#| "nothing.  One day the combination of B<MAP_POPULATE> and B<MAP_NONBLOCK> "
-#| "may be reimplemented."
 msgid ""
 "This flag is meaningful only in conjunction with B<MAP_POPULATE>.  Don't "
 "perform read-ahead: create page tables entries only for pages that are "
 "already present in RAM.  Since Linux 2.6.23, this flag causes "
 "B<MAP_POPULATE> to do nothing.  One day, the combination of B<MAP_POPULATE> "
 "and B<MAP_NONBLOCK> may be reimplemented."
-msgstr ""
-"B<MAP_POPULATE> と組み合わせた場合のみ意味を持つ。 read-ahead (前もって読み込"
-"むこと) を実行しない。 単に、すでに RAM 上に存在するページに対してのみページ"
-"テーブルエントリーを作成する。 Linux 2.6.23 以降では、このフラグは "
-"B<MAP_POPULATE> に何の影響も与えない。 いつか B<MAP_POPULATE> と "
-"B<MAP_NONBLOCK> を組み合わせた場合の動作は実装し直されるかもしれない。"
+msgstr "このフラグは B<MAP_POPULATE> と組み合わせた場合のみ意味を持つ。 read-ahead (前もって読み込むこと) を実行しない。 単に、すでに RAM 上に存在するページに対してのみページテーブルエントリーを作成する。 Linux 2.6.23 以降では、このフラグは B<MAP_POPULATE> に何の影響も与えない。 いつか B<MAP_POPULATE> と B<MAP_NONBLOCK> を組み合わせた場合の動作は実装し直されるかもしれない。"
 
 #. type: TP
 #: build/C/man2/mmap.2:383
@@ -7464,10 +6983,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/mmap.2:425
-#, fuzzy, no-wrap
-#| msgid "B<MAP_STACK> (since Linux 2.6.27)"
+#, no-wrap
 msgid "B<MAP_SYNC> (since Linux 4.15)"
-msgstr "B<MAP_STACK> (Linux 2.6.27 以降)"
+msgstr "B<MAP_SYNC> (Linux 4.15 以降)"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:438
@@ -7520,19 +7038,11 @@ msgstr ""
 #.  http://austingroupbugs.net/view.php?id=850
 #. type: Plain text
 #: build/C/man2/mmap.2:468
-#, fuzzy
-#| msgid ""
-#| "Of the above flags, only B<MAP_FIXED> is specified in POSIX.1-2001.  "
-#| "However, most systems also support B<MAP_ANONYMOUS> (or its synonym "
-#| "B<MAP_ANON>)."
 msgid ""
 "Of the above flags, only B<MAP_FIXED> is specified in POSIX.1-2001 and "
 "POSIX.1-2008.  However, most systems also support B<MAP_ANONYMOUS> (or its "
 "synonym B<MAP_ANON>)."
-msgstr ""
-"上記のフラグの中では、 B<MAP_FIXED> だけが POSIX.1-2001 で規定されている。 し"
-"かしながら、ほとんどのシステムで B<MAP_ANONYMOUS> (またはその同義語である "
-"B<MAP_ANON>)  もサポートされている。"
+msgstr "上記のフラグの中では、 B<MAP_FIXED> だけが POSIX.1-2001 と POSIX.1-2008 で規定されている。 しかしながら、ほとんどのシステムで B<MAP_ANONYMOUS> (またはその同義語である B<MAP_ANON>)  もサポートされている。"
 
 #. type: SS
 #: build/C/man2/mmap.2:468
@@ -7575,32 +7085,18 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mmap.2:501
-#, fuzzy
-#| msgid ""
-#| "On success B<mremap>()  returns a pointer to the new virtual memory "
-#| "area.  On error, the value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>) is "
-#| "returned, and I<errno> is set appropriately."
 msgid ""
 "On success, B<mmap>()  returns a pointer to the mapped area.  On error, the "
 "value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>)  is returned, and I<errno> "
 "is set to indicate the cause of the error."
-msgstr ""
-"成功した場合は B<mremap>()  は新しい仮想メモリー領域へのポインターを返す。 エ"
-"ラーの場合は B<MAP_FAILED> (すなわち I<(void\\ *)\\ -1>) が返され、 I<errno> "
-"が適切に設定される。"
+msgstr "成功した場合は B<mremap>() はマッピングされた領域へのポインターを返す。 エラーの場合は B<MAP_FAILED> (すなわち I<(void\\ *)\\ -1>) が返され、 I<errno> にエラーの原因を示す値が設定される。"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:509
-#, fuzzy
-#| msgid ""
-#| "On success, B<shmdt>()  returns 0; on error -1 is returned, and I<errno> "
-#| "is set to indicate the cause of the error."
 msgid ""
 "On success, B<munmap>()  returns 0.  On failure, it returns -1, and I<errno> "
 "is set to indicate the cause of the error (probably to B<EINVAL>)."
-msgstr ""
-"B<shmdt>()  は、成功すると 0 を返す。 エラーの場合、-1 を返し、 I<errno> にエ"
-"ラーの原因を示す値を設定する。"
+msgstr "B<munmap>()  は、成功すると 0 を返す。 エラーの場合、-1 を返し、 I<errno> にエラーの原因を示す値を設定する (多くの場合 B<EINVAL> である)。"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:528
@@ -7663,16 +7159,10 @@ msgstr "(Linux 2.6.12 以降)  I<length> が 0 であった。"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:569
-#, fuzzy
-#| msgid ""
-#| "I<flags> contained neither B<MAP_PRIVATE> or B<MAP_SHARED>, or contained "
-#| "both of these values."
 msgid ""
 "I<flags> contained none of B<MAP_PRIVATE>, B<MAP_SHARED> or "
 "B<MAP_SHARED_VALIDATE>."
-msgstr ""
-"I<flags> に B<MAP_PRIVATE> と B<MAP_SHARED> のどちらも含まれていなかった、も"
-"しくは その両方が含まれていた。"
+msgstr "I<flags> に B<MAP_PRIVATE>, B<MAP_SHARED>, B<MAP_SHARED_VALIDATE> のいずれもが含まれていなかった。"
 
 #. type: TP
 #: build/C/man2/mmap.2:569 build/C/man3/shm_open.3:228
@@ -7788,21 +7278,20 @@ msgstr ""
 
 #. type: tbl table
 #: build/C/man2/mmap.2:654
-#, fuzzy, no-wrap
-#| msgid "B<mmap>(2), B<sysconf>(3)"
+#, no-wrap
 msgid ""
 "B<mmap>(),\n"
 "B<munmap>()"
-msgstr "B<mmap>(2), B<sysconf>(3)"
+msgstr ""
+"B<mmap>(),\n"
+"B<munmap>()"
 
 #.  SVr4 documents additional error codes ENXIO and ENODEV.
 #.  SUSv2 documents additional error codes EMFILE and EOVERFLOW.
 #. type: Plain text
 #: build/C/man2/mmap.2:660
-#, fuzzy
-#| msgid "POSIX.1-2001, SVr4."
 msgid "POSIX.1-2001, POSIX.1-2008, SVr4, 4.4BSD."
-msgstr "POSIX.1-2001, SVr4."
+msgstr "POSIX.1-2001, POSIX.1-2008, SVr4, 4.4BSD."
 
 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
 #.  -1: unavailable, 0: ask using sysconf().
@@ -8023,10 +7512,9 @@ msgstr ""
 
 #. type: SS
 #: build/C/man2/mmap.2:851 build/C/man2/posix_fadvise.2:189
-#, fuzzy, no-wrap
-#| msgid "C library/kernel ABI differences"
+#, no-wrap
 msgid "C library/kernel differences"
-msgstr "C ライブラリとカーネル ABI の違い"
+msgstr "C ライブラリとカーネルの違い"
 
 #.  Since around glibc 2.1/2.2, depending on the platform.
 #. type: Plain text
@@ -8048,11 +7536,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mmap.2:871
-#, fuzzy
-#| msgid ""
-#| "On Linux there are no guarantees like those suggested above under "
-#| "B<MAP_NORESERVE>.  By default, any process can be killed at any moment "
-#| "when the system runs out of memory."
 msgid ""
 "On Linux, there are no guarantees like those suggested above under "
 "B<MAP_NORESERVE>.  By default, any process can be killed at any moment when "
@@ -8086,18 +7569,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mmap.2:910
-#, fuzzy
-#| msgid ""
-#| "POSIX specifies that the system shall always zero fill any partial page "
-#| "at the end of the object and that system will never write any "
-#| "modification of the object beyond its end.  On Linux, when you write data "
-#| "to such partial page after the end of the object, the data stays in the "
-#| "page cache even after the file is closed and unmapped and even though the "
-#| "data is never written to the file itself, subsequent mappings may see the "
-#| "modified content.  In some cases, this could be fixed by calling "
-#| "B<msync>(2)  before the unmap takes place; however, this doesn't work on "
-#| "tmpfs (for example, when using POSIX shared memory interface documented "
-#| "in B<shm_overview>(7))."
 msgid ""
 "POSIX specifies that the system shall always zero fill any partial page at "
 "the end of the object and that system will never write any modification of "
@@ -8109,16 +7580,7 @@ msgid ""
 "the unmap takes place; however, this doesn't work on B<tmpfs>(5)  (for "
 "example, when using the POSIX shared memory interface documented in "
 "B<shm_overview>(7))."
-msgstr ""
-"POSIX では、 システムはオブジェクト末尾の部分ページを常に 0 で埋め、 末尾より"
-"後ろのオブジェクトを決して変更してはならない、と規定している。 Linux では、 "
-"オブジェクト末尾より後ろの部分ページにデータを書き込んだ場合、 そのファイルを"
-"クローズしてアンマップした後であってもページキャッシュにデータが残り続け、 "
-"データがファイル自体に書き込まれていなくても、 それ以降のマッピングで変更され"
-"た内容が見える可能性がある。 いくつかの場合では、 アンマップを行う前に "
-"B<msync>(2) を呼び出すことで、 この状況を修正することができる。 しかし、 これ"
-"は tmpfs では機能しない (例えば、 B<shm_overview>(7) で説明されている POSIX "
-"共有メモリーインターフェースを使った場合)。"
+msgstr "POSIX では、 システムはオブジェクト末尾の部分ページを常に 0 で埋め、 末尾より後ろのオブジェクトを決して変更してはならない、と規定している。 Linux では、 オブジェクト末尾より後ろの部分ページにデータを書き込んだ場合、 そのファイルをクローズしてアンマップした後であってもページキャッシュにデータが残り続け、 データがファイル自体に書き込まれていなくても、 それ以降のマッピングで変更された内容が見える可能性がある。 いくつかの場合では、 アンマップを行う前に B<msync>(2) を呼び出すことで、 この状況を修正することができる。 しかし、 これは B<tmpfs>(5) では機能しない (例えば、 B<shm_overview>(7) で説明されている POSIX 共有メモリーインターフェースを使った場合)。"
 
 #.  FIXME . Add an example here that uses an anonymous shared region for
 #.  IPC between parent and child.
@@ -8227,18 +7689,14 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mmap.2:958
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    offset = atoi(argv[2]);\n"
-#| "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
-#| "        /* offset for mmap() must be page aligned */\n"
+#, no-wrap
 msgid ""
 "    offset = atoi(argv[2]);\n"
 "    pa_offset = offset & \\(ti(sysconf(_SC_PAGE_SIZE) - 1);\n"
 "        /* offset for mmap() must be page aligned */\n"
 msgstr ""
 "    offset = atoi(argv[2]);\n"
-"    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
+"    pa_offset = offset & \\(ti(sysconf(_SC_PAGE_SIZE) - 1);\n"
 "        /* offset for mmap() must be page aligned */\n"
 
 #. type: Plain text
@@ -8330,25 +7788,17 @@ msgid ""
 "    munmap(addr, length + offset - pa_offset);\n"
 "    close(fd);\n"
 msgstr ""
+"    munmap(addr, length + offset - pa_offset);\n"
+"    close(fd);\n"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:1010
-#, fuzzy
-#| msgid ""
-#| "B<getpagesize>(2), B<memfd_create>(2), B<mincore>(2), B<mlock>(2), "
-#| "B<mmap2>(2), B<mprotect>(2), B<mremap>(2), B<msync>(2), "
-#| "B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>(2), B<shm_open>(3), "
-#| "B<shm_overview>(7)"
 msgid ""
 "B<ftruncate>(2), B<getpagesize>(2), B<memfd_create>(2), B<mincore>(2), "
 "B<mlock>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), B<msync>(2), "
 "B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>(2), B<userfaultfd>(2), "
 "B<shm_open>(3), B<shm_overview>(7)"
-msgstr ""
-"B<getpagesize>(2), B<memfd_create>(2), B<mincore>(2), B<mlock>(2), "
-"B<mmap2>(2), B<mprotect>(2), B<mremap>(2), B<msync>(2), "
-"B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>(2), B<shm_open>(3), "
-"B<shm_overview>(7)"
+msgstr "B<ftruncate>(2), B<getpagesize>(2), B<memfd_create>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>(2), B<userfaultfd>(2), B<shm_open>(3), B<shm_overview>(7)"
 
 #. type: Plain text
 #: build/C/man2/mmap.2:1017
@@ -8361,10 +7811,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mmap.2:1022 build/C/man2/msync.2:154
-#, fuzzy
-#| msgid "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
 msgid "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128\\(en129 and 389\\(en391."
-msgstr "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
+msgstr "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128\\(en129 and 389\\(en391."
 
 #. type: TH
 #: build/C/man2/mmap2.2:29
@@ -8498,10 +7946,8 @@ msgstr "MPROTECT"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:36
-#, fuzzy
-#| msgid "mprotect - set protection on a region of memory"
 msgid "mprotect, pkey_mprotect - set protection on a region of memory"
-msgstr "mprotect - メモリー領域の保護を設定する"
+msgstr "mprotect, pkey_mprotect - メモリー領域の保護を設定する"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:41
@@ -8511,32 +7957,22 @@ msgstr "B<int mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:44 build/C/man2/pkey_alloc.2:32
-#, fuzzy, no-wrap
-#| msgid ""
-#| "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
-#| "B<#include E<lt>sys/mman.hE<gt>>\n"
+#, no-wrap
 msgid ""
 "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
 "B<#include E<lt>sys/mman.hE<gt>>\n"
 msgstr ""
-"B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
+"B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
 "B<#include E<lt>sys/mman.hE<gt>>\n"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:46
-#, fuzzy, no-wrap
-#| msgid "B<int mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
+#, no-wrap
 msgid "B<int pkey_mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<, int >I<pkey>B<);>\n"
-msgstr "B<int mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
+msgstr "B<int pkey_mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<, int >I<pkey>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:54
-#, fuzzy
-#| msgid ""
-#| "B<mprotect>()  changes protection for the calling process's memory "
-#| "page(s)  containing any part of the address range in the interval "
-#| "[I<addr>,\\ I<addr>+I<len>-1].  I<addr> must be aligned to a page "
-#| "boundary."
 msgid ""
 "B<mprotect>()  changes the access protections for the calling process's "
 "memory pages containing any part of the address range in the interval "
@@ -8548,11 +7984,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:59
-#, fuzzy
-#| msgid ""
-#| "If the calling process tries to access memory in a manner that violates "
-#| "the protection, then the kernel generates a B<SIGSEGV> signal for the "
-#| "process."
 msgid ""
 "If the calling process tries to access memory in a manner that violates the "
 "protections, then the kernel generates a B<SIGSEGV> signal for the process."
@@ -8595,10 +8026,9 @@ msgstr "そのメモリーは実行可能である。"
 
 #. type: TP
 #: build/C/man2/mprotect.2:76
-#, fuzzy, no-wrap
-#| msgid "B<MAP_LOCKED> (since Linux 2.5.37)"
+#, no-wrap
 msgid "B<PROT_SEM> (since Linux 2.5.7)"
-msgstr "B<MAP_LOCKED> (Linux 2.5.37 以降)"
+msgstr "B<PROT_SEM> (Linux 2.5.7 以降)"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:85
@@ -8611,10 +8041,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/mprotect.2:85
-#, fuzzy, no-wrap
-#| msgid "B<MAP_STACK> (since Linux 2.6.27)"
+#, no-wrap
 msgid "B<PROT_SAO> (since Linux 2.6.26)"
-msgstr "B<MAP_STACK> (Linux 2.6.27 以降)"
+msgstr "B<PROT_SAO> (Linux 2.6.26 以降)"
 
 #.  commit aba46c5027cb59d98052231b36efcbbde9c77a1d
 #.  commit ef3d3246a0d06be622867d21af25f997aeeb105f
@@ -8640,10 +8069,9 @@ msgstr ""
 #.  And calc_vm_flag_bits converts only GROWSDOWN/DENYWRITE/LOCKED.
 #. type: TP
 #: build/C/man2/mprotect.2:98
-#, fuzzy, no-wrap
-#| msgid "B<PROT_READ>"
+#, no-wrap
 msgid "B<PROT_GROWSUP>"
-msgstr "B<PROT_READ>"
+msgstr "B<PROT_GROWSUP>"
 
 #.  The VMA is one that was marked with VM_GROWSUP by the kernel
 #.  when the stack was created. Note that (unlike VM_GROWSDOWN),
@@ -8659,10 +8087,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/mprotect.2:113
-#, fuzzy, no-wrap
-#| msgid "B<MAP_GROWSDOWN>"
+#, no-wrap
 msgid "B<PROT_GROWSDOWN>"
-msgstr "B<MAP_GROWSDOWN>"
+msgstr "B<PROT_GROWSDOWN>"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:120
@@ -8685,16 +8112,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:148
-#, fuzzy
-#| msgid ""
-#| "On success, B<mprotect>()  returns zero.  On error, -1 is returned, and "
-#| "I<errno> is set appropriately."
 msgid ""
 "On success, B<mprotect>()  and B<pkey_mprotect>()  return zero.  On error, "
 "these system calls return -1, and I<errno> is set appropriately."
-msgstr ""
-"成功した場合、 B<mprotect>()  は 0 を返す。エラーの場合は -1 が返り、 "
-"I<errno> が適切に設定される。"
+msgstr "成功した場合、 B<mprotect>() と B<pkey_mprotect>() は 0 を返す。エラーの場合、これらのシステムコールは -1 を返し、 I<errno> を適切に設定する。"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:158
@@ -8727,10 +8148,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:179
-#, fuzzy
-#| msgid "An invalid value was specified for I<advice>."
 msgid "Invalid flags specified in I<prot>."
-msgstr "無効な値が I<advice> に指定された。"
+msgstr "無効なフラグが I<prot> に指定された。"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:186
@@ -8771,47 +8190,28 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:215
-#, fuzzy
-#| msgid ""
-#| "The B<remap_file_pages>()  system call appeared in Linux 2.5.46; glibc "
-#| "support was added in version 2.3.3."
 msgid ""
 "B<pkey_mprotect>()  first appeared in Linux 4.9; library support was added "
 "in glibc 2.27."
-msgstr ""
-"B<remap_file_pages>()  システムコールは Linux 2.5.46 で登場した。 glibc での"
-"サポートは glibc バージョン 2.3.3 で追加された。"
+msgstr "B<pkey_mprotect>() は Linux 4.9 で登場した。 ライブラリでのサポートは glibc 2.27 で追加された。"
 
 #.  SVr4 defines an additional error
 #.  code EAGAIN. The SVr4 error conditions don't map neatly onto Linux's.
 #. type: Plain text
 #: build/C/man2/mprotect.2:225
-#, fuzzy
-#| msgid ""
-#| "SVr4, POSIX.1-2001.  POSIX says that the behavior of B<mprotect>()  is "
-#| "unspecified if it is applied to a region of memory that was not obtained "
-#| "via B<mmap>(2)."
 msgid ""
 "B<mprotect>(): POSIX.1-2001, POSIX.1-2008, SVr4.  POSIX says that the "
 "behavior of B<mprotect>()  is unspecified if it is applied to a region of "
 "memory that was not obtained via B<mmap>(2)."
-msgstr ""
-"SVr4, POSIX.1-2001.  POSIX では、 B<mmap>(2)  経由で獲得していないメモリー領"
-"域に対して B<mprotect>()  を行った場合の B<mprotect>()  の動作は未定義である"
-"とされている。"
+msgstr "B<mprotect>(): POSIX.1-2001, POSIX.1-2008, SVr4.  POSIX では、 B<mmap>(2)  経由で獲得していないメモリー領域に対して B<mprotect>()  を行った場合の B<mprotect>()  の動作は未定義であるとされている。"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:228
 msgid "B<pkey_mprotect>()  is a nonportable Linux extension."
-msgstr ""
+msgstr "B<pkey_mprotect>() は非標準の Linux による拡張である。"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:235
-#, fuzzy
-#| msgid ""
-#| "On Linux it is always permissible to call B<mprotect>()  on any address "
-#| "in a process's address space (except for the kernel vsyscall area).  In "
-#| "particular it can be used to change existing code mappings to be writable."
 msgid ""
 "On Linux, it is always permissible to call B<mprotect>()  on any address in "
 "a process's address space (except for the kernel vsyscall area).  In "
@@ -8847,22 +8247,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:263
-#, fuzzy
-#| msgid ""
-#| "POSIX.1-2001 says that an implementation may permit access other than "
-#| "that specified in I<prot>, but at a minimum can allow write access only "
-#| "if B<PROT_WRITE> has been set, and must not allow any access if "
-#| "B<PROT_NONE> has been set."
 msgid ""
 "POSIX.1 says that an implementation may permit access other than that "
 "specified in I<prot>, but at a minimum can allow write access only if "
 "B<PROT_WRITE> has been set, and must not allow any access if B<PROT_NONE> "
 "has been set."
-msgstr ""
-"POSIX.1-2001 では、 I<prot> で指定されていないアクセスを許可する実装を認めて"
-"いる。 ただし、最低限、 B<PROT_WRITE> がセットされている場合にのみ書き込みア"
-"クセスが許可され、 B<PROT_NONE> がセットされている場合にはアクセスは許可され"
-"ない点だけは 満たす必要がある。"
+msgstr "POSIX.1 では、 I<prot> で指定されていないアクセスを許可する実装を認めている。 ただし、最低限、 B<PROT_WRITE> がセットされている場合にのみ書き込みアクセスが許可され、 B<PROT_NONE> がセットされている場合にはアクセスは許可されない点だけは 満たす必要がある。"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:276
@@ -8885,20 +8275,12 @@ msgstr ""
 #.  sigaction.2 refers to this example
 #. type: Plain text
 #: build/C/man2/mprotect.2:293
-#, fuzzy
-#| msgid ""
-#| "The program below allocates four pages of memory, makes the third of "
-#| "these pages read-only, and then executes a loop that walks upward through "
-#| "the allocated region modifying bytes."
 msgid ""
 "The program below demonstrates the use of B<mprotect>().  The program "
 "allocates four pages of memory, makes the third of these pages read-only, "
 "and then executes a loop that walks upward through the allocated region "
 "modifying bytes."
-msgstr ""
-"以下のプログラムは、メモリーページを 4つ確保し、そのうち 3番目のページを 読み"
-"込み専用に設定する。その後で、確保した領域のアドレスの小さい方から 大きな方に"
-"向かって順番にバイト値を変更するループを実行する。"
+msgstr "以下のプログラムは、 B<mprotect>() の使用方法を示すものである。このプログラムは、メモリーページを 4つ確保し、そのうち 3番目のページを 読み込み専用に設定する。その後で、確保した領域のアドレスの小さい方から 大きな方に向かって順番にバイト値を変更するループを実行する。"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:296
@@ -8960,38 +8342,19 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:332
-#, fuzzy, no-wrap
-#| msgid ""
-#| "static void\n"
-#| "handler(int sig, siginfo_t *si, void *unused)\n"
-#| "{\n"
-#| "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
-#| "            (long) si-E<gt>si_addr);\n"
-#| "    exit(EXIT_FAILURE);\n"
-#| "}\n"
+#, no-wrap
 msgid ""
 "    printf(\"Got SIGSEGV at address: %p\\en\", si-E<gt>si_addr);\n"
 "    exit(EXIT_FAILURE);\n"
 "}\n"
 msgstr ""
-"static void\n"
-"handler(int sig, siginfo_t *si, void *unused)\n"
-"{\n"
-"    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
-"            (long) si-E<gt>si_addr);\n"
+"    printf(\"Got SIGSEGV at address: %p\\en\", si-E<gt>si_addr);\n"
 "    exit(EXIT_FAILURE);\n"
 "}\n"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:338
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "    char *p;\n"
-#| "    int pagesize;\n"
-#| "    struct sigaction sa;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -9000,9 +8363,8 @@ msgid ""
 "    struct sigaction sa;\n"
 msgstr ""
 "int\n"
-"main(void)\n"
+"main(int argc, char *argv[])\n"
 "{\n"
-"    char *p;\n"
 "    int pagesize;\n"
 "    struct sigaction sa;\n"
 
@@ -9058,10 +8420,9 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:357
-#, fuzzy, no-wrap
-#| msgid "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
+#, no-wrap
 msgid "    printf(\"Start of region:        %p\\en\", buffer);\n"
-msgstr "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
+msgstr "    printf(\"Start of region:        %p\\en\", buffer);\n"
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:361
@@ -9077,15 +8438,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:364
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (p = buffer ; ; )\n"
-#| "        *(p++) = \\(aqa\\(aq;\n"
+#, no-wrap
 msgid ""
 "    for (char *p = buffer ; ; )\n"
 "        *(p++) = \\(aqa\\(aq;\n"
 msgstr ""
-"    for (p = buffer ; ; )\n"
+"    for (char *p = buffer ; ; )\n"
 "        *(p++) = \\(aqa\\(aq;\n"
 
 #. type: Plain text
@@ -9102,10 +8460,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mprotect.2:373
-#, fuzzy
-#| msgid "B<mmap>(2), B<sysconf>(3)"
 msgid "B<mmap>(2), B<sysconf>(3), B<pkeys>(7)"
-msgstr "B<mmap>(2), B<sysconf>(3)"
+msgstr "B<mmap>(2), B<sysconf>(3), B<pkeys>(7)"
 
 #. type: TH
 #: build/C/man2/mremap.2:30
@@ -9181,9 +8537,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mremap.2:78
-#, fuzzy
-#| msgid ""
-#| "The I<flags> bit-mask argument may be 0, or include the following flag:"
 msgid ""
 "The I<flags> bit-mask argument may be 0, or include the following flags:"
 msgstr "I<flags> ビットマスク引数は 0 または以下のフラグを含む:"
@@ -9218,43 +8571,26 @@ msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:107
-#, fuzzy
-#| msgid ""
-#| "This flag serves a similar purpose to the B<MAP_FIXED> flag of "
-#| "B<mmap>(2).  If this flag is specified, then B<mremap>()  accepts a fifth "
-#| "argument, I<void\\ *new_address>, which specifies a page-aligned address "
-#| "to which the mapping must be moved.  Any previous mapping at the address "
-#| "range specified by I<new_address> and I<new_size> is unmapped.  If "
-#| "B<MREMAP_FIXED> is specified, then B<MREMAP_MAYMOVE> must also be "
-#| "specified."
 msgid ""
 "This flag serves a similar purpose to the B<MAP_FIXED> flag of B<mmap>(2).  "
 "If this flag is specified, then B<mremap>()  accepts a fifth argument, I<void"
 "\\ *new_address>, which specifies a page-aligned address to which the "
 "mapping must be moved.  Any previous mapping at the address range specified "
 "by I<new_address> and I<new_size> is unmapped."
-msgstr ""
-"このフラグは B<mmap>(2)  の B<MAP_FIXED> フラグと似たような目的で用いられ"
-"る。 このフラグが指定されると、 B<mremap>()  は 5 番目の引き数 I<void\\ "
-"*new_address> を受け取り、この引数はマッピングが移動されるべきアドレスを指定"
-"する。 このアドレスはページ境界に合っていなければならない。 I<new_address> "
-"と I<new_size> で指定されるアドレス範囲に過去のマッピングがあった場合、 その"
-"マッピングはアンマップされる (unmapped)。 B<MREMAP_FIXED> を指定した場合は、 "
-"B<MREMAP_MAYMOVE> も指定しなければならない。"
+msgstr "このフラグは B<mmap>(2)  の B<MAP_FIXED> フラグと似たような目的で用いられる。 このフラグが指定されると、 B<mremap>()  は 5 番目の引き数 I<void\\ *new_address> を受け取り、この引数はマッピングが移動されるべきアドレスを指定する。 このアドレスはページ境界に合っていなければならない。 I<new_address> と I<new_size> で指定されるアドレス範囲に過去のマッピングがあった場合、 そのマッピングはアンマップされる (unmapped)。"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:113
 msgid ""
 "If B<MREMAP_FIXED> is specified, then B<MREMAP_MAYMOVE> must also be "
 "specified."
-msgstr ""
+msgstr " B<MREMAP_FIXED> を指定した場合は、 B<MREMAP_MAYMOVE> も指定しなければならない。"
 
 #. type: TP
 #: build/C/man2/mremap.2:113
-#, fuzzy, no-wrap
-#| msgid "B<MADV_DONTDUMP> (since Linux 3.4)"
+#, no-wrap
 msgid "B<MREMAP_DONTUNMAP> (since Linux 5.7)"
-msgstr "B<MADV_DONTDUMP> (Linux 3.4 以降)"
+msgstr "B<MREMAP_DONTUNMAP> (Linux 5.7 以降)"
 
 #.  commit e346b3813067d4b17383f975f197a9aa28a3b077
 #. type: Plain text
@@ -9325,24 +8661,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mremap.2:184
-#, fuzzy
-#| msgid ""
-#| "\"Segmentation fault.\" Some address in the range I<old_address> to "
-#| "I<old_address>+I<old_size> is an invalid virtual memory address for this "
-#| "process.  You can also get B<EFAULT> even if there exist mappings that "
-#| "cover the whole address space requested, but those mappings are of "
-#| "different types."
 msgid ""
 "Some address in the range I<old_address> to I<old_address>+I<old_size> is an "
 "invalid virtual memory address for this process.  You can also get B<EFAULT> "
 "even if there exist mappings that cover the whole address space requested, "
 "but those mappings are of different types."
-msgstr ""
-"「セグメンテーション違反(segmentation fault)」 I<old_address> から "
-"I<old_address>+I<old_size> の 範囲のアドレスのどれかがこのプロセスにおいて不"
-"正な仮想メモリーアドレスである。 たとえ要求したアドレス空間全体を含むような"
-"マッピングがあったとしても、 それらのマッピングが異なった型ならば B<EFAULT> "
-"を受け取るだろう。"
+msgstr "I<old_address> から I<old_address>+I<old_size> の 範囲のアドレスのどれかがこのプロセスにおいて不正な仮想メモリーアドレスである。 たとえ要求したアドレス空間全体を含むようなマッピングがあったとしても、 それらのマッピングが異なった型ならば B<EFAULT> を受け取るだろう。"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:188
@@ -9351,10 +8675,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mremap.2:192
-#, fuzzy
-#| msgid "I<addr> is not page-aligned."
 msgid "I<old_address> was not page aligned;"
-msgstr "I<addr> がページ境界ではない。"
+msgstr "I<old_address> がページ境界ではない。"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:201
@@ -9365,10 +8687,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mremap.2:204
-#, fuzzy
-#| msgid "I<options> was nonzero."
 msgid "I<new_size> was zero;"
-msgstr "I<options> が 0 でなかった。"
+msgstr "I<new_size> が 0 であった。"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:209
@@ -9454,30 +8774,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mremap.2:273
-#, fuzzy
-#| msgid ""
-#| "B<mremap>()  uses the Linux page table scheme.  B<mremap>()  changes the "
-#| "mapping between virtual addresses and memory pages.  This can be used to "
-#| "implement a very efficient B<realloc>(3)."
 msgid ""
 "B<mremap>()  changes the mapping between virtual addresses and memory "
 "pages.  This can be used to implement a very efficient B<realloc>(3)."
-msgstr ""
-"B<mremap>()  は Linux のページテーブル方式を使用する。 B<mremap>()  は仮想ア"
-"ドレスとメモリーページのマッピングを変更する。これは非常に効率的な "
-"B<realloc>(3)  を実装するのに使用されている。"
+msgstr "B<mremap>()  は仮想アドレスとメモリーページのマッピングを変更する。これは非常に効率的な B<realloc>(3)  を実装するのに使用されている。"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:287
-#, fuzzy
-#| msgid ""
-#| "In Linux the memory is divided into pages.  A user process has (one or)  "
-#| "several linear virtual memory segments.  Each virtual memory segment has "
-#| "one or more mappings to real memory pages (in the page table).  Each "
-#| "virtual memory segment has its own protection (access rights), which may "
-#| "cause a segmentation violation if the memory is accessed incorrectly (e."
-#| "g., writing to a read-only segment).  Accessing virtual memory outside of "
-#| "the segments will also cause a segmentation violation."
 msgid ""
 "In Linux, memory is divided into pages.  A process has (one or)  several "
 "linear virtual memory segments.  Each virtual memory segment has one or more "
@@ -9486,15 +8789,7 @@ msgid ""
 "segmentation violation (B<SIGSEGV>)  if the memory is accessed incorrectly "
 "(e.g., writing to a read-only segment).  Accessing virtual memory outside of "
 "the segments will also cause a segmentation violation."
-msgstr ""
-"Linux ではメモリーはページに分割される。ユーザープロセスは (一つまたは)  複数"
-"のリニアな仮想メモリーセグメントを持つ。 それぞれの仮想メモリーセグメントは一"
-"つ以上の実メモリーページ にマッピングされている (マッピング情報はページテーブ"
-"ルで管理される)。 仮想メモリーセグメントにはセグメント毎の保護 (アクセス権) "
-"が設定されており、 メモリーが不正にアクセスされた場合 (例えば読み込み専用のセ"
-"グメントに 書き込んだ場合)、セグメンテーション侵害 (segmentation violation) "
-"を 引き起こす。また、セグメント外の仮想メモリーにアクセスした場合にも セグメ"
-"ンテーション侵害が発生する。"
+msgstr "Linux ではメモリーはページに分割される。プロセスは (一つまたは)  複数のリニアな仮想メモリーセグメントを持つ。 それぞれの仮想メモリーセグメントは一つ以上の実メモリーページ にマッピングされている (マッピング情報はページテーブルで管理される)。 仮想メモリーセグメントにはセグメント毎の保護 (アクセス権) が設定されており、 メモリーが不正にアクセスされた場合 (例えば読み込み専用のセグメントに 書き込んだ場合)、セグメンテーション侵害 (segmentation violation; B<SIGSEGV>) を引き起こす。また、セグメント外の仮想メモリーにアクセスした場合にも セグメンテーション侵害が発生する。"
 
 #. type: Plain text
 #: build/C/man2/mremap.2:298
@@ -9569,22 +8864,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/mremap.2:369
-#, fuzzy
-#| msgid ""
-#| "Your favorite text book on operating systems for more information on "
-#| "paged memory (e.g., I<Modern Operating Systems> by Andrew S. Tanenbaum, "
-#| "I<Inside Linux> by Randolf Bentson, I<The Design of the UNIX Operating "
-#| "System> by Maurice J. Bach)"
 msgid ""
 "Your favorite text book on operating systems for more information on paged "
 "memory (e.g., I<Modern Operating Systems> by Andrew S.\\& Tanenbaum, "
 "I<Inside Linux> by Randolph Bentson, I<The Design of the UNIX Operating "
 "System> by Maurice J.\\& Bach)"
-msgstr ""
-"ページ分割されたメモリーについてもっと詳しく知りたいならば、あなたのお気に入"
-"りのオペレーティングシステムの教科書を参照してほしい (例えば、 I<Modern "
-"Operating Systems> by Andrew S. Tanenbaum, I<Inside Linux> by Randolf "
-"Bentson, I<The Design of the UNIX Operating System> by Maurice J. Bach.)"
+msgstr "ページ分割されたメモリーについてもっと詳しく知りたいならば、あなたのお気に入りのオペレーティングシステムの教科書を参照してほしい (例えば、 I<Modern Operating Systems> by Andrew S.\\& Tanenbaum, I<Inside Linux> by Randolf Bentson, I<The Design of the UNIX Operating System> by Maurice J.\\& Bach.)"
 
 #. type: TH
 #: build/C/man2/msync.2:25
@@ -9604,14 +8889,6 @@ msgstr "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
 
 #. type: Plain text
 #: build/C/man2/msync.2:48
-#, fuzzy
-#| msgid ""
-#| "B<msync>()  flushes changes made to the in-core copy of a file that was "
-#| "mapped into memory using B<mmap>(2)  back to the filesystem.  Without use "
-#| "of this call there is no guarantee that changes are written back before "
-#| "B<munmap>(2)  is called.  To be more precise, the part of the file that "
-#| "corresponds to the memory area starting at I<addr> and having length "
-#| "I<length> is updated."
 msgid ""
 "B<msync>()  flushes changes made to the in-core copy of a file that was "
 "mapped into memory using B<mmap>(2)  back to the filesystem.  Without use of "
@@ -9636,10 +8913,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/msync.2:59
-#, fuzzy, no-wrap
-#| msgid "MSYNC"
+#, no-wrap
 msgid "B<MS_ASYNC>"
-msgstr "MSYNC"
+msgstr "B<MS_ASYNC>"
 
 #. type: Plain text
 #: build/C/man2/msync.2:62
@@ -9649,10 +8925,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/msync.2:62
-#, fuzzy, no-wrap
-#| msgid "MSYNC"
+#, no-wrap
 msgid "B<MS_SYNC>"
-msgstr "MSYNC"
+msgstr "B<MS_SYNC>"
 
 #. type: Plain text
 #: build/C/man2/msync.2:65
@@ -9661,10 +8936,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/msync.2:65
-#, fuzzy, no-wrap
-#| msgid "B<MAP_PRIVATE>"
+#, no-wrap
 msgid "B<MS_INVALIDATE>"
-msgstr "B<MAP_PRIVATE>"
+msgstr "B<MS_INVALIDATE>"
 
 #.  Since Linux 2.4, this seems to be a no-op (other than the
 #.  EBUSY check for VM_LOCKED).
@@ -9717,10 +8991,8 @@ msgstr "指定されたメモリー (またはその一部) がマップされ
 
 #. type: Plain text
 #: build/C/man2/msync.2:101 build/C/man3/shm_open.3:265
-#, fuzzy
-#| msgid "POSIX.1-2001, SVr4."
 msgid "POSIX.1-2001, POSIX.1-2008."
-msgstr "POSIX.1-2001, SVr4."
+msgstr "POSIX.1-2001, POSIX.1-2008."
 
 #. type: Plain text
 #: build/C/man2/msync.2:108
@@ -9846,6 +9118,8 @@ msgid ""
 "B<mtrace>(),\n"
 "B<muntrace>()"
 msgstr ""
+"B<mtrace>(),\n"
+"B<muntrace>()"
 
 #. type: tbl table
 #: build/C/man3/mtrace.3:89
@@ -9910,12 +9184,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/mtrace.3:149
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "    int j;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -9925,19 +9194,16 @@ msgstr ""
 "int\n"
 "main(int argc, char *argv[])\n"
 "{\n"
-"    int j;\n"
+"    mtrace();\n"
 
 #. type: Plain text
 #: build/C/man3/mtrace.3:152
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    for (j = 0; j E<lt> 2; j++)\n"
-#| "        malloc(100);            /* Never freed--a memory leak */\n"
+#, no-wrap
 msgid ""
 "    for (int j = 0; j E<lt> 2; j++)\n"
 "        malloc(100);            /* Never freed--a memory leak */\n"
 msgstr ""
-"    for (j = 0; j E<lt> 2; j++)\n"
+"    for (int j = 0; j E<lt> 2; j++)\n"
 "        malloc(100);            /* Never freed--a memory leak */\n"
 
 #. type: Plain text
@@ -10028,10 +9294,8 @@ msgstr "B<posix_fadvise>():"
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:49 build/C/man3/posix_fallocate.3:44
-#, fuzzy
-#| msgid "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
 msgid "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
-msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
+msgstr "_POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:57
@@ -10181,12 +9445,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:115
-#, fuzzy
-#| msgid ""
-#| "Requests to discard partial pages are ignored.  It is preferable to "
-#| "preserve needed data than discard unneeded data.  If the application "
-#| "requires that data be considered for discarding then I<offset> and I<len> "
-#| "must be page-aligned."
 msgid ""
 "Requests to discard partial pages are ignored.  It is preferable to preserve "
 "needed data than discard unneeded data.  If the application requires that "
@@ -10232,19 +9490,11 @@ msgstr "無効な値が I<advice> に指定された。"
 #.  commit 87ba81dba431232548ce29d5d224115d0c2355ac
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:147
-#, fuzzy
-#| msgid ""
-#| "The specified file descriptor refers to a pipe or FIFO.  (B<ESPIPE> is "
-#| "the error specified by POSIX, but before kernel version 2.16, Linux "
-#| "returned B<EINVAL> in this case.)"
 msgid ""
 "The specified file descriptor refers to a pipe or FIFO.  (B<ESPIPE> is the "
 "error specified by POSIX, but before kernel version 2.6.16, Linux returned "
 "B<EINVAL> in this case.)"
-msgstr ""
-"指定されたファイルディスクリプターがパイプまたは FIFO を参照している "
-"(B<ESPIPE> は POSIX で規定されているエラーだが、 バージョン 2.16 より前のカー"
-"ネルでは、 この場合に B<EINVAL> を返していた。)"
+msgstr "指定されたファイルディスクリプターがパイプまたは FIFO を参照している (B<ESPIPE> は POSIX で規定されているエラーだが、 バージョン 2.6.16 より前のカーネルでは、 この場合に B<EINVAL> を返していた。)"
 
 #.  of fadvise64_64()
 #. type: Plain text
@@ -10273,16 +9523,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:171
-#, fuzzy
-#| msgid ""
-#| "POSIX.1-2001.  Note that the type of the I<len> argument was changed from "
-#| "I<size_t> to I<off_t> in POSIX.1-2003 TC1."
 msgid ""
 "POSIX.1-2001, POSIX.1-2008.  Note that the type of the I<len> argument was "
 "changed from I<size_t> to I<off_t> in POSIX.1-2001 TC1."
-msgstr ""
-"POSIX.1-2001.  I<len> 引き数の型が POSIX.1-2003 TC1 において I<size_t> から "
-"I<off_t> に変更された点に注意すること。"
+msgstr "POSIX.1-2001, POSIX.1-2008.  I<len> 引き数の型が POSIX.1-2001 TC1 において I<size_t> から I<off_t> に変更された点に注意すること。"
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:177
@@ -10326,15 +9570,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:216
-#, fuzzy
-#| msgid ""
-#| "Some architectures require 64-bit arguments to be aligned in a suitable "
-#| "pair of registers (see B<syscall>(2)  for further detail).  On such "
-#| "architectures, the call signature of B<posix_fadvise>()  shown in the "
-#| "SYNOPSIS would force a register to be wasted as padding between the I<fd> "
-#| "and I<offset> arguments.  Therefore, these architectures define a version "
-#| "of the system call that orders the arguments suitably, but otherwise is "
-#| "otherwise exactly the same as B<posix_fadvise>()."
 msgid ""
 "Some architectures require 64-bit arguments to be aligned in a suitable pair "
 "of registers (see B<syscall>(2)  for further detail).  On such "
@@ -10392,16 +9627,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/posix_fadvise.2:243
-#, fuzzy
-#| msgid ""
-#| "B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3), "
-#| "B<posix_madvise>(3)"
 msgid ""
 "B<fincore>(1), B<mincore>(2), B<readahead>(2), B<sync_file_range>(2), "
 "B<posix_fallocate>(3), B<posix_madvise>(3)"
-msgstr ""
-"B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3),\n"
-"B<posix_madvise>(3)"
+msgstr "B<fincore>(1), B<mincore>(2), B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3), B<posix_madvise>(3)"
 
 #. type: TH
 #: build/C/man3/posix_fallocate.3:25
@@ -10427,26 +9656,13 @@ msgstr "B<posix_fallocate>():"
 
 #. type: Plain text
 #: build/C/man3/posix_fallocate.3:61
-#, fuzzy
-#| msgid ""
-#| "The function B<posix_fallocate>()  ensures that disk space is allocated "
-#| "for the file referred to by the descriptor I<fd> for the bytes in the "
-#| "range starting at I<offset> and continuing for I<len> bytes.  After a "
-#| "successful call to B<posix_fallocate>(), subsequent writes to bytes in "
-#| "the specified range are guaranteed not to fail because of lack of disk "
-#| "space."
 msgid ""
 "The function B<posix_fallocate>()  ensures that disk space is allocated for "
 "the file referred to by the file descriptor I<fd> for the bytes in the range "
 "starting at I<offset> and continuing for I<len> bytes.  After a successful "
 "call to B<posix_fallocate>(), subsequent writes to bytes in the specified "
 "range are guaranteed not to fail because of lack of disk space."
-msgstr ""
-"関数 B<posix_fallocate>()  は、ディスクリプター I<fd> で参照されるファイルに"
-"対して、ディスクスペースを確実に確保する。 ディスクスペースは I<offset> から"
-"始まる I<len> バイトの範囲のバイトである。 B<posix_fallocate>()  の呼び出しが"
-"成功した後、指定された範囲のバイトに対する書き込みは、 ディスクスペースの不足"
-"で失敗しないことが保証される。"
+msgstr "関数 B<posix_fallocate>()  は、ファイルディスクリプター I<fd> で参照されるファイルに対して、ディスクスペースを確実に確保する。 ディスクスペースは I<offset> から始まる I<len> バイトの範囲のバイトである。 B<posix_fallocate>()  の呼び出しが成功した後、指定された範囲のバイトに対する書き込みは、 ディスクスペースの不足で失敗しないことが保証される。"
 
 #. type: Plain text
 #: build/C/man3/posix_fallocate.3:66
@@ -10601,38 +9817,30 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 
 #. type: TH
 #: build/C/man3/posix_madvise.3:20
-#, fuzzy, no-wrap
-#| msgid "POSIX_FADVISE"
+#, no-wrap
 msgid "POSIX_MADVISE"
-msgstr "POSIX_FADVISE"
+msgstr "POSIX_MADVISE"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:23
-#, fuzzy
-#| msgid "madvise - give advice about use of memory"
 msgid "posix_madvise - give advice about patterns of memory usage"
-msgstr "madvise - メモリー利用に関するアドバイスを与える"
+msgstr ""
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:28
-#, fuzzy, no-wrap
-#| msgid "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
+#, no-wrap
 msgid "B<int posix_madvise(void *>I<addr>B<, size_t >I<len>B<, int >I<advice>B<);>\n"
-msgstr "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
+msgstr "B<int posix_madvise(void *>I<addr>B<, size_t >I<len>B<, int >I<advice>B<);>\n"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:36
-#, fuzzy
-#| msgid "B<posix_fadvise>():"
 msgid "B<posix_madvise>():"
-msgstr "B<posix_fadvise>():"
+msgstr "B<posix_madvise>():"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:40
-#, fuzzy
-#| msgid "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
 msgid "_POSIX_C_SOURCE E<gt>= 200112L"
-msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
+msgstr "_POSIX_C_SOURCE E<gt>= 200112L"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:55
@@ -10647,40 +9855,27 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:59
-#, fuzzy
-#| msgid ""
-#| "The I<flags> bit-mask argument can include any of the following values:"
 msgid "The I<advice> argument is one of the following:"
-msgstr "ビットマスク引き数 I<flags> には以下の値を指定することができる:"
+msgstr ""
 
 #. type: TP
 #: build/C/man3/posix_madvise.3:59
-#, fuzzy, no-wrap
-#| msgid "B<POSIX_FADV_NORMAL>"
+#, no-wrap
 msgid "B<POSIX_MADV_NORMAL>"
-msgstr "B<POSIX_FADV_NORMAL>"
+msgstr "B<POSIX_MADV_NORMAL>"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:64
-#, fuzzy
-#| msgid ""
-#| "Indicates that the application has no advice to give about its access "
-#| "pattern for the specified data.  If no advice is given for an open file, "
-#| "this is the default assumption."
 msgid ""
 "The application has no special advice regarding its memory usage patterns "
 "for the specified address range.  This is the default behavior."
 msgstr ""
-"指定されたデータのアクセスパターンを指示するアドバイスを アプリケーションが何"
-"も持っていないことを示す。 オープンされたファイルにアドバイスが指定されない場"
-"合、 これがデフォルトで仮定される。"
 
 #. type: TP
 #: build/C/man3/posix_madvise.3:64
-#, fuzzy, no-wrap
-#| msgid "B<POSIX_FADV_SEQUENTIAL>"
+#, no-wrap
 msgid "B<POSIX_MADV_SEQUENTIAL>"
-msgstr "B<POSIX_FADV_SEQUENTIAL>"
+msgstr "B<POSIX_MADV_SEQUENTIAL>"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:70
@@ -10701,10 +9896,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man3/posix_madvise.3:70
-#, fuzzy, no-wrap
-#| msgid "B<POSIX_FADV_RANDOM>"
+#, no-wrap
 msgid "B<POSIX_MADV_RANDOM>"
-msgstr "B<POSIX_FADV_RANDOM>"
+msgstr "B<POSIX_MADV_RANDOM>"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:74
@@ -10721,10 +9915,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man3/posix_madvise.3:74
-#, fuzzy, no-wrap
-#| msgid "B<POSIX_FADV_WILLNEED>"
+#, no-wrap
 msgid "B<POSIX_MADV_WILLNEED>"
-msgstr "B<POSIX_FADV_WILLNEED>"
+msgstr "B<POSIX_MADV_WILLNEED>"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:79
@@ -10741,10 +9934,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man3/posix_madvise.3:79
-#, fuzzy, no-wrap
-#| msgid "B<POSIX_FADV_DONTNEED>"
+#, no-wrap
 msgid "B<POSIX_MADV_DONTNEED>"
-msgstr "B<POSIX_FADV_DONTNEED>"
+msgstr "B<POSIX_MADV_DONTNEED>"
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:83
@@ -10821,10 +10013,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/posix_madvise.3:129
-#, fuzzy
-#| msgid "B<posix_fadvise>():"
 msgid "B<madvise>(2), B<posix_fadvise>(2)"
-msgstr "B<posix_fadvise>():"
+msgstr "B<madvise>(2), B<posix_fadvise>(2)"
 
 #. type: TH
 #: build/C/man3/posix_memalign.3:29
@@ -10871,14 +10061,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:54
-#, fuzzy
-#| msgid ""
-#| "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE"
-#| "\\ E<gt>=\\ 600"
 msgid "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
-msgstr ""
-"B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
-"E<gt>=\\ 600"
+msgstr "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:57
@@ -10904,6 +10088,9 @@ msgid ""
 "    || /* Glibc since 2.19: */ _DEFAULT_SOURCE\n"
 "    || /* Glibc versions E<lt>= 2.19: */ _SVID_SOURCE || _BSD_SOURCE\n"
 msgstr ""
+"(_XOPEN_SOURCE\\ E<gt>=\\ 500) && !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L)\n"
+"    || /* glibc 2.19 以降: */ _DEFAULT_SOURCE\n"
+"    || /* glibc 2.19 以前: */ _SVID_SOURCE || _BSD_SOURCE\n"
 
 #. type: TP
 #: build/C/man3/posix_memalign.3:70
@@ -10914,14 +10101,8 @@ msgstr "glibc 2.12 より前:"
 #.     || _XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTENDED
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:74
-#, fuzzy
-#| msgid ""
-#| "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
-#| "_XOPEN_SOURCE_EXTENDED"
 msgid "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500"
-msgstr ""
-"_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
-"_XOPEN_SOURCE_EXTENDED"
+msgstr "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:81
@@ -11059,16 +10240,10 @@ msgstr "割り当て要求を満たすのに十分なメモリーがなかった
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:182
-#, fuzzy
-#| msgid ""
-#| "The functions B<memalign>(), B<valloc>(), and B<pvalloc>()  have been "
-#| "available in all Linux libc libraries."
 msgid ""
 "The functions B<memalign>(), B<valloc>(), and B<pvalloc>()  have been "
 "available since at least glibc 2.0."
-msgstr ""
-"関数 B<memalign>(), B<valloc>(), B<pvalloc>() は\n"
-"すべての Linux libc ライブラリで使用可能である。"
+msgstr "関数 B<memalign>(), B<valloc>(), B<pvalloc>() は少なくとも glibc 2.0 以降で使用可能である。"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:186
@@ -11118,18 +10293,10 @@ msgstr "MT-Unsafe init"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:219
-#, fuzzy
-#| msgid ""
-#| "The function B<valloc>()  appeared in 3.0BSD.  It is documented as being "
-#| "obsolete in 4.3BSD, and as legacy in SUSv2.  It does not appear in "
-#| "POSIX.1-2001."
 msgid ""
 "The function B<valloc>()  appeared in 3.0BSD.  It is documented as being "
 "obsolete in 4.3BSD, and as legacy in SUSv2.  It does not appear in POSIX.1."
-msgstr ""
-"関数 B<valloc>() は 3.0BSD で登場した。4.3BSD では廃止されたと記載されてお"
-"り、\n"
-"SUSv2 では過去の名残だと記載されている。 POSIX.1-2001 には存在しない。"
+msgstr "関数 B<valloc>() は 3.0BSD で登場した。4.3BSD では廃止されたと記載されており、 SUSv2 では過去の名残だと記載されている。 POSIX.1 には存在しない。"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:223
@@ -11143,12 +10310,10 @@ msgstr "関数 B<memalign>() は SunOS 4.1.3 で登場したが、4.4BSD には
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:231
-#, fuzzy
-#| msgid "The function B<posix_memalign>()  comes from POSIX.1d."
 msgid ""
 "The function B<posix_memalign>()  comes from POSIX.1d and is specified in "
 "POSIX.1-2001 and POSIX.1-2008."
-msgstr "é\96¢æ\95° B<posix_memalign>() ã\81¯ POSIX.1d ã\81«ç\94±æ\9d¥ã\81\99る。"
+msgstr "é\96¢æ\95° B<posix_memalign>() ã\81¯ POSIX.1d ã\81«ç\94±æ\9d¥ã\81\97ã\80\81 POSIX.1-2001 ã\81¨ POSIX.1-2008 ã\81§è¦\8få®\9aã\81\95ã\82\8cã\81¦ã\81\84る。"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:236
@@ -11182,21 +10347,11 @@ msgstr ""
 #.  Libc4,5 and
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:252
-#, fuzzy
-#| msgid ""
-#| "According to SUSv2, B<valloc>()  is declared in I<E<lt>stdlib.hE<gt>>.  "
-#| "Libc4,5 and glibc declare it in I<E<lt>malloc.hE<gt>>, and also in "
-#| "I<E<lt>stdlib.hE<gt>> if suitable feature test macros are defined (see "
-#| "above)."
 msgid ""
 "According to SUSv2, B<valloc>()  is declared in I<E<lt>stdlib.hE<gt>>.  "
 "Glibc declares it in I<E<lt>malloc.hE<gt>>, and also in I<E<lt>stdlib."
 "hE<gt>> if suitable feature test macros are defined (see above)."
-msgstr ""
-"SUSv2 によると、 B<valloc>() は I<E<lt>stdlib.hE<gt>> で宣言される。 "
-"libc4,5\n"
-"や glibc では I<E<lt>malloc.hE<gt>> で宣言されており、 さらに適切な機能検査\n"
-"マクロが定義された場合には I<E<lt>stdlib.hE<gt>> でも宣言される(上記を参照)。"
+msgstr "SUSv2 によると、 B<valloc>() は I<E<lt>stdlib.hE<gt>> で宣言される。 glibc では I<E<lt>malloc.hE<gt>> で宣言されており、 さらに適切な機能検査マクロが定義された場合には I<E<lt>stdlib.hE<gt>> でも宣言される(上記を参照)。"
 
 #. type: Plain text
 #: build/C/man3/posix_memalign.3:261
@@ -11298,16 +10453,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/readahead.2:66
-#, fuzzy
-#| msgid ""
-#| "The I<fd> argument is a file descriptor identifying the file which is to "
-#| "be read.  The I<offset> argument specifies the starting point from which "
-#| "data is to be read and I<count> specifies the number of bytes to be "
-#| "read.  I/O is performed in whole pages, so that I<offset> is effectively "
-#| "rounded down to a page boundary and bytes are read up to the next page "
-#| "boundary greater than or equal to I<(offset+count)>.  B<readahead>()  "
-#| "does not read beyond the end of the file.  The current file offset of the "
-#| "open file referred to by I<fd> is left unchanged."
 msgid ""
 "The I<fd> argument is a file descriptor identifying the file which is to be "
 "read.  The I<offset> argument specifies the starting point from which data "
@@ -11317,14 +10462,7 @@ msgid ""
 "or equal to I<(offset+count)>.  B<readahead>()  does not read beyond the end "
 "of the file.  The file offset of the open file description referred to by "
 "the file descriptor I<fd> is left unchanged."
-msgstr ""
-"I<fd> 引き数は読み込みを行うファイルを識別するファイルディスクリプターであ"
-"る。 I<offset> 引き数はデータの読み込み開始位置を指定し、 I<count> は読み込む"
-"データのバイト数を指定する。 ディスク I/O はページ単位で実行されるので、 実際"
-"には I<offset> はページ境界に切り下げられ、読み込みバイト数は I<(offset"
-"+count)> より小さくない次のページ境界まで切り上げられる。 B<readahead>()  は"
-"ファイルの末尾を越えた範囲まで読み出しを行うことはない。 I<fd> で参照された"
-"オープン済のファイルのファイルオフセットの現在値は 変更されない。"
+msgstr "I<fd> 引き数は読み込みを行うファイルを識別するファイルディスクリプターである。 I<offset> 引き数はデータの読み込み開始位置を指定し、 I<count> は読み込むデータのバイト数を指定する。 ディスク I/O はページ単位で実行されるので、 実際には I<offset> はページ境界に切り下げられ、読み込みバイト数は I<(offset+count)> より小さくない次のページ境界まで切り上げられる。 B<readahead>()  はファイルの末尾を越えた範囲まで読み出しを行うことはない。ファイルディスクリプター I<fd> で参照されたオープン済のファイル記述のファイルオフセットは 変更されない。"
 
 #. type: Plain text
 #: build/C/man2/readahead.2:72
@@ -11586,25 +10724,13 @@ msgstr "B<remap_file_pages>()  システムコールは Linux 固有のもので
 #.  commit 3ee6dafc677a68e461a7ddafc94a580ebab80735
 #. type: Plain text
 #: build/C/man2/remap_file_pages.2:184
-#, fuzzy
-#| msgid ""
-#| "Since Linux 2.6.23, B<remap_file_pages>()  creates non-linear mappings "
-#| "only on in-memory file systems such as tmpfs, hugetlbfs or ramfs.  On "
-#| "filesystems with a backing store, B<remap_file_pages>()  is not much more "
-#| "efficient than using B<mmap>(2)  to adjust which parts of the file are "
-#| "mapped to which addresses."
 msgid ""
 "Since Linux 2.6.23, B<remap_file_pages>()  creates non-linear mappings only "
 "on in-memory filesystems such as B<tmpfs>(5), hugetlbfs or ramfs.  On "
 "filesystems with a backing store, B<remap_file_pages>()  is not much more "
 "efficient than using B<mmap>(2)  to adjust which parts of the file are "
 "mapped to which addresses."
-msgstr ""
-"Linux 2.6.23 以降、 B<remap_file_pages>() は tmpfs, hugetlbfs, ramfs などのイ"
-"ンメモリーファイルシステム上にのみ非線形マッピングを作成する。 裏にデータスト"
-"アを持つファイルシステム上では、 B<remap_file_pages>() は、 ファイルのどの部"
-"分がどのアドレスにマッピングされているかの調整が、 B<mmap>(2) を使った場合ほ"
-"ど効率的ではない。"
+msgstr "Linux 2.6.23 以降、 B<remap_file_pages>() は B<tmpfs>(5), hugetlbfs, ramfs などのインメモリーファイルシステム上にのみ非線形マッピングを作成する。 裏にデータストアを持つファイルシステム上では、 B<remap_file_pages>() は、 ファイルのどの部分がどのアドレスにマッピングされているかの調整が、 B<mmap>(2) を使った場合ほど効率的ではない。"
 
 #. type: Plain text
 #: build/C/man2/remap_file_pages.2:191
@@ -11838,15 +10964,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:170
-#, fuzzy
-#| msgid ""
-#| "The operation of B<shm_unlink>()  is analogous to B<unlink>(2): it "
-#| "removes a shared memory object name, and, once all processes have "
-#| "unmapped the object, de-allocates and destroys the contents of the "
-#| "associated memory region.  After a successful B<shm_unlink>(), attempts "
-#| "to B<shm_open>()  an object with the same I<name> will fail (unless "
-#| "B<O_CREAT> was specified, in which case a new, distinct object is "
-#| "created)."
 msgid ""
 "The operation of B<shm_unlink>()  is analogous to B<unlink>(2): it removes a "
 "shared memory object name, and, once all processes have unmapped the object, "
@@ -11864,19 +10981,11 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:179
-#, fuzzy
-#| msgid ""
-#| "On success, B<shm_open>()  returns a nonnegative file descriptor.  On "
-#| "failure, B<shm_open>()  returns -1.  B<shm_unlink>()  returns 0 on "
-#| "success, or -1 on error."
 msgid ""
 "On success, B<shm_open>()  returns a file descriptor (a nonnegative "
 "integer).  On failure, B<shm_open>()  returns -1.  B<shm_unlink>()  returns "
 "0 on success, or -1 on error."
-msgstr ""
-"成功した場合、 B<shm_open>()  は非負のファイルディスクリプターを返す。 失敗し"
-"た場合、 B<shm_open>()  は -1 を返す。 B<shm_unlink>()  は、成功した場合 0 "
-"を、エラーが起こった場合 -1 を返す。"
+msgstr "成功した場合、 B<shm_open>()  はファイルディスクリプター (非負の整数) を返す。 失敗した場合、 B<shm_open>()  は -1 を返す。 B<shm_unlink>()  は、成功した場合 0 を、エラーが起こった場合 -1 を返す。"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:186
@@ -11925,13 +11034,10 @@ msgstr "B<EMFILE>"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:222 build/C/man2/memfd_create.2:193
-#, fuzzy
-#| msgid "The per-process limit on open file descriptors has been reached."
 msgid ""
 "The per-process limit on the number of open file descriptors has been "
 "reached."
-msgstr ""
-"オープンされているファイルディスクリプターのプロセス単位の上限に達した。"
+msgstr "オープンされているファイルディスクリプター数のプロセス単位の上限に達した。"
 
 #. type: TP
 #: build/C/man3/shm_open.3:222
@@ -11973,12 +11079,13 @@ msgstr "これらの関数は glibc 2.2 以降で提供されている。"
 
 #. type: tbl table
 #: build/C/man3/shm_open.3:260
-#, fuzzy, no-wrap
-#| msgid "B<shm_unlink>(3)"
+#, no-wrap
 msgid ""
 "B<shm_open>(),\n"
 "B<shm_unlink>()"
-msgstr "B<shm_unlink>(3)"
+msgstr ""
+"B<shm_open>(),\n"
+"B<shm_unlink>()"
 
 #. type: tbl table
 #: build/C/man3/shm_open.3:260
@@ -12017,16 +11124,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:287
-#, fuzzy
-#| msgid ""
-#| "The POSIX shared memory object implementation on Linux 2.4 makes use of a "
-#| "dedicated filesystem, which is normally mounted under I</dev/shm>."
 msgid ""
 "The POSIX shared memory object implementation on Linux makes use of a "
 "dedicated B<tmpfs>(5)  filesystem that is normally mounted under I</dev/shm>."
-msgstr ""
-"Linux 2.4 における POSIX 共有メモリーオブジェクトの実装は 専用のファイルシス"
-"テムを使用する。そのファイルシステムは通常 I</dev/shm> にマウントされる。"
+msgstr "Linux における POSIX 共有メモリーオブジェクトの実装は専用の B<tmpfs>(5) ファイルシステムを使用する。そのファイルシステムは通常 I</dev/shm> にマウントされる。"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:295
@@ -12048,6 +11149,10 @@ msgid ""
 "$ B<./pshm_ucase_send /myshm hello>\n"
 "HELLO\n"
 msgstr ""
+"$ B<./pshm_ucase_bounce /myshm &>\n"
+"[1] 270171\n"
+"$ B<./pshm_ucase_send /myshm hello>\n"
+"HELLO\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:307
@@ -12056,10 +11161,9 @@ msgstr ""
 
 #. type: SS
 #: build/C/man3/shm_open.3:307
-#, fuzzy, no-wrap
-#| msgid "Program source: t_memfd_create.c"
+#, no-wrap
 msgid "Program source: pshm_ucase.h"
-msgstr "プログラムのソース: t_memfd_create.c"
+msgstr "プログラムのソース: pshm_ucase.h"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:311
@@ -12071,14 +11175,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:321
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>sys/mman.hE<gt>\n"
-#| "#include E<lt>sys/stat.hE<gt>\n"
-#| "#include E<lt>fcntl.hE<gt>\n"
-#| "#include E<lt>stdio.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
-#| "#include E<lt>unistd.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#include E<lt>sys/mman.hE<gt>\n"
 "#include E<lt>fcntl.hE<gt>\n"
@@ -12089,8 +11186,9 @@ msgid ""
 "#include E<lt>unistd.hE<gt>\n"
 msgstr ""
 "#include E<lt>sys/mman.hE<gt>\n"
-"#include E<lt>sys/stat.hE<gt>\n"
 "#include E<lt>fcntl.hE<gt>\n"
+"#include E<lt>semaphore.hE<gt>\n"
+"#include E<lt>sys/stat.hE<gt>\n"
 "#include E<lt>stdio.hE<gt>\n"
 "#include E<lt>stdlib.hE<gt>\n"
 "#include E<lt>unistd.hE<gt>\n"
@@ -12099,7 +11197,7 @@ msgstr ""
 #: build/C/man3/shm_open.3:326
 #, no-wrap
 msgid "#define BUF_SIZE 1024   /* Maximum size for exchanged string */\n"
-msgstr ""
+msgstr "#define BUF_SIZE 1024   /* Maximum size for exchanged string */\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:329
@@ -12123,10 +11221,9 @@ msgstr ""
 
 #. type: SS
 #: build/C/man3/shm_open.3:339
-#, fuzzy, no-wrap
-#| msgid "Program source: t_get_seals.c"
+#, no-wrap
 msgid "Program source: pshm_ucase_bounce.c"
-msgstr "プログラムのソース: t_get_seals.c"
+msgstr "プログラムのソース: pshm_ucase_bounce.c"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:347
@@ -12162,15 +11259,14 @@ msgid ""
 "#include E<lt>ctype.hE<gt>\n"
 "#include \"pshm_ucase.h\"\n"
 msgstr ""
+"   Licensed under GNU General Public License v2 or later.\n"
+"*/\n"
+"#include E<lt>ctype.hE<gt>\n"
+"#include \"pshm_ucase.h\"\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:369
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (argc != 2) {\n"
-#| "        fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -12180,8 +11276,11 @@ msgid ""
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 msgstr ""
+"int\n"
+"main(int argc, char *argv[])\n"
+"{\n"
 "    if (argc != 2) {\n"
-"        fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n"
+"        fprintf(stderr, \"Usage: %s /shm-path\\en\", argv[0]);\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 
@@ -12189,7 +11288,7 @@ msgstr ""
 #: build/C/man3/shm_open.3:371
 #, no-wrap
 msgid "    char *shmpath = argv[1];\n"
-msgstr ""
+msgstr "    char *shmpath = argv[1];\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:374
@@ -12201,33 +11300,27 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:379
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    fd = open(argv[1], O_RDWR);\n"
-#| "    if (fd == -1)\n"
-#| "        errExit(\"open\");\n"
+#, no-wrap
 msgid ""
 "    int fd = shm_open(shmpath, O_CREAT | O_EXCL | O_RDWR,\n"
 "                      S_IRUSR | S_IWUSR);\n"
 "    if (fd == -1)\n"
 "        errExit(\"shm_open\");\n"
 msgstr ""
-"    fd = open(argv[1], O_RDWR);\n"
+"    int fd = shm_open(shmpath, O_CREAT | O_EXCL | O_RDWR,\n"
+"                      S_IRUSR | S_IWUSR);\n"
 "    if (fd == -1)\n"
-"        errExit(\"open\");\n"
+"        errExit(\"shm_open\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:382
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (ftruncate(fd, len) == -1)\n"
-#| "        errExit(\"truncate\");\n"
+#, no-wrap
 msgid ""
 "    if (ftruncate(fd, sizeof(struct shmbuf)) == -1)\n"
 "        errExit(\"ftruncate\");\n"
 msgstr ""
-"    if (ftruncate(fd, len) == -1)\n"
-"        errExit(\"truncate\");\n"
+"    if (ftruncate(fd, sizeof(struct shmbuf)) == -1)\n"
+"        errExit(\"ftruncate\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:384
@@ -12237,12 +11330,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:390 build/C/man3/shm_open.3:479
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
-#| "                MAP_PRIVATE, fd, pa_offset);\n"
-#| "    if (addr == MAP_FAILED)\n"
-#| "        handle_error(\"mmap\");\n"
+#, no-wrap
 msgid ""
 "    struct shmbuf *shmp = mmap(NULL, sizeof(*shmp),\n"
 "                               PROT_READ | PROT_WRITE,\n"
@@ -12250,10 +11338,11 @@ msgid ""
 "    if (shmp == MAP_FAILED)\n"
 "        errExit(\"mmap\");\n"
 msgstr ""
-"    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
-"                MAP_PRIVATE, fd, pa_offset);\n"
-"    if (addr == MAP_FAILED)\n"
-"        handle_error(\"mmap\");\n"
+"    struct shmbuf *shmp = mmap(NULL, sizeof(*shmp),\n"
+"                               PROT_READ | PROT_WRITE,\n"
+"                               MAP_SHARED, fd, 0);\n"
+"    if (shmp == MAP_FAILED)\n"
+"        errExit(\"mmap\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:392
@@ -12270,6 +11359,10 @@ msgid ""
 "    if (sem_init(&shmp-E<gt>sem2, 1, 0) == -1)\n"
 "        errExit(\"sem_init-sem2\");\n"
 msgstr ""
+"    if (sem_init(&shmp-E<gt>sem1, 1, 0) == -1)\n"
+"        errExit(\"sem_init-sem1\");\n"
+"    if (sem_init(&shmp-E<gt>sem2, 1, 0) == -1)\n"
+"        errExit(\"sem_init-sem2\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:400
@@ -12281,16 +11374,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:403
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (ftruncate(fd, len) == -1)\n"
-#| "        errExit(\"truncate\");\n"
+#, no-wrap
 msgid ""
 "    if (sem_wait(&shmp-E<gt>sem1) == -1)\n"
 "        errExit(\"sem_wait\");\n"
 msgstr ""
-"    if (ftruncate(fd, len) == -1)\n"
-"        errExit(\"truncate\");\n"
+"    if (sem_wait(&shmp-E<gt>sem1) == -1)\n"
+"        errExit(\"sem_wait\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:405
@@ -12305,6 +11395,8 @@ msgid ""
 "    for (int j = 0; j E<lt> shmp-E<gt>cnt; j++)\n"
 "        shmp-E<gt>buf[j] = toupper((unsigned char) shmp-E<gt>buf[j]);\n"
 msgstr ""
+"    for (int j = 0; j E<lt> shmp-E<gt>cnt; j++)\n"
+"        shmp-E<gt>buf[j] = toupper((unsigned char) shmp-E<gt>buf[j]);\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:411
@@ -12316,16 +11408,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:414
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (ftruncate(fd, len) == -1)\n"
-#| "        errExit(\"truncate\");\n"
+#, no-wrap
 msgid ""
 "    if (sem_post(&shmp-E<gt>sem2) == -1)\n"
 "        errExit(\"sem_post\");\n"
 msgstr ""
-"    if (ftruncate(fd, len) == -1)\n"
-"        errExit(\"truncate\");\n"
+"    if (sem_post(&shmp-E<gt>sem2) == -1)\n"
+"        errExit(\"sem_post\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:418
@@ -12340,14 +11429,13 @@ msgstr ""
 #: build/C/man3/shm_open.3:420
 #, no-wrap
 msgid "    shm_unlink(shmpath);\n"
-msgstr ""
+msgstr "    shm_unlink(shmpath);\n"
 
 #. type: SS
 #: build/C/man3/shm_open.3:426
-#, fuzzy, no-wrap
-#| msgid "Program source: t_get_seals.c"
+#, no-wrap
 msgid "Program source: pshm_ucase_send.c"
-msgstr "プログラムのソース: t_get_seals.c"
+msgstr "プログラムのソース: pshm_ucase_send.c"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:430
@@ -12372,7 +11460,7 @@ msgstr ""
 #: build/C/man3/shm_open.3:444
 #, no-wrap
 msgid "/* pshm_ucase_send.c\n"
-msgstr ""
+msgstr "/* pshm_ucase_send.c\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:449
@@ -12383,15 +11471,14 @@ msgid ""
 "#include E<lt>string.hE<gt>\n"
 "#include \"pshm_ucase.h\"\n"
 msgstr ""
+"   Licensed under GNU General Public License v2 or later.\n"
+"*/\n"
+"#include E<lt>string.hE<gt>\n"
+"#include \"pshm_ucase.h\"\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:457
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (argc != 2) {\n"
-#| "        fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -12401,43 +11488,37 @@ msgid ""
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 msgstr ""
-"    if (argc != 2) {\n"
-"        fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n"
+"int\n"
+"main(int argc, char *argv[])\n"
+"{\n"
+"    if (argc != 3) {\n"
+"        fprintf(stderr, \"Usage: %s /shm-path string\\en\", argv[0]);\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:461
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    name = argv[1];\n"
-#| "    len = atoi(argv[2]);\n"
-#| "    seals_arg = argv[3];\n"
+#, no-wrap
 msgid ""
 "    char *shmpath = argv[1];\n"
 "    char *string = argv[2];\n"
 "    size_t len = strlen(string);\n"
 msgstr ""
-"    name = argv[1];\n"
-"    len = atoi(argv[2]);\n"
-"    seals_arg = argv[3];\n"
+"    char *shmpath = argv[1];\n"
+"    char *string = argv[2];\n"
+"    size_t len = strlen(string);\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:466
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (offset E<gt>= sb.st_size) {\n"
-#| "        fprintf(stderr, \"offset is past end of file\\en\");\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "    if (len E<gt> BUF_SIZE) {\n"
 "        fprintf(stderr, \"String is too long\\en\");\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 msgstr ""
-"    if (offset E<gt>= sb.st_size) {\n"
-"        fprintf(stderr, \"offset is past end of file\\en\");\n"
+"    if (len E<gt> BUF_SIZE) {\n"
+"        fprintf(stderr, \"String is too long\\en\");\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 
@@ -12451,19 +11532,15 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:473
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    fd = open(argv[1], O_RDWR);\n"
-#| "    if (fd == -1)\n"
-#| "        errExit(\"open\");\n"
+#, no-wrap
 msgid ""
 "    int fd = shm_open(shmpath, O_RDWR, 0);\n"
 "    if (fd == -1)\n"
 "        errExit(\"shm_open\");\n"
 msgstr ""
-"    fd = open(argv[1], O_RDWR);\n"
+"    int fd = shm_open(shmpath, O_RDWR, 0);\n"
 "    if (fd == -1)\n"
-"        errExit(\"open\");\n"
+"        errExit(\"shm_open\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:481
@@ -12478,26 +11555,24 @@ msgid ""
 "    shmp-E<gt>cnt = len;\n"
 "    memcpy(&shmp-E<gt>buf, string, len);\n"
 msgstr ""
+"    shmp-E<gt>cnt = len;\n"
+"    memcpy(&shmp-E<gt>buf, string, len);\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:486
-#, fuzzy, no-wrap
-#| msgid "    /* The main thread also allocates some memory */\n"
+#, no-wrap
 msgid "    /* Tell peer that it can now access shared memory */\n"
-msgstr "    /* The main thread also allocates some memory */\n"
+msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:489
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (ftruncate(fd, len) == -1)\n"
-#| "        errExit(\"truncate\");\n"
+#, no-wrap
 msgid ""
 "    if (sem_post(&shmp-E<gt>sem1) == -1)\n"
 "        errExit(\"sem_post\");\n"
 msgstr ""
-"    if (ftruncate(fd, len) == -1)\n"
-"        errExit(\"truncate\");\n"
+"    if (sem_post(&shmp-E<gt>sem1) == -1)\n"
+"        errExit(\"sem_post\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:492
@@ -12509,16 +11584,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:495
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (ftruncate(fd, len) == -1)\n"
-#| "        errExit(\"truncate\");\n"
+#, no-wrap
 msgid ""
 "    if (sem_wait(&shmp-E<gt>sem2) == -1)\n"
 "        errExit(\"sem_wait\");\n"
 msgstr ""
-"    if (ftruncate(fd, len) == -1)\n"
-"        errExit(\"truncate\");\n"
+"    if (sem_wait(&shmp-E<gt>sem2) == -1)\n"
+"        errExit(\"sem_wait\");\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:497
@@ -12533,6 +11605,8 @@ msgid ""
 "    write(STDOUT_FILENO, &shmp-E<gt>buf, len);\n"
 "    write(STDOUT_FILENO, \"\\en\", 1);\n"
 msgstr ""
+"    write(STDOUT_FILENO, &shmp-E<gt>buf, len);\n"
+"    write(STDOUT_FILENO, \"\\en\", 1);\n"
 
 #. type: Plain text
 #: build/C/man3/shm_open.3:517
@@ -12739,22 +11813,12 @@ msgstr "ファイルシステム経由での共有メモリーオブジェクト
 
 #. type: Plain text
 #: build/C/man7/shm_overview.7:100
-#, fuzzy
-#| msgid ""
-#| "On Linux, shared memory objects are created in a (I<tmpfs>)  virtual "
-#| "filesystem, normally mounted under I</dev/shm>.  Since kernel 2.6.19, "
-#| "Linux supports the use of access control lists (ACLs)  to control the "
-#| "permissions of objects in the virtual filesystem."
 msgid ""
 "On Linux, shared memory objects are created in a (I<tmpfs>(5))  virtual "
 "filesystem, normally mounted under I</dev/shm>.  Since kernel 2.6.19, Linux "
 "supports the use of access control lists (ACLs)  to control the permissions "
 "of objects in the virtual filesystem."
-msgstr ""
-"Linux では、共有メモリーオブジェクトは通常 I</dev/shm> 以下にマウントされる仮"
-"想ファイルシステム (I<tmpfs>)  内に作成される。 カーネル 2.6.19 以降の Linux "
-"では、 仮想ファイルシステム内のオブジェクトの許可属性の制御に、 アクセス制御"
-"リスト (ACL; access control lists) を使うことができる。"
+msgstr "Linux では、共有メモリーオブジェクトは通常 I</dev/shm> 以下にマウントされる仮想ファイルシステム (B<tmpfs>(5))  内に作成される。 カーネル 2.6.19 以降の Linux では、 仮想ファイルシステム内のオブジェクトの許可属性の制御に、 アクセス制御リスト (ACL; access control lists) を使うことができる。"
 
 #. type: Plain text
 #: build/C/man7/shm_overview.7:103
@@ -12837,19 +11901,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:83
-#, fuzzy, no-wrap
-#| msgid ""
-#| "struct shmid_ds {\n"
-#| "    struct ipc_perm shm_perm;    /* Ownership and permissions */\n"
-#| "    size_t          shm_segsz;   /* Size of segment (bytes) */\n"
-#| "    time_t          shm_atime;   /* Last attach time */\n"
-#| "    time_t          shm_dtime;   /* Last detach time */\n"
-#| "    time_t          shm_ctime;   /* Last change time */\n"
-#| "    pid_t           shm_cpid;    /* PID of creator */\n"
-#| "    pid_t           shm_lpid;    /* PID of last shmat(2)/shmdt(2) */\n"
-#| "    shmatt_t        shm_nattch;  /* No. of current attaches */\n"
-#| "    ...\n"
-#| "};\n"
+#, no-wrap
 msgid ""
 "struct shmid_ds {\n"
 "    struct ipc_perm shm_perm;    /* Ownership and permissions */\n"
@@ -12869,7 +11921,8 @@ msgstr ""
 "    size_t          shm_segsz;   /* セグメントのサイズ (バイト) */\n"
 "    time_t          shm_atime;   /* 最後の付加 (attach) の時刻 */\n"
 "    time_t          shm_dtime;   /* 最後の分離 (detach) の時刻 */\n"
-"    time_t          shm_ctime;   /* 最後に変更が行われた時刻 */\n"
+"    time_t          shm_ctime;   /* 作成時刻 / shmctl() による\n"
+"                                    最後の変更時刻 */\n"
 "    pid_t           shm_cpid;    /* 作成者 (creator) の PID */\n"
 "    pid_t           shm_lpid;    /* 最後の shmat(2)/shmdt(2) の PID */\n"
 "    shmatt_t        shm_nattch;  /* 現在付加されている数 */\n"
@@ -12878,18 +11931,14 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:89
-#, fuzzy
-#| msgid ""
-#| "The fields of the I<mallinfo> structure contain the following information:"
 msgid "The fields of the I<shmid_ds> structure are as follows:"
-msgstr "I<mallinfo> 構造体の各フィールドには以下の情報が格納される。"
+msgstr "I<shmid_ds> 構造体のフィールドは以下の通りである。"
 
 #. type: TP
 #: build/C/man2/shmctl.2:89
-#, fuzzy, no-wrap
-#| msgid "B<shm_open>(3)"
+#, no-wrap
 msgid "I<shm_perm>"
-msgstr "B<shm_open>(3)"
+msgstr "I<shm_perm>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:95
@@ -12902,20 +11951,18 @@ msgstr ""
 #: build/C/man2/shmctl.2:95
 #, no-wrap
 msgid "I<shm_segsz>"
-msgstr ""
+msgstr "I<shm_segsz>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:98
-#, fuzzy
-#| msgid "Maximum size in bytes for a shared memory segment."
 msgid "Size in bytes of the shared memory segment."
-msgstr "1 つの共有メモリーセグメントの最大サイズ (バイト数)。"
+msgstr "共有メモリーセグメントのサイズ (バイト単位)。"
 
 #. type: TP
 #: build/C/man2/shmctl.2:98
 #, no-wrap
 msgid "I<shm_atime>"
-msgstr ""
+msgstr "I<shm_atime>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:103
@@ -12926,7 +11973,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:103
 #, no-wrap
 msgid "I<shm_dtime>"
-msgstr ""
+msgstr "I<shm_dtime>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:108
@@ -12937,7 +11984,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:108
 #, no-wrap
 msgid "I<shm_ctime>"
-msgstr ""
+msgstr "I<shm_ctime>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:114
@@ -12950,20 +11997,18 @@ msgstr ""
 #: build/C/man2/shmctl.2:114
 #, no-wrap
 msgid "I<shm_cpid>"
-msgstr ""
+msgstr "I<shm_cpid>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:117
-#, fuzzy
-#| msgid "shmget - allocates a System V shared memory segment"
 msgid "ID of the process that created the shared memory segment."
-msgstr "shmget - System V 共有メモリーセグメントを割り当てる"
+msgstr "その共有メモリーセグメントを作成したプロセスの ID。"
 
 #. type: TP
 #: build/C/man2/shmctl.2:117
 #, no-wrap
 msgid "I<shm_lpid>"
-msgstr ""
+msgstr "I<shm_lpid>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:124
@@ -12976,7 +12021,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:124
 #, no-wrap
 msgid "I<shm_nattch>"
-msgstr ""
+msgstr "I<shm_nattch>"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:127
@@ -13030,7 +12075,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:157
 #, no-wrap
 msgid "0400"
-msgstr ""
+msgstr "0400"
 
 #. type: tbl table
 #: build/C/man2/shmctl.2:157
@@ -13042,7 +12087,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:158
 #, no-wrap
 msgid "0200"
-msgstr ""
+msgstr "0200"
 
 #. type: tbl table
 #: build/C/man2/shmctl.2:158
@@ -13054,7 +12099,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:159
 #, no-wrap
 msgid "0040"
-msgstr ""
+msgstr "0040"
 
 #. type: tbl table
 #: build/C/man2/shmctl.2:159
@@ -13066,7 +12111,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:160
 #, no-wrap
 msgid "0020"
-msgstr ""
+msgstr "0020"
 
 #. type: tbl table
 #: build/C/man2/shmctl.2:160
@@ -13078,7 +12123,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:161
 #, no-wrap
 msgid "0004"
-msgstr ""
+msgstr "0004"
 
 #. type: tbl table
 #: build/C/man2/shmctl.2:161
@@ -13090,7 +12135,7 @@ msgstr ""
 #: build/C/man2/shmctl.2:162
 #, no-wrap
 msgid "0002"
-msgstr ""
+msgstr "0002"
 
 #. type: tbl table
 #: build/C/man2/shmctl.2:162
@@ -13144,15 +12189,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:199
-#, fuzzy
-#| msgid ""
-#| "The least significant 9 bits of I<shm_perm.mode> are set to the least "
-#| "significant 9 bit of I<shmflg>."
 msgid ""
 "The following fields are updated: I<shm_perm.uid>, I<shm_perm.gid>, and (the "
 "least significant 9 bits of) I<shm_perm.mode>."
-msgstr ""
-"I<shm_perm.mode> の下位 9 ビットに I<shmflg> の下位 9 ビットを設定する。"
+msgstr "以下のフィールドが更新される: I<shm_perm.uid>, I<shm_perm.gid> および I<shm_perm.mode> (の下位 9 ビット)。"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:205
@@ -13335,10 +12375,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/shmctl.2:315
-#, fuzzy, no-wrap
-#| msgid "B<SHM_EXEC> (Linux-specific; since Linux 2.6.9)"
+#, no-wrap
 msgid "B<SHM_STAT_ANY> (Linux-specific, since Linux 4.17)"
-msgstr "B<SHM_EXEC> (Linux 固有; Linux 2.6.9 以降)"
+msgstr "B<SHM_STAT_ANY> (Linux-specific, Linux 4.17 以降)"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:328
@@ -13412,15 +12451,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:384
-#, fuzzy
-#| msgid ""
-#| "A successful B<IPC_INFO> or B<SHM_INFO> operation returns the index of "
-#| "the highest used entry in the kernel's internal array recording "
-#| "information about all shared memory segments.  (This information can be "
-#| "used with repeated B<SHM_STAT> operations to obtain information about all "
-#| "shared memory segments on the system.)  A successful B<SHM_STAT> "
-#| "operation returns the identifier of the shared memory segment whose index "
-#| "was given in I<shmid>.  Other operations return 0 on success."
 msgid ""
 "A successful B<IPC_INFO> or B<SHM_INFO> operation returns the index of the "
 "highest used entry in the kernel's internal array recording information "
@@ -13429,13 +12459,7 @@ msgid ""
 "about all shared memory segments on the system.)  A successful B<SHM_STAT> "
 "operation returns the identifier of the shared memory segment whose index "
 "was given in I<shmid>.  Other operations return 0 on success."
-msgstr ""
-"B<IPC_INFO> と B<SHM_INFO> 操作は、成功すると、全ての共有メモリーセグメントに"
-"関する情報を 管理しているカーネルの内部配列の使用中エントリーのインデックス"
-"の うち最大値を返す (この情報は、システムの全ての共有メモリーセグメントに関す"
-"る情報を 取得するために、 B<SHM_STAT> 操作を繰り返し実行する際に使用でき"
-"る)。 B<SHM_STAT> 操作は、成功すると、 I<shmid> で指定されたインデックスを持"
-"つ共有メモリーセグメントの識別子を返す。 他の操作は、成功の場合 0 を返す。"
+msgstr "B<IPC_INFO> と B<SHM_INFO> 操作は、成功すると、全ての共有メモリーセグメントに関する情報を 管理しているカーネルの内部配列の使用中エントリーのインデックスの うち最大値を返す (この情報は、システムの全ての共有メモリーセグメントに関する情報を 取得するために、操作 B<SHM_STAT> か B<SHM_STAT_ANY> を繰り返し実行する際に使用できる)。 B<SHM_STAT> 操作は、成功すると、 I<shmid> で指定されたインデックスを持つ共有メモリーセグメントの識別子を返す。 他の操作は、成功の場合 0 を返す。"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:388
@@ -13481,19 +12505,11 @@ msgstr "I<shmid> が削除 (remove) された識別子 (identifier) を指して
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:422
-#, fuzzy
-#| msgid ""
-#| "I<shmid> is not a valid identifier, or I<cmd> is not a valid command.  "
-#| "Or: for a B<SHM_STAT> operation, the index value specified in I<shmid> "
-#| "referred to an array slot that is currently unused."
 msgid ""
 "I<shmid> is not a valid identifier, or I<cmd> is not a valid command.  Or: "
 "for a B<SHM_STAT> or B<SHM_STAT_ANY> operation, the index value specified in "
 "I<shmid> referred to an array slot that is currently unused."
-msgstr ""
-"I<shmid> が有効な識別子でないか、 I<cmd> が有効なコマンドでない。 もしくは、 "
-"B<SHM_STAT> 操作の場合に、 I<shmid> で指定されたインデックス値が現在未使用の"
-"配列のスロットを参照していた。"
+msgstr "I<shmid> が有効な識別子でないか、 I<cmd> が有効なコマンドでない。 もしくは、操作 B<SHM_STAT> か B<SHM_STAT_ANY> の場合に、 I<shmid> で指定されたインデックス値が現在未使用の配列のスロットを参照していた。"
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:433
@@ -13563,12 +12579,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:492
-#, fuzzy
-#| msgid ""
-#| "The B<IPC_INFO>, B<SHM_STAT> and B<SHM_INFO> operations are used by the "
-#| "B<ipcs>(1)  program to provide information on allocated resources.  In "
-#| "the future, these may modified or moved to a I</proc> filesystem "
-#| "interface."
 msgid ""
 "The B<IPC_INFO>, B<SHM_STAT>, and B<SHM_INFO> operations are used by the "
 "B<ipcs>(1)  program to provide information on allocated resources.  In the "
@@ -13607,16 +12617,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmctl.2:520
-#, fuzzy
-#| msgid ""
-#| "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), "
-#| "B<capabilities>(7), B<svipc>(7)"
 msgid ""
 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
 "B<sysvipc>(7)"
-msgstr ""
-"B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
-"B<shm_overview>(7), B<svipc>(7)"
+msgstr "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), B<sysvipc>(7)"
 
 #. type: TH
 #: build/C/man2/shmget.2:38
@@ -13661,27 +12665,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmget.2:81
-#, fuzzy
-#| msgid ""
-#| "B<shmget>()  returns the identifier of the System\\ V shared memory "
-#| "segment associated with the value of the argument I<key>.  A new shared "
-#| "memory segment, with size equal to the value of I<size> rounded up to a "
-#| "multiple of B<PAGE_SIZE>, is created if I<key> has the value "
-#| "B<IPC_PRIVATE> or I<key> isn't B<IPC_PRIVATE>, no shared memory segment "
-#| "corresponding to I<key> exists, and B<IPC_CREAT> is specified in "
-#| "I<shmflg>."
 msgid ""
 "A new shared memory segment, with size equal to the value of I<size> rounded "
 "up to a multiple of B<PAGE_SIZE>, is created if I<key> has the value "
 "B<IPC_PRIVATE> or I<key> isn't B<IPC_PRIVATE>, no shared memory segment "
 "corresponding to I<key> exists, and B<IPC_CREAT> is specified in I<shmflg>."
-msgstr ""
-"B<shmget>()  は I<key> 引き数に対応する System\\ V 共有メモリーセグメントの識"
-"別子を返す。 I<key> の値が B<IPC_PRIVATE> の場合、もしくは I<key> に対応する"
-"共有メモリーセグメントが存在せず、 I<shmflg> に B<IPC_CREAT> が指定されていた"
-"場合、 新しい共有メモリーセグメントを作成する。 作成される共有メモリーセグメ"
-"ントは、 I<size> 引き数の値を B<PAGE_SIZE> の倍数へと切り上げた (round up) 大"
-"きさとなる。"
+msgstr "I<key> の値が B<IPC_PRIVATE> の場合、もしくは I<key> に対応する共有メモリーセグメントが存在せず、 I<shmflg> に B<IPC_CREAT> が指定されていた場合、 新しい共有メモリーセグメントを作成する。 作成される共有メモリーセグメントは、 I<size> 引き数の値を B<PAGE_SIZE> の倍数へと切り上げた (round up) 大きさとなる。"
 
 #. type: Plain text
 #: build/C/man2/shmget.2:100
@@ -13741,23 +12730,16 @@ msgstr "B<SHM_HUGETLB> (Linux 2.6 以降)"
 
 #. type: Plain text
 #: build/C/man2/shmget.2:123
-#, fuzzy
-#| msgid ""
-#| "Allocate the segment using \"huge pages.\" See the Linux kernel source "
-#| "file I<Documentation/vm/hugetlbpage.txt> for further information."
 msgid ""
 "Allocate the segment using \"huge pages.\" See the Linux kernel source file "
 "I<Documentation/admin-guide/mm/hugetlbpage.rst> for further information."
-msgstr ""
-"\"ヒュージページ (huge page)\" を使うセグメントを割り当てる。詳細な情報は、"
-"Linux カーネルソースのファイル I<Documentation/vm/hugetlbpage.txt> を参照。"
+msgstr "\"ヒュージページ (huge page)\" を使うセグメントを割り当てる。詳細な情報は、Linux カーネルソースのファイル I<Documentation/admin-guide/vm/hugetlbpage.rst> を参照。"
 
 #. type: TP
 #: build/C/man2/shmget.2:123
-#, fuzzy, no-wrap
-#| msgid "B<SHM_HUGETLB> (since Linux 2.6)"
+#, no-wrap
 msgid "B<SHM_HUGE_2MB>, B<SHM_HUGE_1GB> (since Linux 3.8)"
-msgstr "B<SHM_HUGETLB> (Linux 2.6 以降)"
+msgstr "B<SHM_HUGE_2MB>, B<SHM_HUGE_1GB> (Linux 3.8 以降)"
 
 #.  See https://lwn.net/Articles/533499/
 #. type: Plain text
@@ -13848,7 +12830,7 @@ msgstr ""
 #: build/C/man2/shmop.2:159 build/C/man2/shmop.2:162
 #, no-wrap
 msgid "\\(bu"
-msgstr ""
+msgstr "\\(bu"
 
 #. type: Plain text
 #: build/C/man2/shmget.2:188
@@ -14083,20 +13065,11 @@ msgstr "    SHMMAX / PAGE_SIZE * (SHMMNI / 16)\n"
 
 #. type: Plain text
 #: build/C/man2/shmget.2:352
-#, fuzzy
-#| msgid ""
-#| "If B<SHMMAX> and B<SHMMNI> were not modified, then multiplying the result "
-#| "of this formula by the page size (to get a value in bytes) yielded a "
-#| "value of 8 GB as the limit on the total memory used by all shared memory "
-#| "segments."
 msgid ""
 "If B<SHMMAX> and B<SHMMNI> were not modified, then multiplying the result of "
 "this formula by the page size (to get a value in bytes) yielded a value of "
 "8\\ GB as the limit on the total memory used by all shared memory segments."
-msgstr ""
-"B<SHMMAX> と B<SHMMNI> が変更されないとすると、 この式の結果に (バイト単位の"
-"値を得るために) ページサイズを掛け算すると、 全ての共有メモリーセグメントで使"
-"用される全メモリーの上限として、 8 GB という値が得られる。"
+msgstr "B<SHMMAX> と B<SHMMNI> が変更されないとすると、 この式の結果に (バイト単位の値を得るために) ページサイズを掛け算すると、 全ての共有メモリーセグメントで使用される全メモリーの上限として、 8\\ GB という値が得られる。"
 
 #. type: TP
 #: build/C/man2/shmget.2:352
@@ -14134,36 +13107,19 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmget.2:375
-#, fuzzy
-#| msgid ""
-#| "From Linux 2.2 up to Linux 3.15, the default value of this limit was "
-#| "0x2000000 (32MB)."
 msgid ""
 "From Linux 2.2 up to Linux 3.15, the default value of this limit was "
 "0x2000000 (32\\ MB)."
-msgstr ""
-"Linux 2.2 から Linux 3.15 までは、この上限値のデフォルト値は 0x2000000 "
-"(32MB) であった。"
+msgstr "Linux 2.2 から Linux 3.15 までは、この上限値のデフォルト値は 0x2000000 (32\\ MB) であった。"
 
 #. type: Plain text
 #: build/C/man2/shmget.2:381
-#, fuzzy
-#| msgid ""
-#| "Because it is not possible to map just part of a shared memory segment, "
-#| "the amount of virtual memory places another limit on the maximum size of "
-#| "a usable segment: for example, on i386 the largest segments that can be "
-#| "mapped have a size of around 2.8 GB, and on x86_64 the limit is around "
-#| "127 TB."
 msgid ""
 "Because it is not possible to map just part of a shared memory segment, the "
 "amount of virtual memory places another limit on the maximum size of a "
 "usable segment: for example, on i386 the largest segments that can be mapped "
 "have a size of around 2.8\\ GB, and on x86-64 the limit is around 127 TB."
-msgstr ""
-"共有メモリーセグメントの一部分だけをマッピングすることはできないので、 使用可"
-"能なセグメントの最大サイズには仮想メモリーの総量という別の上限が適用される。 "
-"例えば、i386 ではマッピング可能な最大セグメントの大きさはおおよそ 2.8GB で、 "
-"x86_64 では上限はおおよそ 127TB である。"
+msgstr "共有メモリーセグメントの一部分だけをマッピングすることはできないので、 使用可能なセグメントの最大サイズには仮想メモリーの総量という別の上限が適用される。 例えば、i386 ではマッピング可能な最大セグメントの大きさはおおよそ 2.8\\ GB で、 x86-64 では上限はおおよそ 127TB である。"
 
 #. type: TP
 #: build/C/man2/shmget.2:381
@@ -14236,23 +13192,15 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmget.2:417
-#, fuzzy
-#| msgid "B<shm_open>(3)"
 msgid "See B<shmop>(2)."
-msgstr "B<shm_open>(3)"
+msgstr "B<shmop>(2) を参照。"
 
 #. type: Plain text
 #: build/C/man2/shmget.2:426
-#, fuzzy
-#| msgid ""
-#| "B<memfd_create>(2), B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), "
-#| "B<capabilities>(7), B<shm_overview>(7), B<svipc>(7)"
 msgid ""
 "B<memfd_create>(2), B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), "
 "B<capabilities>(7), B<shm_overview>(7), B<sysvipc>(7)"
-msgstr ""
-"B<memfd_create>(2), B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), "
-"B<capabilities>(7), B<shm_overview>(7), B<svipc>(7)"
+msgstr "B<memfd_create>(2), B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), B<shm_overview>(7), B<sysvipc>(7)"
 
 #. type: TH
 #: build/C/man2/shmop.2:40
@@ -14306,16 +13254,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:67
-#, fuzzy
-#| msgid ""
-#| "If I<shmaddr> is NULL, the system chooses a suitable (unused) address at "
-#| "which to attach the segment."
 msgid ""
 "If I<shmaddr> is NULL, the system chooses a suitable (unused) page-aligned "
 "address to attach the segment."
-msgstr ""
-"I<shmaddr> が NULL ならば、システムはセグメントを付加するための 適切な (使用"
-"されていない) アドレスを選択する。"
+msgstr "I<shmaddr> が NULL ならば、システムはセグメントを付加するための 適切な (使用されていない) ページ境界のアドレスを選択する。"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:79
@@ -14612,19 +13554,11 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:271
-#, fuzzy
-#| msgid ""
-#| "On Linux, it is possible to attach a shared memory segment even if it is "
-#| "already marked to be deleted.  However, POSIX.1-2001 does not specify "
-#| "this behavior and many other implementations do not support it."
 msgid ""
 "On Linux, it is possible to attach a shared memory segment even if it is "
 "already marked to be deleted.  However, POSIX.1 does not specify this "
 "behavior and many other implementations do not support it."
-msgstr ""
-"Linux では共有メモリーセグメントに既に削除マークが付けられていても、 その共有"
-"メモリーセグメントを付加することができる。 しかし POSIX.1-2001 ではこのような"
-"動作を指定しておらず、 他の多くの実装もこれをサポートしていない。"
+msgstr "Linux では共有メモリーセグメントに既に削除マークが付けられていても、 その共有メモリーセグメントを付加することができる。 しかし POSIX.1 ではこのような動作を指定しておらず、 他の多くの実装もこれをサポートしていない。"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:274
@@ -14639,16 +13573,6 @@ msgstr "B<SHMLBA>"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:289
-#, fuzzy
-#| msgid ""
-#| "Segment low boundary address multiple.  When explicitly specifying an "
-#| "attach address in a call to B<shmat>(), the caller should ensure that the "
-#| "address is a multiple of this value.  This is necessary on some "
-#| "architectures, in order either to ensure good CPU cache performance or to "
-#| "ensure that different attaches of the same segment have consistent views "
-#| "within the CPU cache.  B<SHMLBA> is normally some multiple of the system "
-#| "page size (on many Linux architectures, it is the same as the system page "
-#| "size)."
 msgid ""
 "Segment low boundary address multiple.  When explicitly specifying an attach "
 "address in a call to B<shmat>(), the caller should ensure that the address "
@@ -14657,14 +13581,7 @@ msgid ""
 "different attaches of the same segment have consistent views within the CPU "
 "cache.  B<SHMLBA> is normally some multiple of the system page size.  (On "
 "many Linux architectures, B<SHMLBA> is the same as the system page size.)"
-msgstr ""
-"セグメントの下限アドレス倍数 (Segment low boundary address multiple)。 "
-"B<shmat>() の呼び出しにおいて付加するアドレスを明示的に指定する際、 呼び出し"
-"元は指定するアドレスがこの値の倍数になるように保証しなければならない。 これは"
-"いくつかのアーキテクチャーでは必要なことで、 CPU キャッシュの性能を保証するた"
-"めであったり、 同じセグメントの別の付与を CPU キャッシュ内部で一貫して扱える"
-"ようにするためだったりする。 B<SHMLBA> は通常はシステムページサイズの倍数であ"
-"る (Linux の多くのアーキテクチャーではシステムページサイズと同じである)。"
+msgstr "セグメントの下限アドレス倍数 (Segment low boundary address multiple)。 B<shmat>() の呼び出しにおいて付加するアドレスを明示的に指定する際、 呼び出し元は指定するアドレスがこの値の倍数になるように保証しなければならない。 これはいくつかのアーキテクチャーでは必要なことで、 CPU キャッシュの性能を保証するためであったり、 同じセグメントの別の付与を CPU キャッシュ内部で一貫して扱えるようにするためだったりする。 B<SHMLBA> は通常はシステムページサイズの倍数である (Linux の多くのアーキテクチャーでは B<SHMLBA> はシステムページサイズと同じである)。"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:293
@@ -14699,6 +13616,8 @@ msgid ""
 "$ B<./svshm_string_read>\n"
 "shmid = 1114194; semid = 15\n"
 msgstr ""
+"$ B<./svshm_string_read>\n"
+"shmid = 1114194; semid = 15\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:316
@@ -14714,7 +13633,7 @@ msgstr ""
 #: build/C/man2/shmop.2:320
 #, no-wrap
 msgid "$ B<./svshm_string_write 1114194 15 \\(aqHello, world\\(aq>\n"
-msgstr ""
+msgstr "$ B<./svshm_string_write 1114194 15 \\(aqHello, world\\(aq>\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:327
@@ -14728,14 +13647,13 @@ msgstr ""
 #: build/C/man2/shmop.2:331
 #, no-wrap
 msgid "Hello, world\n"
-msgstr ""
+msgstr "Hello, world\n"
 
 #. type: SS
 #: build/C/man2/shmop.2:334
-#, fuzzy, no-wrap
-#| msgid "Program source: t_memfd_create.c"
+#, no-wrap
 msgid "Program source: svshm_string.h"
-msgstr "プログラムのソース: t_memfd_create.c"
+msgstr "プログラムのソース: svshm_string.h"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:336
@@ -14746,15 +13664,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:346
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>unistd.hE<gt>\n"
-#| "#include E<lt>signal.hE<gt>\n"
-#| "#include E<lt>stdio.hE<gt>\n"
-#| "#include E<lt>malloc.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
-#| "#include E<lt>errno.hE<gt>\n"
-#| "#include E<lt>sys/mman.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#include E<lt>sys/types.hE<gt>\n"
 "#include E<lt>sys/ipc.hE<gt>\n"
@@ -14764,13 +13674,13 @@ msgid ""
 "#include E<lt>stdlib.hE<gt>\n"
 "#include E<lt>string.hE<gt>\n"
 msgstr ""
-"#include E<lt>unistd.hE<gt>\n"
-"#include E<lt>signal.hE<gt>\n"
+"#include E<lt>sys/types.hE<gt>\n"
+"#include E<lt>sys/ipc.hE<gt>\n"
+"#include E<lt>sys/shm.hE<gt>\n"
+"#include E<lt>sys/sem.hE<gt>\n"
 "#include E<lt>stdio.hE<gt>\n"
-"#include E<lt>malloc.hE<gt>\n"
 "#include E<lt>stdlib.hE<gt>\n"
-"#include E<lt>errno.hE<gt>\n"
-"#include E<lt>sys/mman.hE<gt>\n"
+"#include E<lt>string.hE<gt>\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:358
@@ -14785,19 +13695,26 @@ msgid ""
 "#endif\n"
 "};\n"
 msgstr ""
+"union semun {                   /* Used in calls to semctl() */\n"
+"    int                 val;\n"
+"    struct semid_ds *   buf;\n"
+"    unsigned short *    array;\n"
+"#if defined(__linux__)\n"
+"    struct seminfo *    __buf;\n"
+"#endif\n"
+"};\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:360
 #, no-wrap
 msgid "#define MEM_SIZE 4096\n"
-msgstr ""
+msgstr "#define MEM_SIZE 4096\n"
 
 #. type: SS
 #: build/C/man2/shmop.2:363
-#, fuzzy, no-wrap
-#| msgid "Program source: t_get_seals.c"
+#, no-wrap
 msgid "Program source: svshm_string_read.c"
-msgstr "プログラムのソース: t_get_seals.c"
+msgstr "プログラムのソース: svshm_string_read.c"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:371
@@ -14813,7 +13730,7 @@ msgstr ""
 #: build/C/man2/shmop.2:375
 #, no-wrap
 msgid "/* svshm_string_read.c\n"
-msgstr ""
+msgstr "/* svshm_string_read.c\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:379 build/C/man2/shmop.2:453
@@ -14823,16 +13740,13 @@ msgid ""
 "*/\n"
 "#include \"svshm_string.h\"\n"
 msgstr ""
+"   Licensed under GNU General Public License v2 or later.\n"
+"*/\n"
+"#include \"svshm_string.h\"\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:387
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "    int fd;\n"
-#| "    unsigned int seals;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -14845,8 +13759,10 @@ msgstr ""
 "int\n"
 "main(int argc, char *argv[])\n"
 "{\n"
-"    int fd;\n"
-"    unsigned int seals;\n"
+"    int semid, shmid;\n"
+"    union semun arg, dummy;\n"
+"    struct sembuf sop;\n"
+"    char *addr;\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:390
@@ -14858,35 +13774,27 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:394
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    seals = fcntl(fd, F_GET_SEALS);\n"
-#| "    if (seals == -1)\n"
-#| "        errExit(\"fcntl\");\n"
+#, no-wrap
 msgid ""
 "    shmid = shmget(IPC_PRIVATE, MEM_SIZE, IPC_CREAT | 0600);\n"
 "    if (shmid == -1)\n"
 "        errExit(\"shmget\");\n"
 msgstr ""
-"    seals = fcntl(fd, F_GET_SEALS);\n"
-"    if (seals == -1)\n"
-"        errExit(\"fcntl\");\n"
+"    shmid = shmget(IPC_PRIVATE, MEM_SIZE, IPC_CREAT | 0600);\n"
+"    if (shmid == -1)\n"
+"        errExit(\"shmget\");\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:398
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    fd = open(argv[1], O_RDWR);\n"
-#| "    if (fd == -1)\n"
-#| "        errExit(\"open\");\n"
+#, no-wrap
 msgid ""
 "    semid = semget(IPC_PRIVATE, 1, IPC_CREAT | 0600);\n"
 "    if (shmid == -1)\n"
 "        errExit(\"shmget\");\n"
 msgstr ""
-"    fd = open(argv[1], O_RDWR);\n"
-"    if (fd == -1)\n"
-"        errExit(\"open\");\n"
+"    semid = semget(IPC_PRIVATE, 1, IPC_CREAT | 0600);\n"
+"    if (shmid == -1)\n"
+"        errExit(\"shmget\");\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:400
@@ -14896,19 +13804,15 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:404
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    fd = memfd_create(name, MFD_ALLOW_SEALING);\n"
-#| "    if (fd == -1)\n"
-#| "        errExit(\"memfd_create\");\n"
+#, no-wrap
 msgid ""
 "    addr = shmat(shmid, NULL, SHM_RDONLY);\n"
 "    if (addr == (void *) -1)\n"
 "        errExit(\"shmat\");\n"
 msgstr ""
-"    fd = memfd_create(name, MFD_ALLOW_SEALING);\n"
-"    if (fd == -1)\n"
-"        errExit(\"memfd_create\");\n"
+"    addr = shmat(shmid, NULL, SHM_RDONLY);\n"
+"    if (addr == (void *) -1)\n"
+"        errExit(\"shmat\");\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:406
@@ -14918,25 +13822,21 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:410
-#, fuzzy, no-wrap
-#| msgid ""
-#| "        if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n"
-#| "            errExit(\"fcntl\");\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "    arg.val = 1;\n"
 "    if (semctl(semid, 0, SETVAL, arg) == -1)\n"
 "        errExit(\"semctl\");\n"
 msgstr ""
-"        if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n"
-"            errExit(\"fcntl\");\n"
-"    }\n"
+"    arg.val = 1;\n"
+"    if (semctl(semid, 0, SETVAL, arg) == -1)\n"
+"        errExit(\"semctl\");\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:412
 #, no-wrap
 msgid "    printf(\"shmid = %d; semid = %d\\en\", shmid, semid);\n"
-msgstr ""
+msgstr "    printf(\"shmid = %d; semid = %d\\en\", shmid, semid);\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:414
@@ -14952,32 +13852,31 @@ msgid ""
 "    sop.sem_op = 0;\n"
 "    sop.sem_flg = 0;\n"
 msgstr ""
+"    sop.sem_num = 0;\n"
+"    sop.sem_op = 0;\n"
+"    sop.sem_flg = 0;\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:421 build/C/man2/shmop.2:495
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (ftruncate(fd, len) == -1)\n"
-#| "        errExit(\"truncate\");\n"
+#, no-wrap
 msgid ""
 "    if (semop(semid, &sop, 1) == -1)\n"
 "        errExit(\"semop\");\n"
 msgstr ""
-"    if (ftruncate(fd, len) == -1)\n"
-"        errExit(\"truncate\");\n"
+"    if (semop(semid, &sop, 1) == -1)\n"
+"        errExit(\"semop\");\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:423
-#, fuzzy, no-wrap
-#| msgid "    /* The main thread also allocates some memory */\n"
+#, no-wrap
 msgid "    /* Print the string from shared memory */\n"
-msgstr "    /* The main thread also allocates some memory */\n"
+msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:425
 #, no-wrap
 msgid "    printf(\"%s\\en\", addr);\n"
-msgstr ""
+msgstr "    printf(\"%s\\en\", addr);\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:427
@@ -14994,13 +13893,16 @@ msgid ""
 "    if (semctl(semid, 0, IPC_RMID, dummy) == -1)\n"
 "        errExit(\"semctl\");\n"
 msgstr ""
+"    if (shmctl(shmid, IPC_RMID, NULL) == -1)\n"
+"        errExit(\"shmctl\");\n"
+"    if (semctl(semid, 0, IPC_RMID, dummy) == -1)\n"
+"        errExit(\"semctl\");\n"
 
 #. type: SS
 #: build/C/man2/shmop.2:438
-#, fuzzy, no-wrap
-#| msgid "Program source: t_get_seals.c"
+#, no-wrap
 msgid "Program source: svshm_string_write.c"
-msgstr "プログラムのソース: t_get_seals.c"
+msgstr "プログラムのソース: svshm_string_write.c"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:445
@@ -15017,20 +13919,11 @@ msgstr ""
 #: build/C/man2/shmop.2:449
 #, no-wrap
 msgid "/* svshm_string_write.c\n"
-msgstr ""
+msgstr "/* svshm_string_write.c\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:461
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "    int fd;\n"
-#| "    unsigned int seals;\n"
-#| "    char *addr;\n"
-#| "    char *name, *seals_arg;\n"
-#| "    ssize_t len;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char *argv[])\n"
@@ -15043,40 +13936,28 @@ msgstr ""
 "int\n"
 "main(int argc, char *argv[])\n"
 "{\n"
-"    int fd;\n"
-"    unsigned int seals;\n"
+"    int semid, shmid;\n"
+"    struct sembuf sop;\n"
 "    char *addr;\n"
-"    char *name, *seals_arg;\n"
-"    ssize_t len;\n"
+"    size_t len;\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:466
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (argc != 2) {\n"
-#| "        fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "    if (argc != 4) {\n"
 "        fprintf(stderr, \"Usage: %s shmid semid string\\en\", argv[0]);\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 msgstr ""
-"    if (argc != 2) {\n"
-"        fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n"
+"    if (argc != 4) {\n"
+"        fprintf(stderr, \"Usage: %s shmid semid string\\en\", argv[0]);\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:472
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    p = malloc(1000);\n"
-#| "    if (p == NULL) {\n"
-#| "        fprintf(stderr, \"malloc() failed\");\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "    len = strlen(argv[3]) + 1;  /* +1 to include trailing \\(aq\\e0\\(aq */\n"
 "    if (len E<gt> MEM_SIZE) {\n"
@@ -15084,33 +13965,27 @@ msgid ""
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 msgstr ""
-"    p = malloc(1000);\n"
-"    if (p == NULL) {\n"
-"        fprintf(stderr, \"malloc() failed\");\n"
+"    len = strlen(argv[3]) + 1;  /* +1 to include trailing \\(aq\\e0\\(aq */\n"
+"    if (len E<gt> MEM_SIZE) {\n"
+"        fprintf(stderr, \"String is too big!\\en\");\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:474
-#, fuzzy, no-wrap
-#| msgid "    /* Size the file as specified on the command line */\n"
+#, no-wrap
 msgid "    /* Get object IDs from command-line */\n"
-msgstr "    /* Size the file as specified on the command line */\n"
+msgstr "    /* Get object IDs from command-line */\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:477
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    name = argv[1];\n"
-#| "    len = atoi(argv[2]);\n"
-#| "    seals_arg = argv[3];\n"
+#, no-wrap
 msgid ""
 "    shmid = atoi(argv[1]);\n"
 "    semid = atoi(argv[2]);\n"
 msgstr ""
-"    name = argv[1];\n"
-"    len = atoi(argv[2]);\n"
-"    seals_arg = argv[3];\n"
+"    shmid = atoi(argv[1]);\n"
+"    semid = atoi(argv[2]);\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:480
@@ -15122,25 +13997,21 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/shmop.2:484
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    seals = fcntl(fd, F_GET_SEALS);\n"
-#| "    if (seals == -1)\n"
-#| "        errExit(\"fcntl\");\n"
+#, no-wrap
 msgid ""
 "    addr = shmat(shmid, NULL, 0);\n"
 "    if (addr == (void *) -1)\n"
 "        errExit(\"shmat\");\n"
 msgstr ""
-"    seals = fcntl(fd, F_GET_SEALS);\n"
-"    if (seals == -1)\n"
-"        errExit(\"fcntl\");\n"
+"    addr = shmat(shmid, NULL, 0);\n"
+"    if (addr == (void *) -1)\n"
+"        errExit(\"shmat\");\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:486
 #, no-wrap
 msgid "    memcpy(addr, argv[3], len);\n"
-msgstr ""
+msgstr "    memcpy(addr, argv[3], len);\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:488
@@ -15156,19 +14027,16 @@ msgid ""
 "    sop.sem_op = -1;\n"
 "    sop.sem_flg = 0;\n"
 msgstr ""
+"    sop.sem_num = 0;\n"
+"    sop.sem_op = -1;\n"
+"    sop.sem_flg = 0;\n"
 
 #. type: Plain text
 #: build/C/man2/shmop.2:508
-#, fuzzy
-#| msgid ""
-#| "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
-#| "B<shm_overview>(7), B<svipc>(7)"
 msgid ""
 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
 "B<shm_overview>(7), B<sysvipc>(7)"
-msgstr ""
-"B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
-"B<shm_overview>(7), B<svipc>(7)"
+msgstr "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), B<shm_overview>(7), B<sysvipc>(7)"
 
 #. type: TH
 #: build/C/man2/subpage_prot.2:30
@@ -15183,15 +14051,12 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/subpage_prot.2:37
-#, fuzzy, no-wrap
-#| msgid ""
-#| "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
-#| "B<                  uint32_t *>I<map>B<);>\n"
+#, no-wrap
 msgid ""
 "B<int subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
 "B<                  uint32_t *>I<map>B<);>\n"
 msgstr ""
-"B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
+"B<int subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
 "B<                  uint32_t *>I<map>B<);>\n"
 
 #. type: Plain text
@@ -15314,12 +14179,10 @@ msgstr "B<mprotect>(2), B<syscall>(2)"
 
 #. type: Plain text
 #: build/C/man2/subpage_prot.2:134
-#, fuzzy
-#| msgid "I<Documentation/vm/hugetlbpage.txt> in the Linux kernel source tree"
 msgid ""
 "I<Documentation/admin-guide/mm/hugetlbpage.rst> in the Linux kernel source "
 "tree"
-msgstr "Linux カーネルソースの I<Documentation/vm/hugetlbpage.txt>"
+msgstr "Linux カーネルソースの I<Documentation/admin-guide/vm/hugetlbpage.rst>"
 
 #. type: TH
 #: build/C/man2/sync_file_range.2:30
@@ -15589,16 +14452,10 @@ msgstr "ディスク領域不足である。"
 
 #. type: Plain text
 #: build/C/man2/sync_file_range.2:174
-#, fuzzy
-#| msgid ""
-#| "I<fd> refers to something other than a regular file, a block device, a "
-#| "directory, or a symbolic link."
 msgid ""
 "I<fd> refers to something other than a regular file, a block device, or a "
 "directory."
-msgstr ""
-"I<fd> が、通常のファイル、ブロックデバイス、ディレクトリ、シンボリックリンク "
-"以外のものを指している。"
+msgstr "I<fd> が、通常のファイル、ブロックデバイス、ディレクトリ以外のものを指している。"
 
 #. type: Plain text
 #: build/C/man2/sync_file_range.2:177
@@ -15693,10 +14550,9 @@ msgstr "memfd_create - 無名ファイル (anonymous file) を作成する"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:30
-#, fuzzy, no-wrap
-#| msgid "B<int memfd_create(const char *>I<name>B<, unsigned int >I<flags>B<);>"
+#, no-wrap
 msgid "B<int memfd_create(const char *>I<name>B<, unsigned int >I<flags>B<);>\n"
-msgstr "B<int memfd_create(const char *>I<name>B<, unsigned int >I<flags>B<);>"
+msgstr "B<int memfd_create(const char *>I<name>B<, unsigned int >I<flags>B<);>\n"
 
 #.  David Herrmann:
 #.      memfd uses VM_NORESERVE so each page is accounted on first access.
@@ -15756,10 +14612,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:77
-#, fuzzy
-#| msgid ""
-#| "The following values may be bitwise ORed in I<flags> to change the "
-#| "behaviour of B<memfd_create>():"
 msgid ""
 "The following values may be bitwise ORed in I<flags> to change the behavior "
 "of B<memfd_create>():"
@@ -15809,10 +14661,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/memfd_create.2:103
-#, fuzzy, no-wrap
-#| msgid "B<SHM_HUGETLB> (since Linux 2.6)"
+#, no-wrap
 msgid "B<MFD_HUGETLB> (since Linux 4.14)"
-msgstr "B<SHM_HUGETLB> (Linux 2.6 以降)"
+msgstr "B<MFD_HUGETLB> (Linux 4.14 以降)"
 
 #.  commit 749df87bd7bee5a79cef073f5d032ddb2b211de8
 #.  commit 47b9012ecdc747f6936395265e677d41e11a31ff
@@ -15830,7 +14681,7 @@ msgstr ""
 #: build/C/man2/memfd_create.2:119
 #, no-wrap
 msgid "B<MFD_HUGE_2MB>, B<MFD_HUGE_1GB>, B<...>"
-msgstr ""
+msgstr "B<MFD_HUGE_2MB>, B<MFD_HUGE_1GB>, B<...>"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:128
@@ -15855,12 +14706,6 @@ msgstr "I<flags> の未使用のビットは 0 でなければならない。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:145
-#, fuzzy
-#| msgid ""
-#| "As its return value, B<memfd_create>()  returns a new file descriptor "
-#| "that can be used to refer to the file.  This file descriptor is opened "
-#| "for both reading and writing (B<O_RDWR>)  and B<O_LARGEFILE> is set for "
-#| "the descriptor."
 msgid ""
 "As its return value, B<memfd_create>()  returns a new file descriptor that "
 "can be used to refer to the file.  This file descriptor is opened for both "
@@ -15927,16 +14772,10 @@ msgstr "新しい無名ファイルを作成するのに十分なメモリーが
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:204
-#, fuzzy
-#| msgid ""
-#| "The B<remap_file_pages>()  system call appeared in Linux 2.5.46; glibc "
-#| "support was added in version 2.3.3."
 msgid ""
 "The B<memfd_create>()  system call first appeared in Linux 3.17; glibc "
 "support was added in version 2.27."
-msgstr ""
-"B<remap_file_pages>()  システムコールは Linux 2.5.46 で登場した。 glibc での"
-"サポートは glibc バージョン 2.3.3 で追加された。"
+msgstr "B<memfd_create>() システムコールは Linux 3.17 で登場した。 glibc でのサポートは glibc バージョン 2.27 で追加された。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:208
@@ -15947,25 +14786,13 @@ msgstr "B<memfd_create>()  システムコールは Linux 固有である。"
 #.  and http://lwn.net/Articles/594919/ and http://lwn.net/Articles/591108/
 #. type: Plain text
 #: build/C/man2/memfd_create.2:221
-#, fuzzy
-#| msgid ""
-#| "The B<memfd_create>()  system call provides a simple alternative to "
-#| "manually mounting a I<tmpfs> filesystem and creating and opening a file "
-#| "in that filesystem.  The primary purpose of B<memfd_create>()  is to "
-#| "create files and associated file descriptors that are used with the file-"
-#| "sealing APIs provided by B<fcntl>(2)."
 msgid ""
 "The B<memfd_create>()  system call provides a simple alternative to manually "
 "mounting a B<tmpfs>(5)  filesystem and creating and opening a file in that "
 "filesystem.  The primary purpose of B<memfd_create>()  is to create files "
 "and associated file descriptors that are used with the file-sealing APIs "
 "provided by B<fcntl>(2)."
-msgstr ""
-"B<memfd_create>() システムコールは、 手動で I<tmpfs> ファイルシステムをマウン"
-"トして、 そのファイルシステムにファイルをオープンするという操作の、 簡単な代"
-"替手段を提供している。 B<memfd_create>() の主な目的は、 B<fcntl>(2) が提供す"
-"る file-sealing API で使用できる、 ファイルとそれに関連付けられるファイルディ"
-"スクリプターを作成することである。"
+msgstr "B<memfd_create>() システムコールは、 手動で B<tmpfs>(5) ファイルシステムをマウントして、 そのファイルシステムにファイルをオープンするという操作の、 簡単な代替手段を提供している。 B<memfd_create>() の主な目的は、 B<fcntl>(2) が提供する file-sealing API で使用できる、 ファイルとそれに関連付けられるファイルディスクリプターを作成することである。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:235
@@ -16037,17 +14864,10 @@ msgstr "sealing 機構の使い方の例は以下のとおりである。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:267
-#, fuzzy
-#| msgid ""
-#| "The first process creates a I<tmpfs> file using B<memfd_create>().  The "
-#| "call yields a file descriptor used in subsequent steps."
 msgid ""
 "The first process creates a B<tmpfs>(5)  file using B<memfd_create>().  The "
 "call yields a file descriptor used in subsequent steps."
-msgstr ""
-"最初のプロセスは B<memfd_create>() を使って I<tmpfs> ファイルを作成する。 "
-"B<memfd_create>() はこれ以降のステップで使用するファイルディスクリプターを返"
-"す。"
+msgstr "最初のプロセスは B<memfd_create>() を使って B<tmpfs>(5) ファイルを作成する。 B<memfd_create>() はこれ以降のステップで使用するファイルディスクリプターを返す。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:274
@@ -16098,17 +14918,11 @@ msgstr "4."
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:298
-#, fuzzy
-#| msgid ""
-#| "A second process obtains a file descriptor for the I<tmpfs> file and maps "
-#| "it.  Among the possible ways in which this could happen are the following:"
 msgid ""
 "A second process obtains a file descriptor for the B<tmpfs>(5)  file and "
 "maps it.  Among the possible ways in which this could happen are the "
 "following:"
-msgstr ""
-"二つ目のプロセスは I<tmpfs> ファイルのファイルディスクリプターを入手し、 その"
-"ファイルをマップする。 以下に示す方法を使用することができる。"
+msgstr "二つ目のプロセスは B<tmpfs>(5) ファイルのファイルディスクリプターを入手し、 そのファイルをマップする。 以下に示す方法を使用することができる。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:309
@@ -16139,25 +14953,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:331
-#, fuzzy
-#| msgid ""
-#| "The second process opens the file I</proc/E<lt>pdE<gt>/fd/E<lt>fdE<gt>>, "
-#| "where I<E<lt>pidE<gt>> is the PID of the first process (the one that "
-#| "called B<memfd_create>()), and I<E<lt>fdE<gt>> is the number of the file "
-#| "descriptor returned by the call to B<memfd_create>()  in that process.  "
-#| "The second process then maps the file using B<mmap>(2)."
 msgid ""
 "The second process opens the file I</proc/E<lt>pidE<gt>/fd/E<lt>fdE<gt>>, "
 "where I<E<lt>pidE<gt>> is the PID of the first process (the one that called "
 "B<memfd_create>()), and I<E<lt>fdE<gt>> is the number of the file descriptor "
 "returned by the call to B<memfd_create>()  in that process.  The second "
 "process then maps the file using B<mmap>(2)."
-msgstr ""
-"二つ目のプロセスは I</proc/E<lt>pdE<gt>/fd/E<lt>fdE<gt>> をオープンする。 "
-"I<E<lt>pidE<gt>> は最初のプロセス (B<memfd_create>() を呼び出したプロセス) "
-"の PID で、 I<E<lt>fdE<gt>> は最初のプロセスでの B<memfd_create>() の呼び出し"
-"で返されたファイルディスクリプター番号である。 それからこのファイルを "
-"B<mmap>(2) を使ってマッピングする。"
+msgstr "二つ目のプロセスは I</proc/E<lt>pidE<gt>/fd/E<lt>fdE<gt>> をオープンする。 I<E<lt>pidE<gt>> は最初のプロセス (B<memfd_create>() を呼び出したプロセス) の PID で、 I<E<lt>fdE<gt>> は最初のプロセスでの B<memfd_create>() の呼び出しで返されたファイルディスクリプター番号である。 それからこのファイルを B<mmap>(2) を使ってマッピングする。"
 
 #. type: IP
 #: build/C/man2/memfd_create.2:332
@@ -16192,15 +14994,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:363
-#, fuzzy
-#| msgid ""
-#| "The first program, I<t_memfd_create.c>, creates a I<tmpfs> file using "
-#| "B<memfd_create>(), sets a size for the file, maps it into memory, and "
-#| "optionally places some seals on the file.  The program accepts up to "
-#| "three command-line arguments, of which the first two are required.  The "
-#| "first argument is the name to associate with the file, the second "
-#| "argument is the size to be set for the file, and the optional third is a "
-#| "string of characters that specify seals to be set on file."
 msgid ""
 "The first program, I<t_memfd_create.c>, creates a B<tmpfs>(5)  file using "
 "B<memfd_create>(), sets a size for the file, maps it into memory, and "
@@ -16209,14 +15002,7 @@ msgid ""
 "argument is the name to associate with the file, the second argument is the "
 "size to be set for the file, and the optional third argument is a string of "
 "characters that specify seals to be set on file."
-msgstr ""
-"最初のプログラム I<t_memfd_create.c> は、 B<memfd_create>() を使って "
-"I<tmpfs> ファイルを作成し、 そのファイルのサイズを設定し、 メモリーにマッピン"
-"グし、 要求された場合にはそのファイルに seal を設定する。 このプログラムは最"
-"大で 3 つのコマンドライン引き数を取り、 最初の 2 つは必須である。 最初の引き"
-"数はファイルに関連付けられる名前で、 2 番目の引き数はファイルに設定されるサイ"
-"ズである。 省略可能な 3 番目の引き数は、 このファイルに設定する seal を指定す"
-"る文字列である。"
+msgstr "最初のプログラム I<t_memfd_create.c> は、 B<memfd_create>() を使って B<tmpfs>(5) ファイルを作成し、 そのファイルのサイズを設定し、 メモリーにマッピングし、 要求された場合にはそのファイルに seal を設定する。 このプログラムは最大で 3 つのコマンドライン引き数を取り、 最初の 2 つは必須である。 最初の引き数はファイルに関連付けられる名前で、 2 番目の引き数はファイルに設定されるサイズである。 省略可能な 3 番目の引き数は、 このファイルに設定する seal を指定する文字列である。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:369
@@ -16231,16 +15017,10 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:374
-#, fuzzy
-#| msgid ""
-#| "The following shell session demonstrates the use of these programs.  "
-#| "First we create a I<tmpfs> file and set some seals on it:"
 msgid ""
 "The following shell session demonstrates the use of these programs.  First "
 "we create a B<tmpfs>(5)  file and set some seals on it:"
-msgstr ""
-"以下のシェルのセッションはこれらのプログラムの使用例を示したものである。 ま"
-"ず I<tmpfs> ファイルを作成し、そのファイルに seal をいくつか設定している。"
+msgstr "以下のシェルのセッションはこれらのプログラムの使用例を示したものである。 まず B<tmpfs>(5) ファイルを作成し、そのファイルに seal をいくつか設定している。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:380
@@ -16256,15 +15036,6 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:398
-#, fuzzy
-#| msgid ""
-#| "At this point, the I<t_memfd_create> program continues to run in the "
-#| "background.  From another program, we can obtain a file descriptor for "
-#| "the file created by B<memfd_create>()  by opening the I</proc/PID/fd> "
-#| "file that corresponds to the descriptor opened by B<memfd_create>().  "
-#| "Using that pathname, we inspect the content of the I</proc/PID/fd> "
-#| "symbolic link, and use our I<t_get_seals> program to view the seals that "
-#| "have been placed on the file:"
 msgid ""
 "At this point, the I<t_memfd_create> program continues to run in the "
 "background.  From another program, we can obtain a file descriptor for the "
@@ -16273,15 +15044,7 @@ msgid ""
 "that pathname, we inspect the content of the I</proc/[pid]/fd> symbolic "
 "link, and use our I<t_get_seals> program to view the seals that have been "
 "placed on the file:"
-msgstr ""
-"この時点では、 I<t_memfd_create> プログラムはバックグラウンドで動作し続け"
-"る。 もう一つのプログラムから、 B<memfd_create>() がオープンしたディスクリプ"
-"ターに対応する I</proc/PID/fd> ファイルをオープンすることで、 "
-"B<memfd_create>() で作成されたファイルのファイルディスクリプターを取得でき"
-"る。\n"
-"そのパス名を使って、 I</proc/PID/fd> シンボリックリンクの内容を調査し、 "
-"I<t_get_seals> プログラムを使ってそのファイルに設定されている seal を見ること"
-"ができる。"
+msgstr "この時点では、 I<t_memfd_create> プログラムはバックグラウンドで動作し続ける。 もう一つのプログラムから、 B<memfd_create>() がオープンしたファイルディスクリプターに対応する I</proc/[pid]/fd> ファイルをオープンすることで、 B<memfd_create>() で作成されたファイルのファイルディスクリプターを取得できる。そのパス名を使って、 I</proc/[pid]/fd> シンボリックリンクの内容を調査し、 I<t_get_seals> プログラムを使ってそのファイルに設定されている seal を見ることができる。"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:405
@@ -16305,14 +15068,7 @@ msgstr "プログラムのソース: t_memfd_create.c"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:418
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>sys/memfd.hE<gt>\n"
-#| "#include E<lt>fcntl.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
-#| "#include E<lt>unistd.hE<gt>\n"
-#| "#include E<lt>string.hE<gt>\n"
-#| "#include E<lt>stdio.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#define _GNU_SOURCE\n"
 "#include E<lt>stdint.hE<gt>\n"
@@ -16323,7 +15079,9 @@ msgid ""
 "#include E<lt>string.hE<gt>\n"
 "#include E<lt>stdio.hE<gt>\n"
 msgstr ""
-"#include E<lt>sys/memfd.hE<gt>\n"
+"#define _GNU_SOURCE\n"
+"#include E<lt>stdint.hE<gt>\n"
+"#include E<lt>sys/mman.hE<gt>\n"
 "#include E<lt>fcntl.hE<gt>\n"
 "#include E<lt>stdlib.hE<gt>\n"
 "#include E<lt>unistd.hE<gt>\n"
@@ -16354,18 +15112,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:442
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    if (argc E<lt> 3) {\n"
-#| "        fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n"
-#| "        fprintf(stderr, \"\\et\\(aqseals\\(aq can contain any of the \"\n"
-#| "                \"following characters:\\en\");\n"
-#| "        fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n"
-#| "        fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n"
-#| "        fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n"
-#| "        fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "    if (argc E<lt> 3) {\n"
 "        fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n"
@@ -16386,6 +15133,7 @@ msgstr ""
 "        fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n"
 "        fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n"
 "        fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n"
+"        fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n"
 "        fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n"
 "        exit(EXIT_FAILURE);\n"
 "    }\n"
@@ -16442,16 +15190,13 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:461
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    printf(\"PID: %ld; fd: %d; /proc/%ld/fd/%d\\en\",\n"
-#| "            (long) getpid(), fd, (long) getpid(), fd);\n"
+#, no-wrap
 msgid ""
 "    printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n"
 "            (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n"
 msgstr ""
-"    printf(\"PID: %ld; fd: %d; /proc/%ld/fd/%d\\en\",\n"
-"            (long) getpid(), fd, (long) getpid(), fd);\n"
+"    printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n"
+"            (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:464
@@ -16485,16 +15230,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:481
-#, fuzzy, no-wrap
-#| msgid ""
-#| "        if (strchr(seals_arg, \\(aqg\\(aq) != NULL)\n"
-#| "            seals |= F_SEAL_GROW;\n"
-#| "        if (strchr(seals_arg, \\(aqs\\(aq) != NULL)\n"
-#| "            seals |= F_SEAL_SHRINK;\n"
-#| "        if (strchr(seals_arg, \\(aqw\\(aq) != NULL)\n"
-#| "            seals |= F_SEAL_WRITE;\n"
-#| "        if (strchr(seals_arg, \\(aqS\\(aq) != NULL)\n"
-#| "            seals |= F_SEAL_SEAL;\n"
+#, no-wrap
 msgid ""
 "        if (strchr(seals_arg, \\(aqg\\(aq) != NULL)\n"
 "            seals |= F_SEAL_GROW;\n"
@@ -16513,6 +15249,8 @@ msgstr ""
 "            seals |= F_SEAL_SHRINK;\n"
 "        if (strchr(seals_arg, \\(aqw\\(aq) != NULL)\n"
 "            seals |= F_SEAL_WRITE;\n"
+"        if (strchr(seals_arg, \\(aqW\\(aq) != NULL)\n"
+"            seals |= F_SEAL_FUTURE_WRITE;\n"
 "        if (strchr(seals_arg, \\(aqS\\(aq) != NULL)\n"
 "            seals |= F_SEAL_SEAL;\n"
 
@@ -16552,14 +15290,7 @@ msgstr "プログラムのソース: t_get_seals.c"
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:504
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>sys/memfd.hE<gt>\n"
-#| "#include E<lt>fcntl.hE<gt>\n"
-#| "#include E<lt>unistd.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
-#| "#include E<lt>string.hE<gt>\n"
-#| "#include E<lt>stdio.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#define _GNU_SOURCE\n"
 "#include E<lt>sys/mman.hE<gt>\n"
@@ -16569,7 +15300,8 @@ msgid ""
 "#include E<lt>string.hE<gt>\n"
 "#include E<lt>stdio.hE<gt>\n"
 msgstr ""
-"#include E<lt>sys/memfd.hE<gt>\n"
+"#define _GNU_SOURCE\n"
+"#include E<lt>sys/mman.hE<gt>\n"
 "#include E<lt>fcntl.hE<gt>\n"
 "#include E<lt>unistd.hE<gt>\n"
 "#include E<lt>stdlib.hE<gt>\n"
@@ -16632,18 +15364,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/memfd_create.2:539
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    printf(\"Existing seals:\");\n"
-#| "    if (seals & F_SEAL_SEAL)\n"
-#| "        printf(\" SEAL\");\n"
-#| "    if (seals & F_SEAL_GROW)\n"
-#| "        printf(\" GROW\");\n"
-#| "    if (seals & F_SEAL_WRITE)\n"
-#| "        printf(\" WRITE\");\n"
-#| "    if (seals & F_SEAL_SHRINK)\n"
-#| "        printf(\" SHRINK\");\n"
-#| "    printf(\"\\en\");\n"
+#, no-wrap
 msgid ""
 "    printf(\"Existing seals:\");\n"
 "    if (seals & F_SEAL_SEAL)\n"
@@ -16665,6 +15386,8 @@ msgstr ""
 "        printf(\" GROW\");\n"
 "    if (seals & F_SEAL_WRITE)\n"
 "        printf(\" WRITE\");\n"
+"    if (seals & F_SEAL_FUTURE_WRITE)\n"
+"        printf(\" FUTURE_WRITE\");\n"
 "    if (seals & F_SEAL_SHRINK)\n"
 "        printf(\" SHRINK\");\n"
 "    printf(\"\\en\");\n"
@@ -16705,10 +15428,7 @@ msgstr "B<#include E<lt>asm/unistd.hE<gt>>\n"
 
 #. type: Plain text
 #: build/C/man2/s390_pci_mmio_write.2:37
-#, fuzzy, no-wrap
-#| msgid ""
-#| "B<int s390_pci_mmio_write(unsigned long >I<mmio_addr>B<,>\n"
-#| "B<                        void *>I<user_buffer>B<, size_t >I<length>B<);>\n"
+#, no-wrap
 msgid ""
 "B<int s390_pci_mmio_write(unsigned long >I<mmio_addr>B<,>\n"
 "B<                        void *>I<user_buffer>B<, size_t >I<length>B<);>\n"
@@ -16717,6 +15437,8 @@ msgid ""
 msgstr ""
 "B<int s390_pci_mmio_write(unsigned long >I<mmio_addr>B<,>\n"
 "B<                        void *>I<user_buffer>B<, size_t >I<length>B<);>\n"
+"B<int s390_pci_mmio_read(unsigned long >I<mmio_addr>B<,>\n"
+"B<                        void *>I<user_buffer>B<, size_t >I<length>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/s390_pci_mmio_write.2:56
@@ -16814,17 +15536,15 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:32
-#, fuzzy, no-wrap
-#| msgid "B<#include E<lt>sys/mman.hE<gt>>\n"
+#, no-wrap
 msgid "B<#include E<lt>linux/membarrier.hE<gt>>\n"
-msgstr "B<#include E<lt>sys/mman.hE<gt>>\n"
+msgstr "B<#include E<lt>linux/membarrier.hE<gt>>\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:34
-#, fuzzy, no-wrap
-#| msgid "B<int memfd_create(const char *>I<name>B<, unsigned int >I<flags>B<);>"
+#, no-wrap
 msgid "B<int membarrier(int >I<cmd>B<, unsigned int >I<flags>B<, int >I<cpu_id>B<);>\n"
-msgstr "B<int memfd_create(const char *>I<name>B<, unsigned int >I<flags>B<);>"
+msgstr "B<int membarrier(int >I<cmd>B<, unsigned int >I<flags>B<, int >I<cpu_id>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:48
@@ -16859,7 +15579,7 @@ msgstr ""
 #: build/C/man2/membarrier.2:66
 #, no-wrap
 msgid "asm volatile (\"\" : : : \"memory\")\n"
-msgstr ""
+msgstr "asm volatile (\"\" : : : \"memory\")\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:71
@@ -16877,18 +15597,14 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:81
-#, fuzzy
-#| msgid ""
-#| "The I<flags> bit-mask argument can include any of the following values:"
 msgid "The I<cmd> argument is one of the following:"
-msgstr "ビットマスク引き数 I<flags> には以下の値を指定することができる:"
+msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:81
-#, fuzzy, no-wrap
-#| msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_QUERY> (since Linux 4.3)"
-msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
+msgstr "B<MEMBARRIER_CMD_QUERY> (Linux 4.3 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:92
@@ -16901,10 +15617,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:92
-#, fuzzy, no-wrap
-#| msgid "B<MADV_REMOVE> (since Linux 2.6.16)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_GLOBAL> (since Linux 4.16)"
-msgstr "B<MADV_REMOVE> (Linux 2.6.16 以降)"
+msgstr "B<MEMBARRIER_CMD_GLOBAL> (Linux 4.16 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:100
@@ -16917,10 +15632,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:100
-#, fuzzy, no-wrap
-#| msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> (since Linux 4.16)"
-msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
+msgstr "B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> (Linux 4.16 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:105
@@ -16957,10 +15671,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:122
-#, fuzzy, no-wrap
-#| msgid "B<MADV_SOFT_OFFLINE> (since Linux 2.6.33)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED> (since Linux 4.16)"
-msgstr "B<MADV_SOFT_OFFLINE> (Linux 2.6.33 以降)"
+msgstr "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED> (Linux 4.16 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:127
@@ -16971,10 +15684,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:127
-#, fuzzy, no-wrap
-#| msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED> (since Linux 4.14)"
-msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
+msgstr "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED> (Linux 4.14 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:131
@@ -17005,7 +15717,7 @@ msgstr ""
 #: build/C/man2/membarrier.2:145
 #, no-wrap
 msgid "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED> (since Linux 4.14)"
-msgstr ""
+msgstr "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED> (Linux 4.14 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:149
@@ -17017,7 +15729,7 @@ msgstr ""
 #: build/C/man2/membarrier.2:149
 #, no-wrap
 msgid "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> (since Linux 4.16)"
-msgstr ""
+msgstr "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> (Linux 4.16 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:157
@@ -17047,7 +15759,7 @@ msgstr ""
 #: build/C/man2/membarrier.2:163
 #, no-wrap
 msgid "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> (since Linux 4.16)"
-msgstr ""
+msgstr "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> (Linux 4.16 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:167
@@ -17058,10 +15770,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:167
-#, fuzzy, no-wrap
-#| msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ> (since Linux 5.10)"
-msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
+msgstr "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ> (Linux 5.10 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:181
@@ -17090,7 +15801,7 @@ msgstr ""
 #: build/C/man2/membarrier.2:186
 #, no-wrap
 msgid "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_RSEQ> (since Linux 5.10)"
-msgstr ""
+msgstr "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_RSEQ> (Linux 5.10 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:190
@@ -17101,10 +15812,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/membarrier.2:190
-#, fuzzy, no-wrap
-#| msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
+#, no-wrap
 msgid "B<MEMBARRIER_CMD_SHARED> (since Linux 4.3)"
-msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
+msgstr "B<MEMBARRIER_CMD_SHARED> (Linux 4.3 以降)"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:195
@@ -17156,6 +15866,10 @@ msgid ""
 "       smp_mb()           X          O          O\n"
 "       membarrier()       O          O          O\n"
 msgstr ""
+"                       barrier()  smp_mb()  membarrier()\n"
+"       barrier()          X          X          O\n"
+"       smp_mb()           X          O          O\n"
+"       membarrier()       O          O          O\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:253
@@ -17192,10 +15906,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:283
-#, fuzzy
-#| msgid "The system call is not supported on this kernel."
 msgid "The B<membarrier>()  system call is not implemented by this kernel."
-msgstr "ã\81\93ã\81®ã\82·ã\82¹ã\83\86ã\83 ã\82³ã\83¼ã\83«ã\81¯カーネルでサポートされていない。"
+msgstr "ã\82·ã\82¹ã\83\86ã\83 ã\82³ã\83¼ã\83« B<membarrier>() ã\81¯ã\81\93ã\81®カーネルでサポートされていない。"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:287
@@ -17206,10 +15918,8 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:291
-#, fuzzy
-#| msgid "The B<memfd_create>()  system call is Linux-specific."
 msgid "The B<membarrier>()  system call was added in Linux 4.3."
-msgstr "B<memfd_create>()  システムコールは Linux 固有である。"
+msgstr "B<membarrier>() システムコールは Linux 4.3 で追加された。"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:295
@@ -17218,10 +15928,9 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:299
-#, fuzzy, no-wrap
-#| msgid "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
+#, no-wrap
 msgid "B<int membarrier(int >I<cmd>B<, int >I<flags>B<);>\n"
-msgstr "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
+msgstr "B<int membarrier(int >I<cmd>B<, int >I<flags>B<);>\n"
 
 #.  .SH SEE ALSO
 #.  FIXME See if the following syscalls make it into Linux 4.15 or later
@@ -17229,10 +15938,8 @@ msgstr "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
 #.  .BR rseq (2)
 #. type: Plain text
 #: build/C/man2/membarrier.2:308
-#, fuzzy
-#| msgid "B<fallocate>()  is Linux-specific."
 msgid "B<membarrier>()  is Linux-specific."
-msgstr "B<fallocate>()  は Linux 固有である。"
+msgstr "B<membarrier>() は Linux 固有である。"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:317
@@ -17268,16 +15975,15 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:337
-#, fuzzy, no-wrap
-#| msgid "B<#include E<lt>stdlib.hE<gt>>\n"
+#, no-wrap
 msgid "#include E<lt>stdlib.hE<gt>\n"
-msgstr "B<#include E<lt>stdlib.hE<gt>>\n"
+msgstr "#include E<lt>stdlib.hE<gt>\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:339 build/C/man2/membarrier.2:397
 #, no-wrap
 msgid "static volatile int a, b;\n"
-msgstr ""
+msgstr "static volatile int a, b;\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:347
@@ -17291,6 +15997,13 @@ msgid ""
 "    *read_b = b;\n"
 "}\n"
 msgstr ""
+"static void\n"
+"fast_path(int *read_b)\n"
+"{\n"
+"    a = 1;\n"
+"    asm volatile (\"mfence\" : : : \"memory\");\n"
+"    *read_b = b;\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:355
@@ -17304,15 +16017,17 @@ msgid ""
 "    *read_a = a;\n"
 "}\n"
 msgstr ""
+"static void\n"
+"slow_path(int *read_a)\n"
+"{\n"
+"    b = 1;\n"
+"    asm volatile (\"mfence\" : : : \"memory\");\n"
+"    *read_a = a;\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:360 build/C/man2/membarrier.2:446
-#, fuzzy, no-wrap
-#| msgid ""
-#| "int\n"
-#| "main(int argc, char *argv[])\n"
-#| "{\n"
-#| "    int j;\n"
+#, no-wrap
 msgid ""
 "int\n"
 "main(int argc, char **argv)\n"
@@ -17320,9 +16035,9 @@ msgid ""
 "    int read_a, read_b;\n"
 msgstr ""
 "int\n"
-"main(int argc, char *argv[])\n"
+"main(int argc, char **argv)\n"
 "{\n"
-"    int j;\n"
+"    int read_a, read_b;\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:366 build/C/man2/membarrier.2:455
@@ -17342,6 +16057,8 @@ msgid ""
 "    slow_path(&read_a);\n"
 "    fast_path(&read_b);\n"
 msgstr ""
+"    slow_path(&read_a);\n"
+"    fast_path(&read_b);\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:374 build/C/man2/membarrier.2:463
@@ -17360,6 +16077,8 @@ msgid ""
 "    if (read_b == 0 && read_a == 0)\n"
 "        abort();\n"
 msgstr ""
+"    if (read_b == 0 && read_a == 0)\n"
+"        abort();\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:386
@@ -17368,13 +16087,7 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:395
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>unistd.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
-#| "#include E<lt>pthread.hE<gt>\n"
-#| "#include E<lt>malloc.hE<gt>\n"
-#| "#include E<lt>errno.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#define _GNU_SOURCE\n"
 "#include E<lt>stdlib.hE<gt>\n"
@@ -17383,11 +16096,12 @@ msgid ""
 "#include E<lt>sys/syscall.hE<gt>\n"
 "#include E<lt>linux/membarrier.hE<gt>\n"
 msgstr ""
-"#include E<lt>unistd.hE<gt>\n"
+"#define _GNU_SOURCE\n"
 "#include E<lt>stdlib.hE<gt>\n"
-"#include E<lt>pthread.hE<gt>\n"
-"#include E<lt>malloc.hE<gt>\n"
-"#include E<lt>errno.hE<gt>\n"
+"#include E<lt>stdio.hE<gt>\n"
+"#include E<lt>unistd.hE<gt>\n"
+"#include E<lt>sys/syscall.hE<gt>\n"
+"#include E<lt>linux/membarrier.hE<gt>\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:403
@@ -17399,6 +16113,11 @@ msgid ""
 "    return syscall(__NR_membarrier, cmd, flags, cpu_id);\n"
 "}\n"
 msgstr ""
+"static int\n"
+"membarrier(int cmd, unsigned int flags, int cpu_id)\n"
+"{\n"
+"    return syscall(__NR_membarrier, cmd, flags, cpu_id);\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:408
@@ -17409,6 +16128,10 @@ msgid ""
 "{\n"
 "    int ret;\n"
 msgstr ""
+"static int\n"
+"init_membarrier(void)\n"
+"{\n"
+"    int ret;\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:410
@@ -17426,6 +16149,11 @@ msgid ""
 "        return -1;\n"
 "    }\n"
 msgstr ""
+"    ret = membarrier(MEMBARRIER_CMD_QUERY, 0, 0);\n"
+"    if (ret E<lt> 0) {\n"
+"        perror(\"membarrier\");\n"
+"        return -1;\n"
+"    }\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:422
@@ -17437,18 +16165,20 @@ msgid ""
 "        return -1;\n"
 "    }\n"
 msgstr ""
+"    if (!(ret & MEMBARRIER_CMD_GLOBAL)) {\n"
+"        fprintf(stderr,\n"
+"            \"membarrier does not support MEMBARRIER_CMD_GLOBAL\\en\");\n"
+"        return -1;\n"
+"    }\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:425
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    return result;\n"
-#| "}\n"
+#, no-wrap
 msgid ""
 "    return 0;\n"
 "}\n"
 msgstr ""
-"    return result;\n"
+"    return 0;\n"
 "}\n"
 
 #. type: Plain text
@@ -17463,6 +16193,13 @@ msgid ""
 "    *read_b = b;\n"
 "}\n"
 msgstr ""
+"static void\n"
+"fast_path(int *read_b)\n"
+"{\n"
+"    a = 1;\n"
+"    asm volatile (\"\" : : : \"memory\");\n"
+"    *read_b = b;\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:441
@@ -17476,28 +16213,29 @@ msgid ""
 "    *read_a = a;\n"
 "}\n"
 msgstr ""
+"static void\n"
+"slow_path(int *read_a)\n"
+"{\n"
+"    b = 1;\n"
+"    membarrier(MEMBARRIER_CMD_GLOBAL, 0, 0);\n"
+"    *read_a = a;\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man2/membarrier.2:449
-#, fuzzy, no-wrap
-#| msgid ""
-#| "        fprintf(stderr, \"partial write\");\n"
-#| "        exit(EXIT_FAILURE);\n"
-#| "    }\n"
+#, no-wrap
 msgid ""
 "    if (init_membarrier())\n"
 "        exit(EXIT_FAILURE);\n"
 msgstr ""
-"        fprintf(stderr, \"partial write\");\n"
+"    if (init_membarrier())\n"
 "        exit(EXIT_FAILURE);\n"
-"    }\n"
 
 #. type: TH
 #: build/C/man2/pkey_alloc.2:25
-#, fuzzy, no-wrap
-#| msgid "ALLOCA"
+#, no-wrap
 msgid "PKEY_ALLOC"
-msgstr "ALLOCA"
+msgstr "PKEY_ALLOC"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:28
@@ -17511,6 +16249,8 @@ msgid ""
 "B<int pkey_alloc(unsigned int >I<flags>B<, unsigned int >I<access_rights>B<);>\n"
 "B<int pkey_free(int >I<pkey>B<);>\n"
 msgstr ""
+"B<int pkey_alloc(unsigned int >I<flags>B<, unsigned int >I<access_rights>B<);>\n"
+"B<int pkey_free(int >I<pkey>B<);>\n"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:40
@@ -17537,7 +16277,7 @@ msgstr ""
 #: build/C/man2/pkey_alloc.2:50
 #, no-wrap
 msgid "B<PKEY_DISABLE_ACCESS>"
-msgstr ""
+msgstr "B<PKEY_DISABLE_ACCESS>"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:53
@@ -17547,10 +16287,9 @@ msgstr ""
 
 #. type: TP
 #: build/C/man2/pkey_alloc.2:53
-#, fuzzy, no-wrap
-#| msgid "B<MAP_DENYWRITE>"
+#, no-wrap
 msgid "B<PKEY_DISABLE_WRITE>"
-msgstr "B<MAP_DENYWRITE>"
+msgstr "B<PKEY_DISABLE_WRITE>"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:56
@@ -17576,26 +16315,16 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:80
-#, fuzzy
-#| msgid ""
-#| "On success, B<alloc_hugepages>()  returns the allocated virtual address, "
-#| "and B<free_hugepages>()  returns zero.  On error, -1 is returned, and "
-#| "I<errno> is set appropriately."
 msgid ""
 "On success, B<pkey_alloc>()  returns a positive protection key value.  On "
 "success, B<pkey_free>()  returns zero.  On error, -1 is returned, and "
 "I<errno> is set appropriately."
 msgstr ""
-"成功した場合、 B<alloc_hugepages>()  は割り当てられた仮想アドレスを返し、 "
-"B<free_hugepages>()  は 0 を返す。 失敗した場合、-1 を返し、 I<errno> が適切"
-"に設定される。"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:88
-#, fuzzy
-#| msgid "I<addr>, I<size>, I<prot>, or I<pgoff> is invalid."
 msgid "I<pkey>, I<flags>, or I<access_rights> is invalid."
-msgstr "I<addr>, I<size>, I<prot>, I<pgoff> のいずれかが不正である。"
+msgstr "I<pkey>, I<flags>, I<access_rights> のいずれかが無効である。"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:97
@@ -17624,11 +16353,9 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:115
-#, fuzzy
-#| msgid "The B<memfd_create>()  system call is Linux-specific."
 msgid ""
 "The B<pkey_alloc>()  and B<pkey_free>()  system calls are Linux-specific."
-msgstr "B<memfd_create>()  システムコールは Linux 固有である。"
+msgstr "システムコール B<pkey_alloc>() と B<pkey_free>() は Linux 固有である。"
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:123
@@ -17657,16 +16384,14 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man2/pkey_alloc.2:140
-#, fuzzy
-#| msgid "B<mprotect>(2), B<syscall>(2)"
 msgid "B<pkey_mprotect>(2), B<pkeys>(7)"
-msgstr "B<mprotect>(2), B<syscall>(2)"
+msgstr "B<pkey_mprotect>(2), B<pkeys>(7)"
 
 #. type: TH
 #: build/C/man7/pkeys.7:25
 #, no-wrap
 msgid "PKEYS"
-msgstr ""
+msgstr "PKEYS"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:28
@@ -17850,16 +16575,14 @@ msgid ""
 "about to read buffer again...\n"
 "Segmentation fault (core dumped)\n"
 msgstr ""
+"$B< ./a.out>\n"
+"buffer contains: 73\n"
+"about to read buffer again...\n"
+"Segmentation fault (core dumped)\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:191
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#include E<lt>unistd.hE<gt>\n"
-#| "#include E<lt>stdlib.hE<gt>\n"
-#| "#include E<lt>pthread.hE<gt>\n"
-#| "#include E<lt>malloc.hE<gt>\n"
-#| "#include E<lt>errno.hE<gt>\n"
+#, no-wrap
 msgid ""
 "#define _GNU_SOURCE\n"
 "#include E<lt>unistd.hE<gt>\n"
@@ -17867,11 +16590,11 @@ msgid ""
 "#include E<lt>stdio.hE<gt>\n"
 "#include E<lt>sys/mman.hE<gt>\n"
 msgstr ""
+"#define _GNU_SOURCE\n"
 "#include E<lt>unistd.hE<gt>\n"
-"#include E<lt>stdlib.hE<gt>\n"
-"#include E<lt>pthread.hE<gt>\n"
-"#include E<lt>malloc.hE<gt>\n"
-"#include E<lt>errno.hE<gt>\n"
+"#include E<lt>sys/syscall.hE<gt>\n"
+"#include E<lt>stdio.hE<gt>\n"
+"#include E<lt>sys/mman.hE<gt>\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:198
@@ -17884,6 +16607,12 @@ msgid ""
 "    unsigned int ecx = 0;\n"
 "    unsigned int edx = 0;\n"
 msgstr ""
+"static inline void\n"
+"wrpkru(unsigned int pkru)\n"
+"{\n"
+"    unsigned int eax = pkru;\n"
+"    unsigned int ecx = 0;\n"
+"    unsigned int edx = 0;\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:202
@@ -17893,6 +16622,9 @@ msgid ""
 "                 : : \"a\" (eax), \"c\" (ecx), \"d\" (edx));\n"
 "}\n"
 msgstr ""
+"    asm volatile(\".byte 0x0f,0x01,0xef\\en\\et\"\n"
+"                 : : \"a\" (eax), \"c\" (ecx), \"d\" (edx));\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:209
@@ -17905,6 +16637,12 @@ msgid ""
 "    return wrpkru(pkru);\n"
 "}\n"
 msgstr ""
+"int\n"
+"pkey_set(int pkey, unsigned long rights, unsigned long flags)\n"
+"{\n"
+"    unsigned int pkru = (rights E<lt>E<lt> (2 * pkey));\n"
+"    return wrpkru(pkru);\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:216
@@ -17917,6 +16655,12 @@ msgid ""
 "    return syscall(SYS_pkey_mprotect, ptr, size, orig_prot, pkey);\n"
 "}\n"
 msgstr ""
+"int\n"
+"pkey_mprotect(void *ptr, size_t size, unsigned long orig_prot,\n"
+"              unsigned long pkey)\n"
+"{\n"
+"    return syscall(SYS_pkey_mprotect, ptr, size, orig_prot, pkey);\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:222
@@ -17928,6 +16672,11 @@ msgid ""
 "    return syscall(SYS_pkey_alloc, 0, 0);\n"
 "}\n"
 msgstr ""
+"int\n"
+"pkey_alloc(void)\n"
+"{\n"
+"    return syscall(SYS_pkey_alloc, 0, 0);\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:228
@@ -17939,19 +16688,21 @@ msgid ""
 "    return syscall(SYS_pkey_free, pkey);\n"
 "}\n"
 msgstr ""
+"int\n"
+"pkey_free(unsigned long pkey)\n"
+"{\n"
+"    return syscall(SYS_pkey_free, pkey);\n"
+"}\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:231
-#, fuzzy, no-wrap
-#| msgid ""
-#| "#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \\e\n"
-#| "                        } while (0)\n"
+#, no-wrap
 msgid ""
 "#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \\e\n"
 "                           } while (0)\n"
 msgstr ""
 "#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \\e\n"
-"                        } while (0)\n"
+"                           } while (0)\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:238
@@ -17964,15 +16715,16 @@ msgid ""
 "    int pkey;\n"
 "    int *buffer;\n"
 msgstr ""
+"int\n"
+"main(void)\n"
+"{\n"
+"    int status;\n"
+"    int pkey;\n"
+"    int *buffer;\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:246
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
-#| "                MAP_PRIVATE, fd, pa_offset);\n"
-#| "    if (addr == MAP_FAILED)\n"
-#| "        handle_error(\"mmap\");\n"
+#, no-wrap
 msgid ""
 "    /*\n"
 "     *Allocate one page of memory\n"
@@ -17982,10 +16734,13 @@ msgid ""
 "    if (buffer == MAP_FAILED)\n"
 "        errExit(\"mmap\");\n"
 msgstr ""
-"    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
-"                MAP_PRIVATE, fd, pa_offset);\n"
-"    if (addr == MAP_FAILED)\n"
-"        handle_error(\"mmap\");\n"
+"    /*\n"
+"     *Allocate one page of memory\n"
+"     */\n"
+"    buffer = mmap(NULL, getpagesize(), PROT_READ | PROT_WRITE,\n"
+"                  MAP_ANONYMOUS | MAP_PRIVATE, -1, 0);\n"
+"    if (buffer == MAP_FAILED)\n"
+"        errExit(\"mmap\");\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:252
@@ -18042,7 +16797,7 @@ msgstr ""
 #: build/C/man7/pkeys.7:279
 #, no-wrap
 msgid "    printf(\"about to read buffer again...\\en\");\n"
-msgstr ""
+msgstr "    printf(\"about to read buffer again...\\en\");\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:284
@@ -18056,41 +16811,20 @@ msgstr ""
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:288
-#, fuzzy, no-wrap
-#| msgid ""
-#| "    seals = fcntl(fd, F_GET_SEALS);\n"
-#| "    if (seals == -1)\n"
-#| "        errExit(\"fcntl\");\n"
+#, no-wrap
 msgid ""
 "    status = pkey_free(pkey);\n"
 "    if (status == -1)\n"
 "        errExit(\"pkey_free\");\n"
 msgstr ""
-"    seals = fcntl(fd, F_GET_SEALS);\n"
-"    if (seals == -1)\n"
-"        errExit(\"fcntl\");\n"
+"    status = pkey_free(pkey);\n"
+"    if (status == -1)\n"
+"        errExit(\"pkey_free\");\n"
 
 #. type: Plain text
 #: build/C/man7/pkeys.7:297
-#, fuzzy
-#| msgid "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 msgid "B<pkey_alloc>(2), B<pkey_free>(2), B<pkey_mprotect>(2), B<sigaction>(2)"
-msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
-
-#~ msgid "2007-05-31"
-#~ msgstr "2007-05-31"
-
-#~ msgid "2013-10-07"
-#~ msgstr "2013-10-07"
-
-#~ msgid "Multithreading (see pthreads(7))"
-#~ msgstr "マルチスレッディング (pthreads(7) 参照)"
-
-#~ msgid "The B<alloca>()  function is thread-safe."
-#~ msgstr "B<alloca>() 関数はスレッドセーフである。"
-
-#~ msgid "2007-05-26"
-#~ msgstr "2007-05-26"
+msgstr "B<pkey_alloc>(2), B<pkey_free>(2), B<pkey_mprotect>(2), B<sigaction>(2)"
 
 #~ msgid ""
 #~ "This Linux-specific system call is available only on MIPS-based systems.  "
@@ -18099,9 +16833,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "この Linux 特有のシステムコールは MIPS ベースのシステムでのみ有効である。 "
 #~ "移植を意図したプログラムで使用すべきではない。"
 
-#~ msgid "2015-01-22"
-#~ msgstr "2015-01-22"
-
 #~ msgid ""
 #~ "Do not expect access in the near future.  (For the time being, the "
 #~ "application is finished with the given range, so the kernel can free "
@@ -18141,13 +16872,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "しようとしている。"
 
 #~ msgid ""
-#~ "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>, "
-#~ "B<MADV_MERGEABLE>, and B<MADV_UNMERGEABLE> are Linux-specific."
-#~ msgstr ""
-#~ "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>,\n"
-#~ "B<MADV_MERGEABLE>, B<MADV_UNMERGEABLE> は Linux 固有である。"
-
-#~ msgid ""
 #~ "The current Linux implementation (2.4.0) views this system call more as a "
 #~ "command than as advice and hence may return an error when it cannot do "
 #~ "what it usually would do in response to this advice.  (See the ERRORS "
@@ -18158,38 +16882,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "可能な場合は、 エラーを返すことがある (上記の エラー の記述を参照)。 この"
 #~ "振舞いは標準とは異なる。"
 
-#~ msgid "2012-05-06"
-#~ msgstr "2012-05-06"
-
-#~ msgid ""
-#~ "#include E<lt>malloc.hE<gt>\n"
-#~ "#include \"tlpi_hdr.h\"\n"
-#~ msgstr ""
-#~ "#include E<lt>malloc.hE<gt>\n"
-#~ "#include \"tlpi_hdr.h\"\n"
-
-#~ msgid "2014-06-13"
-#~ msgstr "2014-06-13"
-
-#~ msgid "2010-10-13"
-#~ msgstr "2010-10-13"
-
-#~ msgid ""
-#~ "int\n"
-#~ "main(int argc, char *argv[])\n"
-#~ "{\n"
-#~ "    int j, tn, sleepTime;\n"
-#~ "    pthread_t *thr;\n"
-#~ msgstr ""
-#~ "int\n"
-#~ "main(int argc, char *argv[])\n"
-#~ "{\n"
-#~ "    int j, tn, sleepTime;\n"
-#~ "    pthread_t *thr;\n"
-
-#~ msgid "2014-05-28"
-#~ msgstr "2014-05-28"
-
 #~ msgid ""
 #~ "This function cannot release free memory located at places other than the "
 #~ "top of the heap."
@@ -18200,18 +16892,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ msgid "This function releases only memory in the main arena."
 #~ msgstr "この関数はメイン領域のメモリーだけを解放する。"
 
-#~ msgid "The B<malloc_usable_size>()  function is thread-safe."
-#~ msgstr "B<malloc_usable_size>() 関数はスレッドセーフである。"
-
-#~ msgid "2014-07-08"
-#~ msgstr "2014-07-08"
-
-#~ msgid "2014-01-11"
-#~ msgstr "2014-01-11"
-
-#~ msgid "2014-04-14"
-#~ msgstr "2014-04-14"
-
 #~ msgid "AVAILABILITY"
 #~ msgstr "可用性"
 
@@ -18288,18 +16968,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "越えた部分など。これには 他のプロセスがファイルを切り詰めた場合なども含ま"
 #~ "れる)  にアクセスしようとした。"
 
-#~ msgid "SVr4, 4.4BSD, POSIX.1-2001."
-#~ msgstr "SVr4, 4.4BSD, POSIX.1-2001."
-
-#~ msgid "2014-02-25"
-#~ msgstr "2014-02-25"
-
-#~ msgid "2014-01-05"
-#~ msgstr "2014-01-05"
-
-#~ msgid "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
-#~ msgstr "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
-
 #~ msgid ""
 #~ "An invalid argument was given.  Possible causes are: I<old_address> was "
 #~ "not page aligned; a value other than B<MREMAP_MAYMOVE> or B<MREMAP_FIXED> "
@@ -18317,9 +16985,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "I<old_size> で指定される古いアドレス範囲と重なっている; B<MREMAP_FIXED> が"
 #~ "指定されているが B<MREMAP_MAYMOVE> が指定されていない。"
 
-#~ msgid "2014-04-20"
-#~ msgstr "2014-04-20"
-
 #~ msgid ""
 #~ "The I<flags> argument may have the bits B<MS_ASYNC>, B<MS_SYNC>, and "
 #~ "B<MS_INVALIDATE> set, but not both B<MS_ASYNC> and B<MS_SYNC>.  "
@@ -18335,12 +17000,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "(たった今書き込んだ新しい値でマッピングを更新することができるように)  同じ"
 #~ "ファイルに対する他のマッピングを無効にすることを要求する。"
 
-#~ msgid "    mtrace();\n"
-#~ msgstr "    mtrace();\n"
-
-#~ msgid "The B<posix_fallocate>()  function is thread-safe."
-#~ msgstr "B<posix_fallocate>() 関数はスレッドセーフである。"
-
 #~ msgid ""
 #~ "In the glibc implementation, B<posix_fallocate>()  is implemented using "
 #~ "B<fallocate>(2)."
@@ -18348,20 +17007,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "glibc の実装では、 B<posix_fallocate>() は B<fallocate>() を使って実装され"
 #~ "ている。"
 
-#~ msgid "2013-09-02"
-#~ msgstr "2013-09-02"
-
-#~ msgid ""
-#~ "_BSD_SOURCE ||\n"
-#~ "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
-#~ "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
-#~ "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
-#~ msgstr ""
-#~ "_BSD_SOURCE ||\n"
-#~ "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
-#~ "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
-#~ "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
-
 #~ msgid ""
 #~ "B<Note>: this system call is (since Linux 3.16) deprecated and will "
 #~ "eventually be replaced by a slower in-kernel emulation.  Those few "
@@ -18381,9 +17026,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "reached."
 #~ msgstr "ファイルシステムでオープンできるファイル数の上限に達した。"
 
-#~ msgid "2014-02-07"
-#~ msgstr "2014-02-07"
-
 #~ msgid ""
 #~ "Write the values of some members of the I<shmid_ds> structure pointed to "
 #~ "by I<buf> to the kernel data structure associated with this shared memory "
@@ -18400,18 +17042,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "呼び出したプロセスの実効 UID が所有者 (I<shm_perm.uid>)  または作成者 "
 #~ "(I<shm_perm.cuid>)  と一致するか、呼び出し元が特権を持たなければならない。"
 
-#~ msgid "SVr4, POSIX.1-2001."
-#~ msgstr "SVr4, POSIX.1-2001."
-
-#~ msgid "2015-01-10"
-#~ msgstr "2015-01-10"
-
-#~ msgid "2012-07-13"
-#~ msgstr "2012-07-13"
-
-#~ msgid "B<#include E<lt>sys/memfd.hE<gt>>"
-#~ msgstr "B<#include E<lt>sys/memfd.hE<gt>>"
-
 #~ msgid ""
 #~ "An unsupported value was specified in one of the arguments: I<flags> "
 #~ "included unknown bits, or I<name> was too long."
@@ -18426,16 +17056,6 @@ msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
 #~ "B<memfd_create>() システムコールは Linux 3.17 で初めて登場した。 GNU C ラ"
 #~ "イブラリでのサポートは検討中である。"
 
-#~ msgid "2015-01-15"
-#~ msgstr "2015-01-15"
-
-#~ msgid ""
-#~ "B<int s390_pci_mmio_read(unsigned long >I<mmio_addr>B<,>\n"
-#~ "B<                        void *>I<user_buffer>B<, size_t >I<length>B<);>\n"
-#~ msgstr ""
-#~ "B<int s390_pci_mmio_read(unsigned long >I<mmio_addr>B<,>\n"
-#~ "B<                        void *>I<user_buffer>B<, size_t >I<length>B<);>\n"
-
 #~ msgid "System-wide limit on the number of pages of shared memory."
 #~ msgstr "共有メモリーのページ数のシステム全体での上限値。"
 
index 0527862..c481d21 100644 (file)
@@ -1,39 +1,31 @@
 # pagename,#complete,#remaining,#all
-alloc_hugepages.2,29,5,34
-alloca.3,38,4,42
-cacheflush.2,28,22,50
-fallocate.2,84,24,108
-madvise.2,61,54,115
-mallinfo.3,62,14,76
-malloc_get_state.3,31,3,34
-malloc_hook.3,38,5,43
-malloc_info.3,56,9,65
-malloc_stats.3,25,2,27
-malloc_trim.3,28,7,35
-malloc_usable_size.3,29,1,30
-mallopt.3,57,70,127
-mcheck.3,34,32,66
-mlock.2,59,33,92
-mmap.2,118,64,182
-mprotect.2,49,40,89
-mremap.2,47,33,80
-msync.2,27,11,38
-mtrace.3,28,16,44
-posix_fadvise.2,52,12,64
-posix_fallocate.3,51,11,62
-posix_madvise.3,20,25,45
-posix_memalign.3,61,14,75
-readahead.2,29,2,31
-remap_file_pages.2,37,2,39
-shm_open.3,69,59,128
-shm_overview.7,40,2,42
-shmctl.2,62,44,106
-shmget.2,81,23,104
-shmop.2,63,64,127
-subpage_prot.2,21,15,36
-sync_file_range.2,61,1,62
-memfd_create.2,82,29,111
-s390_pci_mmio_write.2,23,11,34
-membarrier.2,18,90,108
-pkey_alloc.2,15,25,40
-pkeys.7,9,40,49
+alloca.3,41,1,42
+cacheflush.2,38,12,50
+fallocate.2,101,7,108
+madvise.2,82,33,115
+mallinfo.3,72,4,76
+malloc_hook.3,42,1,43
+malloc_trim.3,32,3,35
+mallopt.3,64,63,127
+mcheck.3,48,18,66
+mlock.2,77,15,92
+mmap.2,143,39,182
+mprotect.2,73,16,89
+mremap.2,58,22,80
+msync.2,34,4,38
+mtrace.3,33,11,44
+posix_fadvise.2,60,4,64
+posix_fallocate.3,54,8,62
+posix_madvise.3,30,15,45
+posix_memalign.3,72,3,75
+remap_file_pages.2,38,1,39
+shm_open.3,105,23,128
+shmctl.2,88,18,106
+shmget.2,98,6,104
+shmop.2,111,16,127
+subpage_prot.2,24,12,36
+memfd_create.2,104,7,111
+s390_pci_mmio_write.2,24,10,34
+membarrier.2,59,49,108
+pkey_alloc.2,25,15,40
+pkeys.7,26,23,49
index 9483c68..ea1d93b 100644 (file)
 <TR class="over80"><TD>sincos.3</TD><TD>1/42</TD><TD>97.62</TD></TR>
 <TR class="over80"><TD>y0.3</TD><TD>2/62</TD><TD>96.77</TD></TR>
 <TR><TD ALIGN="center" COLSPAN=3 BGCOLOR="Yellow"><B>memory</B></TD></TR>
-<TR class="over80"><TD>alloc_hugepages.2</TD><TD>5/34</TD><TD>85.29</TD></TR>
-<TR class="over80"><TD>alloca.3</TD><TD>4/42</TD><TD>90.48</TD></TR>
-<TR><TD>cacheflush.2</TD><TD>22/50</TD><TD>56.00</TD></TR>
-<TR class="over70"><TD>fallocate.2</TD><TD>24/108</TD><TD>77.78</TD></TR>
-<TR><TD>madvise.2</TD><TD>54/115</TD><TD>53.04</TD></TR>
-<TR class="over80"><TD>mallinfo.3</TD><TD>14/76</TD><TD>81.58</TD></TR>
-<TR class="over80"><TD>malloc_get_state.3</TD><TD>3/34</TD><TD>91.18</TD></TR>
-<TR class="over80"><TD>malloc_hook.3</TD><TD>5/43</TD><TD>88.37</TD></TR>
-<TR class="over80"><TD>malloc_info.3</TD><TD>9/65</TD><TD>86.15</TD></TR>
-<TR class="over80"><TD>malloc_stats.3</TD><TD>2/27</TD><TD>92.59</TD></TR>
-<TR class="over80"><TD>malloc_trim.3</TD><TD>7/35</TD><TD>80.00</TD></TR>
-<TR class="over80"><TD>malloc_usable_size.3</TD><TD>1/30</TD><TD>96.67</TD></TR>
-<TR><TD>mallopt.3</TD><TD>70/127</TD><TD>44.88</TD></TR>
-<TR><TD>mcheck.3</TD><TD>32/66</TD><TD>51.52</TD></TR>
-<TR><TD>mlock.2</TD><TD>33/92</TD><TD>64.13</TD></TR>
-<TR><TD>mmap.2</TD><TD>64/182</TD><TD>64.84</TD></TR>
-<TR><TD>mprotect.2</TD><TD>40/89</TD><TD>55.06</TD></TR>
-<TR><TD>mremap.2</TD><TD>33/80</TD><TD>58.75</TD></TR>
-<TR class="over70"><TD>msync.2</TD><TD>11/38</TD><TD>71.05</TD></TR>
-<TR><TD>mtrace.3</TD><TD>16/44</TD><TD>63.64</TD></TR>
-<TR class="over80"><TD>posix_fadvise.2</TD><TD>12/64</TD><TD>81.25</TD></TR>
-<TR class="over80"><TD>posix_fallocate.3</TD><TD>11/62</TD><TD>82.26</TD></TR>
-<TR><TD>posix_madvise.3</TD><TD>25/45</TD><TD>44.44</TD></TR>
-<TR class="over80"><TD>posix_memalign.3</TD><TD>14/75</TD><TD>81.33</TD></TR>
-<TR class="over80"><TD>readahead.2</TD><TD>2/31</TD><TD>93.55</TD></TR>
-<TR class="over80"><TD>remap_file_pages.2</TD><TD>2/39</TD><TD>94.87</TD></TR>
-<TR><TD>shm_open.3</TD><TD>59/128</TD><TD>53.91</TD></TR>
-<TR class="over80"><TD>shm_overview.7</TD><TD>2/42</TD><TD>95.24</TD></TR>
-<TR><TD>shmctl.2</TD><TD>44/106</TD><TD>58.49</TD></TR>
-<TR class="over70"><TD>shmget.2</TD><TD>23/104</TD><TD>77.88</TD></TR>
-<TR><TD>shmop.2</TD><TD>64/127</TD><TD>49.61</TD></TR>
-<TR><TD>subpage_prot.2</TD><TD>15/36</TD><TD>58.33</TD></TR>
-<TR class="over80"><TD>sync_file_range.2</TD><TD>1/62</TD><TD>98.39</TD></TR>
-<TR class="over70"><TD>memfd_create.2</TD><TD>29/111</TD><TD>73.87</TD></TR>
-<TR><TD>s390_pci_mmio_write.2</TD><TD>11/34</TD><TD>67.65</TD></TR>
-<TR><TD>membarrier.2</TD><TD>90/108</TD><TD>16.67</TD></TR>
-<TR><TD>pkey_alloc.2</TD><TD>25/40</TD><TD>37.50</TD></TR>
-<TR><TD>pkeys.7</TD><TD>40/49</TD><TD>18.37</TD></TR>
+<TR class="over80"><TD>alloca.3</TD><TD>1/42</TD><TD>97.62</TD></TR>
+<TR class="over70"><TD>cacheflush.2</TD><TD>12/50</TD><TD>76.00</TD></TR>
+<TR class="over80"><TD>fallocate.2</TD><TD>7/108</TD><TD>93.52</TD></TR>
+<TR class="over70"><TD>madvise.2</TD><TD>33/115</TD><TD>71.30</TD></TR>
+<TR class="over80"><TD>mallinfo.3</TD><TD>4/76</TD><TD>94.74</TD></TR>
+<TR class="over80"><TD>malloc_hook.3</TD><TD>1/43</TD><TD>97.67</TD></TR>
+<TR class="over80"><TD>malloc_trim.3</TD><TD>3/35</TD><TD>91.43</TD></TR>
+<TR><TD>mallopt.3</TD><TD>63/127</TD><TD>50.39</TD></TR>
+<TR class="over70"><TD>mcheck.3</TD><TD>18/66</TD><TD>72.73</TD></TR>
+<TR class="over80"><TD>mlock.2</TD><TD>15/92</TD><TD>83.70</TD></TR>
+<TR class="over70"><TD>mmap.2</TD><TD>39/182</TD><TD>78.57</TD></TR>
+<TR class="over80"><TD>mprotect.2</TD><TD>16/89</TD><TD>82.02</TD></TR>
+<TR class="over70"><TD>mremap.2</TD><TD>22/80</TD><TD>72.50</TD></TR>
+<TR class="over80"><TD>msync.2</TD><TD>4/38</TD><TD>89.47</TD></TR>
+<TR class="over70"><TD>mtrace.3</TD><TD>11/44</TD><TD>75.00</TD></TR>
+<TR class="over80"><TD>posix_fadvise.2</TD><TD>4/64</TD><TD>93.75</TD></TR>
+<TR class="over80"><TD>posix_fallocate.3</TD><TD>8/62</TD><TD>87.10</TD></TR>
+<TR><TD>posix_madvise.3</TD><TD>15/45</TD><TD>66.67</TD></TR>
+<TR class="over80"><TD>posix_memalign.3</TD><TD>3/75</TD><TD>96.00</TD></TR>
+<TR class="over80"><TD>remap_file_pages.2</TD><TD>1/39</TD><TD>97.44</TD></TR>
+<TR class="over80"><TD>shm_open.3</TD><TD>23/128</TD><TD>82.03</TD></TR>
+<TR class="over80"><TD>shmctl.2</TD><TD>18/106</TD><TD>83.02</TD></TR>
+<TR class="over80"><TD>shmget.2</TD><TD>6/104</TD><TD>94.23</TD></TR>
+<TR class="over80"><TD>shmop.2</TD><TD>16/127</TD><TD>87.40</TD></TR>
+<TR><TD>subpage_prot.2</TD><TD>12/36</TD><TD>66.67</TD></TR>
+<TR class="over80"><TD>memfd_create.2</TD><TD>7/111</TD><TD>93.69</TD></TR>
+<TR class="over70"><TD>s390_pci_mmio_write.2</TD><TD>10/34</TD><TD>70.59</TD></TR>
+<TR><TD>membarrier.2</TD><TD>49/108</TD><TD>54.63</TD></TR>
+<TR><TD>pkey_alloc.2</TD><TD>15/40</TD><TD>62.50</TD></TR>
+<TR><TD>pkeys.7</TD><TD>23/49</TD><TD>53.06</TD></TR>
 <TR><TD ALIGN="center" COLSPAN=3 BGCOLOR="Yellow"><B>mqueue</B></TD></TR>
 <TR class="over80"><TD>mq_notify.3</TD><TD>1/69</TD><TD>98.55</TD></TR>
 <TR class="over80"><TD>mq_open.3</TD><TD>5/79</TD><TD>93.67</TD></TR>
 <TR class="over80"><TD>login.3</TD><TD>1/46</TD><TD>97.83</TD></TR>
 <TR><TD ALIGN="center" COLSPAN=3 BGCOLOR="Yellow"><B>wchar</B></TD></TR>
 <TR class="over80"><TD>mbsnrtowcs.3</TD><TD>1/47</TD><TD>97.87</TD></TR>
-<TR><TD COLSPAN=3>Total 636 pages</TD></TR>
+<TR><TD COLSPAN=3>Total 628 pages</TD></TR>
 </TABLE>
 </BODY></HTML>