mman.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. #ifndef _SYS_MMAN_H
  2. #define _SYS_MMAN_H
  3. #include <features.h>
  4. #include <bits/types.h>
  5. #define __need_size_t
  6. #include <stddef.h>
  7. #include <bits/mman.h>
  8. #ifndef MAP_ANON
  9. #define MAP_ANON MAP_ANONYMOUS /* idem */
  10. #endif
  11. #ifndef MAP_FILE
  12. #define MAP_FILE 0x00 /* The 'normal' way: mapped from file */
  13. #endif
  14. #define MAP_FAILED ((__ptr_t) -1) /* Return value of `mmap' in case of an error. */
  15. __BEGIN_DECLS
  16. extern __ptr_t mmap __P((__ptr_t __addr, size_t __len,
  17. int __prot, int __flags, int __fd, off_t __off));
  18. extern int munmap __P((__ptr_t __addr, size_t __len));
  19. extern int mprotect __P ((__const __ptr_t __addr, size_t __len, int __prot));
  20. extern int msync __P((__ptr_t __addr, size_t __len, int __flags));
  21. extern int mlock __P((__const __ptr_t __addr, size_t __len));
  22. extern int munlock __P((__const __ptr_t __addr, size_t __len));
  23. extern int mlockall __P((int __flags));
  24. extern int munlockall __P((void));
  25. extern __ptr_t mremap __P((__ptr_t __addr, size_t __old_len,
  26. size_t __new_len, int __may_move));
  27. __END_DECLS
  28. #endif /* _SYS_MMAN_H */