uClibc_page.h 502 B

12345678910111213141516171819202122232425
  1. /*
  2. * Licensed under the LGPL v2.1 or later, see the file COPYING.LIB in this tarball.
  3. */
  4. #ifndef _UCLIBC_PAGE_H
  5. #define _UCLIBC_PAGE_H
  6. /*
  7. * AARCH64 supports 4k, 16k, 64k pages (build time).
  8. */
  9. #include <features.h>
  10. #if defined(__CONFIG_AARCH64_PAGE_SIZE_64K__)
  11. #define PAGE_SHIFT 16
  12. #elif defined(__CONFIG_AARCH64_PAGE_SIZE_16K__)
  13. #define PAGE_SHIFT 14
  14. #else
  15. #define PAGE_SHIFT 12
  16. #endif
  17. #define PAGE_SIZE (1UL << PAGE_SHIFT)
  18. #define PAGE_MASK (~(PAGE_SIZE-1))
  19. #endif /* _UCLIBC_PAGE_H */