提交 f86c9747 编写于 作者: S Sonny Rao 提交者: Paul Mackerras

[POWERPC] Fix idr locking in init_new_context

We always need to serialize accesses to mmu_context_idr.

I hit this bug when testing with a small number of mmu contexts.
Signed-off-by: NSonny Rao <sonny@burdell.org>
Signed-off-by: NPaul Mackerras <paulus@samba.org>
上级 975b3658
......@@ -44,7 +44,9 @@ int init_new_context(struct task_struct *tsk, struct mm_struct *mm)
return err;
if (index > MAX_CONTEXT) {
spin_lock(&mmu_context_lock);
idr_remove(&mmu_context_idr, index);
spin_unlock(&mmu_context_lock);
return -ENOMEM;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册