diff --git a/[refs] b/[refs] index 5d0fcd41f363..3984f82d7d87 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8447d950e7445cae71ad66d0e33784f8388aaf9d +refs/heads/master: dc3f21eadeea6d9898271ff32d35d5e00c6872ea diff --git a/trunk/mm/oom_kill.c b/trunk/mm/oom_kill.c index 856106036ba2..517299c808cb 100644 --- a/trunk/mm/oom_kill.c +++ b/trunk/mm/oom_kill.c @@ -34,6 +34,7 @@ #include #include #include +#include #define CREATE_TRACE_POINTS #include @@ -444,6 +445,8 @@ static void oom_kill_process(struct task_struct *p, gfp_t gfp_mask, int order, struct task_struct *t = p; struct mm_struct *mm; unsigned int victim_points = 0; + static DEFINE_RATELIMIT_STATE(oom_rs, DEFAULT_RATELIMIT_INTERVAL, + DEFAULT_RATELIMIT_BURST); /* * If the task is already exiting, don't alarm the sysadmin or kill @@ -454,7 +457,7 @@ static void oom_kill_process(struct task_struct *p, gfp_t gfp_mask, int order, return; } - if (printk_ratelimit()) + if (__ratelimit(&oom_rs)) dump_header(p, gfp_mask, order, memcg, nodemask); task_lock(p);