• Zqiang's avatar
    workqueue: Disable per-cpu CPU hog detection when wq_cpu_intensive_thresh_us is 0 · 18c8ae81
    Zqiang authored
    If workqueue.cpu_intensive_thresh_us is set to 0, the detection mechanism
    for CPU-hogging per-cpu work item will keep triggering spuriously:
    
      workqueue: process_srcu hogged CPU for >0us 4 times, consider switching to WQ_UNBOUND
      workqueue: gc_worker hogged CPU for >0us 4 times, consider switching to WQ_UNBOUND
      workqueue: gc_worker hogged CPU for >0us 8 times, consider switching to WQ_UNBOUND
      workqueue: wait_rcu_exp_gp hogged CPU for >0us 4 times, consider switching to WQ_UNBOUND
      workqueue: kfree_rcu_monitor hogged CPU for >0us 4 times, consider switching to WQ_UNBOUND
      workqueue: kfree_rcu_monitor hogged CPU for >0us 8 times, consider switching to WQ_UNBOUND
      workqueue: reg_todo hogged CPU for >0us 4 times, consider switching to WQ_UNBOUND
    
    This commit therefore disables the CPU-hog detection mechanism when
    workqueue.cpu_intensive_thresh_us is set to 0.
    
    tj: Patch description updated and the condition check on
        cpu_intensive_thresh_us separated into a separate if statement for
        readability.
    Signed-off-by: default avatarZqiang <qiang.zhang1211@gmail.com>
    Signed-off-by: default avatarTejun Heo <tj@kernel.org>
    18c8ae81
workqueue.c 182 KB