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
You need to sign in or sign up before continuing.
  • linux
  • kernel
  • module.c
Find file BlameHistoryPermalink
  • Rusty Russell's avatar
    module: drop the lock while waiting for module to complete initialization. · 480b02df
    Rusty Russell authored May 19, 2010
    
    
    This fixes "gave up waiting for init of module libcrc32c." which
    happened at boot time due to multiple parallel module loads.
    
    The problem was a deadlock: we wait for a module to finish
    initializing, but we keep the module_lock mutex so it can't complete.
    In particular, this could reasonably happen if a module does a
    request_module() in its initialization routine.
    
    So we change use_module() to return an errno rather than a bool, and if
    it's -EBUSY we drop the lock and wait in the caller, then reaquire the
    lock.
    
    Reported-by: default avatarBrandon Philips <brandon@ifup.org>
    Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
    Tested-by: default avatarBrandon Philips <brandon@ifup.org>
    480b02df
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7