mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
UPSTREAM: staging: android: lowmemorykiller: set TIF_MEMDIE before send kill sig
(cherry picked from commit 6bc2b856bb
)
Set TIF_MEMDIE tsk_thread flag before send kill signal to the
selected thread. This is to fit a usual code sequence and avoid
potential race issue.
Signed-off-by: Weijie Yang <weijie.yang@samsung.com>
Acked-by: David Rientjes <rientjes@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
36cb9e975f
commit
10a5473b65
1 changed files with 1 additions and 1 deletions
|
@ -392,8 +392,8 @@ static int lowmem_shrink(struct shrinker *s, struct shrink_control *sc)
|
|||
}
|
||||
|
||||
lowmem_deathpending_timeout = jiffies + HZ;
|
||||
send_sig(SIGKILL, selected, 0);
|
||||
set_tsk_thread_flag(selected, TIF_MEMDIE);
|
||||
send_sig(SIGKILL, selected, 0);
|
||||
rem -= selected_tasksize;
|
||||
rcu_read_unlock();
|
||||
/* give the system time to free up the memory */
|
||||
|
|
Loading…
Reference in a new issue