fstatfs.c 889 B

1234567891011121314151617181920212223242526272829303132333435
  1. /* vi: set sw=4 ts=4: */
  2. /*
  3. * fstatfs() for uClibc
  4. *
  5. * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
  6. *
  7. * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
  8. */
  9. #include <sys/syscall.h>
  10. #include <sys/vfs.h>
  11. #ifndef __USE_FILE_OFFSET64
  12. extern int fstatfs (int __fildes, struct statfs *__buf)
  13. __THROW __nonnull ((2));
  14. #else
  15. # ifdef __REDIRECT_NTH
  16. extern int __REDIRECT_NTH (fstatfs, (int __fildes, struct statfs *__buf),
  17. fstatfs64) __nonnull ((2));
  18. # else
  19. # define fstatfs fstatfs64
  20. # endif
  21. #endif
  22. extern __typeof(fstatfs) __libc_fstatfs;
  23. libc_hidden_proto(__libc_fstatfs)
  24. #define __NR___libc_fstatfs __NR_fstatfs
  25. _syscall2(int, __libc_fstatfs, int, fd, struct statfs *, buf)
  26. libc_hidden_def(__libc_fstatfs)
  27. #if defined __UCLIBC_LINUX_SPECIFIC__
  28. libc_hidden_proto(fstatfs)
  29. weak_alias(__libc_fstatfs,fstatfs)
  30. libc_hidden_weak(fstatfs)
  31. #endif