提交 d16e15f5 编写于 作者: N Namhyung Kim 提交者: Linus Torvalds

exit: add lock context annotation on find_new_reaper()

find_new_reaper() releases and regrabs tasklist_lock but was missing
proper annotations.  Add it.  This remove following sparse warning:

 warning: context imbalance in 'find_new_reaper' - unexpected unlock
Signed-off-by: NNamhyung Kim <namhyung@gmail.com>
Acked-by: NRoland McGrath <roland@redhat.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 89502155
...@@ -703,6 +703,8 @@ static void exit_mm(struct task_struct * tsk) ...@@ -703,6 +703,8 @@ static void exit_mm(struct task_struct * tsk)
* space. * space.
*/ */
static struct task_struct *find_new_reaper(struct task_struct *father) static struct task_struct *find_new_reaper(struct task_struct *father)
__releases(&tasklist_lock)
__acquires(&tasklist_lock)
{ {
struct pid_namespace *pid_ns = task_active_pid_ns(father); struct pid_namespace *pid_ns = task_active_pid_ns(father);
struct task_struct *thread; struct task_struct *thread;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册