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

Commit d8136467 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "lowmemorykiller: ignore the tasks that has null mm for reaping"

parents 4eb2a28f 05fdda0d
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -561,13 +561,15 @@ static unsigned long lowmem_scan(struct shrinker *s, struct shrink_control *sc)

		task_lock(selected);
		send_sig(SIGKILL, selected, 0);
		if (selected->mm)
		if (selected->mm) {
			task_set_lmk_waiting(selected);
		if (oom_reaper)
			if (!test_bit(MMF_OOM_SKIP, &selected->mm->flags) &&
			    oom_reaper) {
				mark_lmk_victim(selected);
		task_unlock(selected);
		if (oom_reaper)
				wake_oom_reaper(selected);
			}
		}
		task_unlock(selected);
		trace_lowmemory_kill(selected, cache_size, cache_limit, free);
		lowmem_print(1, "Killing '%s' (%d) (tgid %d), adj %hd,\n"
			"to free %ldkB on behalf of '%s' (%d) because\n"