printk: Add printk_deferred_once
[linux-2.6-block.git] / kernel / sched / rt.c
index 5d7667b37c2163c1b3fcb5ff1898c1069a97dc22..b3512f1afce9361588a8ccb50f7ad75540122426 100644 (file)
@@ -890,14 +890,8 @@ static int sched_rt_runtime_exceeded(struct rt_rq *rt_rq)
                 * but accrue some time due to boosting.
                 */
                if (likely(rt_b->rt_runtime)) {
-                       static bool once = false;
-
                        rt_rq->rt_throttled = 1;
-
-                       if (!once) {
-                               once = true;
-                               printk_deferred("sched: RT throttling activated\n");
-                       }
+                       printk_deferred_once("sched: RT throttling activated\n");
                } else {
                        /*
                         * In case we did anyway, make it go away,