“092268602a4735958da2e871de1d825599e768da”上不存在“...registry/git@gitcode.net:openanolis/dragonwell8_jdk.git”
  • T
    workqueue: Fix pwq ref leak in rescuer_thread() · 1fe8f4ae
    Tejun Heo 提交于
    commit e66b39af00f426b3356b96433d620cb3367ba1ff upstream.
    
    008847f6 ("workqueue: allow rescuer thread to do more work.") made
    the rescuer worker requeue the pwq immediately if there may be more
    work items which need rescuing instead of waiting for the next mayday
    timer expiration.  Unfortunately, it doesn't check whether the pwq is
    already on the mayday list and unconditionally gets the ref and moves
    it onto the list.  This doesn't corrupt the list but creates an
    additional reference to the pwq.  It got queued twice but will only be
    removed once.
    
    This leak later can trigger pwq refcnt warning on workqueue
    destruction and prevent freeing of the workqueue.
    Signed-off-by: NTejun Heo <tj@kernel.org>
    Cc: "Williams, Gerald S" <gerald.s.williams@intel.com>
    Cc: NeilBrown <neilb@suse.de>
    Cc: stable@vger.kernel.org # v3.19+
    Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
    1fe8f4ae
workqueue.c 163.1 KB