diff options
author | joseph <joseph@7b3dc134-2b1b-0410-93df-9e9f96275f8d> | 2011-04-01 19:43:08 +0000 |
---|---|---|
committer | joseph <joseph@7b3dc134-2b1b-0410-93df-9e9f96275f8d> | 2011-04-01 19:43:08 +0000 |
commit | c46d4a9b60ba79c321ab9075f71751389808a15a (patch) | |
tree | 604d02100f0216b1684cfb7f51d46663b25b10d3 /libc/sysdeps/unix/sysv/linux/x86_64 | |
parent | 5c8cf8f50bb4598c4ecf2aa860aa7bf0ef0c3df7 (diff) |
Merge changes between r13227 and r13354 from /fsf/trunk.
git-svn-id: svn://svn.eglibc.org/trunk@13355 7b3dc134-2b1b-0410-93df-9e9f96275f8d
Diffstat (limited to 'libc/sysdeps/unix/sysv/linux/x86_64')
-rw-r--r-- | libc/sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h | 57 |
1 files changed, 50 insertions, 7 deletions
diff --git a/libc/sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h b/libc/sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h index ac029fdda..7f18562c1 100644 --- a/libc/sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h +++ b/libc/sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h @@ -1,5 +1,5 @@ /* O_*, F_*, FD_* bit values for Linux/x86-64. - Copyright (C) 2001,2002,2004,2006,2007,2009,2010 + Copyright (C) 2001,2002,2004,2006,2007,2009,2010,2011 Free Software Foundation, Inc. This file is part of the GNU C Library. @@ -54,6 +54,7 @@ #ifdef __USE_GNU # define O_DIRECT 040000 /* Direct disk access. */ # define O_NOATIME 01000000 /* Do not set atime. */ +# define O_PATH 010000000 /* Resolve pathname but do not open file. */ #endif /* For now Linux has synchronisity options for data and read operations. @@ -247,6 +248,19 @@ struct f_owner_ex we splice from/to). */ # define SPLICE_F_MORE 4 /* Expect more data. */ # define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */ + + +/* File handle structure. */ +struct file_handle +{ + unsigned int handle_bytes; + int handle_type; + /* File identifier. */ + unsigned char f_handle[0]; +}; + +/* Maximum handle size (for now). */ +# define MAX_HANDLE_SZ 128 #endif __BEGIN_DECLS @@ -258,25 +272,40 @@ extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count) __THROW; -/* Selective file content synch'ing. */ +/* Selective file content synch'ing. + + This function is a possible cancellation point and therefore not + marked with __THROW. */ extern int sync_file_range (int __fd, __off64_t __offset, __off64_t __count, unsigned int __flags); -/* Splice address range into a pipe. */ +/* Splice address range into a pipe. + + This function is a possible cancellation point and therefore not + marked with __THROW. */ extern ssize_t vmsplice (int __fdout, const struct iovec *__iov, size_t __count, unsigned int __flags); -/* Splice two files together. */ +/* Splice two files together. + + This function is a possible cancellation point and therefore not + marked with __THROW. */ extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout, __off64_t *__offout, size_t __len, unsigned int __flags); -/* In-kernel implementation of tee for pipe buffers. */ +/* In-kernel implementation of tee for pipe buffers. + + This function is a possible cancellation point and therefore not + marked with __THROW. */ extern ssize_t tee (int __fdin, int __fdout, size_t __len, unsigned int __flags); -/* Reserve storage for the data of the file associated with FD. */ +/* Reserve storage for the data of the file associated with FD. + + This function is a possible cancellation point and therefore not + marked with __THROW. */ # ifndef __USE_FILE_OFFSET64 extern int fallocate (int __fd, int __mode, __off_t __offset, __off_t __len); # else @@ -292,6 +321,20 @@ extern int __REDIRECT (fallocate, (int __fd, int __mode, __off64_t __offset, extern int fallocate64 (int __fd, int __mode, __off64_t __offset, __off64_t __len); # endif -#endif + + +/* Map file name to file handle. */ +extern int name_to_handle_at (int __dfd, const char *__name, + struct file_handle *__handle, int *__mnt_id, + int __flags) __THROW; + +/* Open file using the file handle. + + This function is a possible cancellation point and therefore not + marked with __THROW. */ +extern int open_by_handle_at (int __mountdirfd, struct file_handle *__handle, + int __flags); + +#endif /* use GNU */ __END_DECLS |