summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRussell King <rmk@flint.arm.linux.org.uk>2004-10-29 18:05:26 +0100
committerRussell King <rmk@flint.arm.linux.org.uk>2004-10-29 18:05:26 +0100
commita6a4b52e27f3efecdb87024f53108fdac4493d2a (patch)
treec0f319291b7e23dc8f08e2650b3722b9ee92eeb6 /include
parenteec2e6670c41f1aba7b02dde582951165a95966e (diff)
[ARM] Use cpu_vm_mask to indicate whether the MM is mapped.
Diffstat (limited to 'include')
-rw-r--r--include/asm-arm/mmu_context.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/include/asm-arm/mmu_context.h b/include/asm-arm/mmu_context.h
index a4cb79241a73..4af9c411c617 100644
--- a/include/asm-arm/mmu_context.h
+++ b/include/asm-arm/mmu_context.h
@@ -80,18 +80,17 @@ static inline void
switch_mm(struct mm_struct *prev, struct mm_struct *next,
struct task_struct *tsk)
{
+ unsigned int cpu = smp_processor_id();
+
if (prev != next) {
+ cpu_set(cpu, next->cpu_vm_mask);
check_context(next);
cpu_switch_mm(next->pgd, next);
+ cpu_clear(cpu, prev->cpu_vm_mask);
}
}
#define deactivate_mm(tsk,mm) do { } while (0)
-
-static inline void activate_mm(struct mm_struct *prev, struct mm_struct *next)
-{
- check_context(next);
- cpu_switch_mm(next->pgd, next);
-}
+#define activate_mm(prev,next) switch_mm(prev, next, NULL)
#endif