Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • L linux
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Kirill Smelkov
  • linux
  • Repository
  • linux
  • kernel
  • workqueue.c
Find file BlameHistoryPermalink
  • Tejun Heo's avatar
    workqueue: Fix pwq ref leak in rescuer_thread() · aa8bff63
    Tejun Heo authored Sep 25, 2019
    BugLink: https://bugs.launchpad.net/bugs/1858489
    
    commit e66b39af 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: default avatarTejun 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: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    Signed-off-by: default avatarConnor Kuehl <connor.kuehl@canonical.com>
    Signed-off-by: default avatarKleber Sacilotto de Souza <kleber.souza@canonical.com>
    aa8bff63
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7