1 | /* |
1 | /* |
2 | * libeio API header |
2 | * libeio API header |
3 | * |
3 | * |
4 | * Copyright (c) 2007,2008,2009,2010 Marc Alexander Lehmann <libeio@schmorp.de> |
4 | * Copyright (c) 2007,2008,2009,2010,2011 Marc Alexander Lehmann <libeio@schmorp.de> |
5 | * All rights reserved. |
5 | * All rights reserved. |
6 | * |
6 | * |
7 | * Redistribution and use in source and binary forms, with or without modifica- |
7 | * Redistribution and use in source and binary forms, with or without modifica- |
8 | * tion, are permitted provided that the following conditions are met: |
8 | * tion, are permitted provided that the following conditions are met: |
9 | * |
9 | * |
… | |
… | |
180 | struct eio_req |
180 | struct eio_req |
181 | { |
181 | { |
182 | eio_req volatile *next; /* private ETP */ |
182 | eio_req volatile *next; /* private ETP */ |
183 | |
183 | |
184 | ssize_t result; /* result of syscall, e.g. result = read (... */ |
184 | ssize_t result; /* result of syscall, e.g. result = read (... */ |
185 | off_t offs; /* read, write, truncate, readahead, sync_file_range: file offset */ |
185 | off_t offs; /* read, write, truncate, readahead, sync_file_range: file offset, mknod: dev_t */ |
186 | size_t size; /* read, write, readahead, sendfile, msync, mlock, sync_file_range: length */ |
186 | size_t size; /* read, write, readahead, sendfile, msync, mlock, sync_file_range: length */ |
187 | void *ptr1; /* all applicable requests: pathname, old name; readdir: optional eio_dirents */ |
187 | void *ptr1; /* all applicable requests: pathname, old name; readdir: optional eio_dirents */ |
188 | void *ptr2; /* all applicable requests: new name or memory buffer; readdir: name strings */ |
188 | void *ptr2; /* all applicable requests: new name or memory buffer; readdir: name strings */ |
189 | eio_tstamp nv1; /* utime, futime: atime; busy: sleep time */ |
189 | eio_tstamp nv1; /* utime, futime: atime; busy: sleep time */ |
190 | eio_tstamp nv2; /* utime, futime: mtime */ |
190 | eio_tstamp nv2; /* utime, futime: mtime */ |
191 | |
191 | |
192 | int type; /* EIO_xxx constant ETP */ |
192 | int type; /* EIO_xxx constant ETP */ |
193 | int int1; /* all applicable requests: file descriptor; sendfile: output fd; open, msync, mlockall, readdir: flags */ |
193 | int int1; /* all applicable requests: file descriptor; sendfile: output fd; open, msync, mlockall, readdir: flags */ |
194 | long int2; /* chown, fchown: uid; sendfile: input fd; open, chmod, mkdir, mknod: file mode, sync_file_range: flags */ |
194 | long int2; /* chown, fchown: uid; sendfile: input fd; open, chmod, mkdir, mknod: file mode, sync_file_range: flags */ |
195 | long int3; /* chown, fchown: gid; mknod: dev_t */ |
195 | long int3; /* chown, fchown: gid */ |
196 | int errorno; /* errno value on syscall return */ |
196 | int errorno; /* errno value on syscall return */ |
197 | |
197 | |
198 | unsigned char flags; /* private */ |
198 | unsigned char flags; /* private */ |
199 | signed char pri; /* the priority */ |
199 | signed char pri; /* the priority */ |
200 | |
200 | |