X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?p=pandora-kernel.git;a=blobdiff_plain;f=mm%2Foom_kill.c;h=4dda9482f8736ca9e1d7b75da0113389e40059c5;hp=76f2c5ae908e85a858c006d932edcdf9128e0cc2;hb=41cf82c2b1e6a027d487c1f92dc3a0e811e1529a;hpb=2d360fcbd851b7f9f8c23b1c30b2f3c060fa43e6 diff --git a/mm/oom_kill.c b/mm/oom_kill.c index 76f2c5ae908e..4dda9482f873 100644 --- a/mm/oom_kill.c +++ b/mm/oom_kill.c @@ -176,7 +176,7 @@ static bool oom_unkillable_task(struct task_struct *p, unsigned int oom_badness(struct task_struct *p, struct mem_cgroup *mem, const nodemask_t *nodemask, unsigned long totalpages) { - int points; + long points; if (oom_unkillable_task(p, mem, nodemask)) return 0; @@ -213,7 +213,7 @@ unsigned int oom_badness(struct task_struct *p, struct mem_cgroup *mem, * implementation used by LSMs. */ if (has_capability_noaudit(p, CAP_SYS_ADMIN)) - points -= 30; + points -= (points * 3) / 100; /* * /proc/pid/oom_score_adj ranges from -1000 to +1000 such that it may