OSDN Git Service

0cb3dac5c7d89be7ee5256b81c6f1f83a3fdd4f8
[linuxjm/LDP_man-pages.git] / release / man3 / aio_fsync.3
1 .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
2 .\"
3 .\" This is free documentation; you can redistribute it and/or
4 .\" modify it under the terms of the GNU General Public License as
5 .\" published by the Free Software Foundation; either version 2 of
6 .\" the License, or (at your option) any later version.
7 .\"
8 .\" The GNU General Public License's references to "object code"
9 .\" and "executables" are to be interpreted as the output of any
10 .\" document formatting or typesetting system, including
11 .\" intermediate and printed output.
12 .\"
13 .\" This manual is distributed in the hope that it will be useful,
14 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
15 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 .\" GNU General Public License for more details.
17 .\"
18 .\" You should have received a copy of the GNU General Public
19 .\" License along with this manual; if not, write to the Free
20 .\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
21 .\" USA.
22 .\"
23 .\" Japanese Version Copyright (c) 2004 Yuichi SATO
24 .\"         all rights reserved.
25 .\" Translated Sun Jul  4 17:20:13 JST 2004
26 .\"         by Yuichi SATO <ysato444@yahoo.co.jp>
27 .\"
28 .TH AIO_FSYNC 3 2003-11-14  "" "Linux Programmer's Manual"
29 .SH 名前
30 aio_fsync \- 非同期ファイルを同期させる
31 .SH 書式
32 .B "#include <aio.h>"
33 .sp
34 .BI "int aio_fsync(int " op ", struct aiocb *" aiocbp );
35 .sp
36 \fI\-lrt\fP でリンクする。
37 .SH 説明
38 .BR aio_fsync ()
39 関数は、
40 .I aiocbp\->aio_fildes
41 で関連付けられているまだ完了していない全ての非同期 I/O 操作を同期させる。
42 .LP
43 より正確に言うと、
44 .I op
45
46 .B O_SYNC
47 の場合、現在キューに入れられている全ての I/O 操作は、
48 .BR fsync (2)
49 が呼ばれたかのように完了されるだろう。
50 また
51 .I op
52
53 .B O_DSYNC
54 の場合、この呼び出しは
55 .BR fdatasync (2)
56 の非同期版となる。
57 この関数はリクエストを行うだけである点に注意すること \(em
58 この呼び出しは I/O の完了を待たない。
59 .LP
60 .I aiocbp
61 で指される構造体のフィールドのうち、この呼び出しで
62 .I aio_fildes
63 以外に使用されるのは
64 .I aio_sigevent
65 フィールド (\fIstruct sigevent\fP) のみである。
66 このフィールドは、完了時の非同期通知に使用したいタイプを示す。
67 その他のフィールドは無視される。
68 .SH 返り値
69 成功した場合 (同期リクエストをキューに入れるのに成功した場合)、
70 この関数は 0 を返す。
71 エラーの場合、\-1 が返され、
72 .I errno
73 が適切に設定される。
74 .SH エラー
75 .TP
76 .B EAGAIN
77 リソースが足りない。
78 .TP
79 .B EBADF
80 .I aio_fildes
81 が書き込みのためにオープンされた有効なファイルディスクリプタではない。
82 .TP
83 .B EINVAL
84 このファイルに対する同期 I/O がサポートされていない。
85 または
86 .I op
87
88 .B O_SYNC
89 でも
90 .B O_DSYNC
91 でもない。
92 .SH 準拠
93 POSIX.1-2001.
94 .SH 関連項目
95 .BR aio_cancel (3),
96 .BR aio_error (3),
97 .BR aio_read (3),
98 .BR aio_return (3),
99 .BR aio_suspend (3),
100 .BR aio_write (3)