EINVAL can happen with O_DIRECT

This commit is contained in:
Michael Kerrisk 2005-10-10 13:07:32 +00:00
parent 1ae9f93747
commit 94604cf710
2 changed files with 17 additions and 2 deletions

View File

@ -89,7 +89,14 @@ The call was interrupted by a signal before any data was read.
.TP
.B EINVAL
.I fd
is attached to an object which is unsuitable for reading.
is attached to an object which is unsuitable for reading;
or the file was opened with the
.B O_DIRECT
flag, and either the address specified in
.IR buf ,
the value specified in
.IR count ,
or the current file offset is not suitably aligned.
.TP
.B EIO
I/O error. This will happen for example when the process is in a
@ -133,6 +140,7 @@ and/or disks.
.BR fcntl (2),
.BR ioctl (2),
.BR lseek (2),
.BR open (2),
.BR readdir (2),
.BR readlink (2),
.BR select (2),

View File

@ -79,7 +79,14 @@ The call was interrupted by a signal before any data was written.
.TP
.B EINVAL
.I fd
is attached to an object which is unsuitable for writing.
is attached to an object which is unsuitable for writing;
or the file was opened with the
.B O_DIRECT
flag, and either the address specified in
.IR buf ,
the value specified in
.IR count ,
or the current file offset is not suitably aligned.
.TP
.B EIO
A low-level I/O error occurred while modifying the inode.