mmu_context_32.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef __SPARC_MMU_CONTEXT_H
  3. #define __SPARC_MMU_CONTEXT_H
  4. #ifndef __ASSEMBLY__
  5. #include <asm-generic/mm_hooks.h>
  6. static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk)
  7. {
  8. }
  9. /* Initialize a new mmu context. This is invoked when a new
  10. * address space instance (unique or shared) is instantiated.
  11. */
  12. int init_new_context(struct task_struct *tsk, struct mm_struct *mm);
  13. /* Destroy a dead context. This occurs when mmput drops the
  14. * mm_users count to zero, the mmaps have been released, and
  15. * all the page tables have been flushed. Our job is to destroy
  16. * any remaining processor-specific state.
  17. */
  18. void destroy_context(struct mm_struct *mm);
  19. /* Switch the current MM context. */
  20. void switch_mm(struct mm_struct *old_mm, struct mm_struct *mm,
  21. struct task_struct *tsk);
  22. #define deactivate_mm(tsk,mm) do { } while (0)
  23. /* Activate a new MM instance for the current task. */
  24. #define activate_mm(active_mm, mm) switch_mm((active_mm), (mm), NULL)
  25. #endif /* !(__ASSEMBLY__) */
  26. #endif /* !(__SPARC_MMU_CONTEXT_H) */