From bb8e0116cd59b11053154fb4adbad9f06a344147 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Fri, 14 Apr 2000 07:51:02 +0000 Subject: update. 2000-04-14 Ulrich Drepper * include/sys/statfs.h: Add prototypes for __statfs64 and __fstatfs64. * sysdeps/generic/fstatfs64.c (__fstatfs64): Renamed to fstatfs64. Make old name weak alias. * sysdeps/unix/sysv/linux/fstatfs64.c: Likewise. * sysdeps/generic/statfs64.c (__statfs64): Renamed to statfs64. Make old name weak alias. * sysdeps/unix/sysv/linux/statfs64.c: Likewise. * io/Makefile (routines): Add posix_fadvise, posix_fadvise64, posix_fallocate, and posix_fallocate64. * io/Versions [libc] (GLIBC_2.2): Add posix_fadvise, posix_fadvise64, posix_fallocate, and posix_fallocate64. * io/fcntl.h: Declare posix_fadvise, posix_fadvise64, posix_fallocate, and posix_fallocate64. * sysdeps/generic/fadvise.c: New file. * sysdeps/generic/fadvise64.c: New file. * sysdeps/generic/fallocate.c: New file. * sysdeps/generic/fallocate64.c: New file. * sysdeps/posix/fallocate.c: New file. * sysdeps/posix/fallocate64.c: New file. * sysdeps/generic/bits/fcntl.h: Define POSIX_FADV_NORMAL, POSIX_FADV_RANDOM, POSIX_FADV_SEQUENTIAL, POSIX_FADV_WILLNEED, POSIX_FADV_DONTNEED, and POSIX_FADV_NOREUSE. * sysdeps/mach/hurd/bits/fcntl.h: Likewise. * sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Likewise. * sysdeps/unix/sysv/linux/bits/fcntl.h: Likewise. * sysdeps/unix/sysv/linux/i386/bits/fcntl.h: Likewise. * sysdeps/unix/sysv/linux/mips/bits/fcntl.h: Likewise. * sysdeps/unix/sysv/linux/sparc/bits/fcntl.h: Likewise. * sysdeps/generic/madvise.c (__madvise): Renamed to posix_madvise. * sysdeps/unix/sysv/linux/syscalls.list: Likewise. --- io/fcntl.h | 41 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) (limited to 'io/fcntl.h') diff --git a/io/fcntl.h b/io/fcntl.h index 8706a44dc8..7ab542642c 100644 --- a/io/fcntl.h +++ b/io/fcntl.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1991,92,94,95,96,97,98,99 Free Software Foundation, Inc. +/* Copyright (C) 1991,92,94,95,96,97,98,99, 2000 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -125,6 +125,45 @@ extern int lockf64 (int __fd, int __cmd, __off64_t __len) __THROW; # endif #endif +#ifdef __USE_XOPEN2K +/* Advice the system about the expected behaviour of the application with + respect to the file associated with FD. */ +# ifndef __USE_FILE_OFFSET64 +extern int posix_fadvise (int __fd, __off_t __offset, size_t __len, + int __advise) __THROW; +# else +# ifdef __REDIRECT +extern int __REDIRECT (posix_fadvise, (int __fd, __off64_t __offset, + size_t __len, int __advise) __THROW, + posix_fadvise64); +# else +# define posix_fadvise posix_fadvise64 +# endif +# endif +# ifdef __USE_LARGEFILE64 +extern int posix_fadvise64 (int __fd, __off64_t __offset, size_t __len, + int __advise) __THROW; +# endif + + +/* Reserve storage for the data of the file associated with FD. */ +# ifndef __USE_FILE_OFFSET64 +extern int posix_fallocate (int __fd, __off_t __offset, size_t __len) __THROW; +# else +# ifdef __REDIRECT +extern int __REDIRECT (posix_fallocate, (int __fd, __off64_t __offset, + size_t __len) __THROW, + posix_fallocate64); +# else +# define posix_fallocate posix_fallocate64 +# endif +# endif +# ifdef __USE_LARGEFILE64 +extern int posix_fallocate64 (int __fd, __off64_t __offset, size_t __len) + __THROW; +# endif +#endif + __END_DECLS #endif /* fcntl.h */ -- cgit 1.4.1