Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 322a2c10 authored by Thomas Gleixner's avatar Thomas Gleixner
Browse files

futex: Move exit_pi_state() call to release_mm()



exit_pi_state() is called from do_exit() but not from do_execve().
Move it to release_mm() so it gets called from do_execve() as well.

Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
LKML-Reference: <new-submission>
Cc: stable@kernel.org
Cc: Anirban Sinha <ani@anirban.org>
Cc: Peter Zijlstra <peterz@infradead.org>
parent fc6b177d
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -989,8 +989,6 @@ NORET_TYPE void do_exit(long code)
	tsk->mempolicy = NULL;
#endif
#ifdef CONFIG_FUTEX
	if (unlikely(!list_empty(&tsk->pi_state_list)))
		exit_pi_state_list(tsk);
	if (unlikely(current->pi_state_cache))
		kfree(current->pi_state_cache);
#endif
+2 −0
Original line number Diff line number Diff line
@@ -553,6 +553,8 @@ void mm_release(struct task_struct *tsk, struct mm_struct *mm)
		tsk->compat_robust_list = NULL;
	}
#endif
	if (unlikely(!list_empty(&tsk->pi_state_list)))
		exit_pi_state_list(tsk);
#endif

	/* Get rid of any cached register state */