aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2012-09-08 21:29:10 -0700
committerMike Frysinger <vapier@gentoo.org>2012-10-04 23:24:45 -0400
commitc2b598a94512c5d754b25c77399032e87c1f2dd5 (patch)
treeff05712c7bd3000c64e5c891d8bf343f5914e7b8 /sysdeps/unix/sysv
parent9043e2288e8f61bf36b90f5790abf549782d1957 (diff)
downloadglibc-c2b598a94512c5d754b25c77399032e87c1f2dd5.zip
glibc-c2b598a94512c5d754b25c77399032e87c1f2dd5.tar.gz
glibc-c2b598a94512c5d754b25c77399032e87c1f2dd5.tar.bz2
powerpc: add name_to_handle_at, open_by_handle etc. to bits/fcntl.h
Fixes BZ #14251.
Diffstat (limited to 'sysdeps/unix/sysv')
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h28
1 files changed, 27 insertions, 1 deletions
diff --git a/sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h b/sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h
index c984e2b..91797b7 100644
--- a/sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h
+++ b/sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h
@@ -1,5 +1,5 @@
/* O_*, F_*, FD_* bit values for Linux/PowerPC.
- Copyright (C) 1995-1998, 2000, 2003, 2004, 2006, 2007, 2009, 2010, 2011
+ Copyright (C) 1995-2012
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -232,6 +232,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
@@ -278,6 +291,19 @@ extern int fallocate64 (int __fd, int __mode, __off64_t __offset,
__off64_t __len);
# 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
__END_DECLS