Commit a73a9aad authored by Tiwei Bie's avatar Tiwei Bie Committed by Johannes Berg
Browse files

um: Stop tracking virtual CPUs via mm_cpumask()



In UML, each user address space is represented as a separate stub
process on the host. Therefore, user address spaces do not require
TLB management on UML virtual CPUs, and it's unnecessary to track
which virtual CPUs they have executed on.

Signed-off-by: default avatarTiwei Bie <tiwei.btw@antgroup.com>
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent e047f9af
Loading
Loading
Loading
Loading
+0 −11
Original line number Diff line number Diff line
@@ -13,20 +13,9 @@
#include <asm/mm_hooks.h>
#include <asm/mmu.h>

#define activate_mm activate_mm
static inline void activate_mm(struct mm_struct *old, struct mm_struct *new)
{
}

static inline void switch_mm(struct mm_struct *prev, struct mm_struct *next, 
			     struct task_struct *tsk)
{
	unsigned cpu = smp_processor_id();

	if (prev != next) {
		cpumask_clear_cpu(cpu, mm_cpumask(prev));
		cpumask_set_cpu(cpu, mm_cpumask(next));
	}
}

#define init_new_context init_new_context