Skip to content

Commit

Permalink
ARM: 6944/1: mm: allow ASID 0 to be allocated to tasks
Browse files Browse the repository at this point in the history
Now that ASID 0 is no longer used as a reserved value, allow it to be
allocated to tasks.

Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Will Deacon authored and Russell King committed May 26, 2011
1 parent 52af9c6 commit 45b9523
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions arch/arm/mm/context.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ static void reset_context(void *info)
return;

smp_rmb();
asid = cpu_last_asid + cpu + 1;
asid = cpu_last_asid + cpu;

flush_context();
set_mm_context(mm, asid);
Expand Down Expand Up @@ -144,13 +144,13 @@ void __new_context(struct mm_struct *mm)
* to start a new version and flush the TLB.
*/
if (unlikely((asid & ~ASID_MASK) == 0)) {
asid = cpu_last_asid + smp_processor_id() + 1;
asid = cpu_last_asid + smp_processor_id();
flush_context();
#ifdef CONFIG_SMP
smp_wmb();
smp_call_function(reset_context, NULL, 1);
#endif
cpu_last_asid += NR_CPUS;
cpu_last_asid += NR_CPUS - 1;
}

set_mm_context(mm, asid);
Expand Down

0 comments on commit 45b9523

Please sign in to comment.