mmu.h 603 B

1234567891011121314151617181920212223242526272829303132333435
  1. #ifndef __ARM_MMU_H
  2. #define __ARM_MMU_H
  3. #ifdef CONFIG_MMU
  4. typedef struct {
  5. #ifdef CONFIG_CPU_HAS_ASID
  6. atomic64_t id;
  7. #endif
  8. unsigned int vmalloc_seq;
  9. unsigned long sigpage;
  10. } mm_context_t;
  11. #ifdef CONFIG_CPU_HAS_ASID
  12. #define ASID_BITS 8
  13. #define ASID_MASK ((~0ULL) << ASID_BITS)
  14. #define ASID(mm) ((mm)->context.id.counter & ~ASID_MASK)
  15. #else
  16. #define ASID(mm) (0)
  17. #endif
  18. #else
  19. /*
  20. * From nommu.h:
  21. * Copyright (C) 2002, David McCullough <davidm@snapgear.com>
  22. * modified for 2.6 by Hyok S. Choi <hyok.choi@samsung.com>
  23. */
  24. typedef struct {
  25. unsigned long end_brk;
  26. } mm_context_t;
  27. #endif
  28. #endif