Commit 4b687a46 authored by KOSAKI Motohiro's avatar KOSAKI Motohiro Committed by James Toy

commit 0753ba01 (mm: revert "oom: move oom_adj value") reverted some

regression patch. but it didn't revert one oom retrieved driver patch.

Then, it made build error to the driver. This reverts commit
a6a9f81c too and fixes the build error.
Reported-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: default avatarKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Greg KH <greg@kroah.com>
Cc: <stable@kernel.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 86750812
......@@ -99,21 +99,19 @@ static int lowmem_shrink(int nr_to_scan, gfp_t gfp_mask)
read_lock(&tasklist_lock);
for_each_process(p) {
struct mm_struct *mm;
int oom_adj;
task_lock(p);
mm = p->mm;
if (!mm) {
if (!p->mm) {
task_unlock(p);
continue;
}
oom_adj = mm->oom_adj;
oom_adj = p->oomkilladj;
if (oom_adj < min_adj) {
task_unlock(p);
continue;
}
tasksize = get_mm_rss(mm);
tasksize = get_mm_rss(p->mm);
task_unlock(p);
if (tasksize <= 0)
continue;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment