X-Git-Url: http://git.monstr.eu/?a=blobdiff_plain;f=kernel%2Fworkqueue.c;h=9880b6c0e2721fe5c0758eda58d82c1f36576d19;hb=aa8c7db494d0a83ecae583aa193f1134ef25d506;hp=b5295a0b05369c9927b01afb1fbcf88e220777e7;hpb=432c19a8d965aa0123e0a81492492a7cb1da5257;p=linux-2.6-microblaze.git diff --git a/kernel/workqueue.c b/kernel/workqueue.c index b5295a0b0536..9880b6c0e272 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -3731,17 +3731,24 @@ static void pwq_adjust_max_active(struct pool_workqueue *pwq) * is updated and visible. */ if (!freezable || !workqueue_freezing) { + bool kick = false; + pwq->max_active = wq->saved_max_active; while (!list_empty(&pwq->delayed_works) && - pwq->nr_active < pwq->max_active) + pwq->nr_active < pwq->max_active) { pwq_activate_first_delayed(pwq); + kick = true; + } /* * Need to kick a worker after thawed or an unbound wq's - * max_active is bumped. It's a slow path. Do it always. + * max_active is bumped. In realtime scenarios, always kicking a + * worker will cause interference on the isolated cpu cores, so + * let's kick iff work items were activated. */ - wake_up_worker(pwq->pool); + if (kick) + wake_up_worker(pwq->pool); } else { pwq->max_active = 0; }