git: kernel - Fix panic during coredump

Matthew Dillon dillon at crater.dragonflybsd.org
Fri Jul 10 00:40:31 PDT 2015


commit f5b92db707a8f80d80fd78012a3fcdda94a8dd8a
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Fri Jul 10 00:37:32 2015 -0700

    kernel - Fix panic during coredump
    
    * multi-threaded coredumps were not stopping all other threads before
      attempting to scan the vm_map, resulting in numerous possible panics.
    
    * Add a new process state, SCORE, indicating that a core dump is in progress
      and adjust proc_stop() and friends as well as any code which tests the
      SSTOP state.  SCORE overrides SSTOP.
    
    * The coredump code actively waits for all running threads to stop before
      proceeding.
    
    * Prevent a deadlock between a SIGKILL and core dump in progress by
      temporarily counting the master exit thread as a stopped thread (which
      allows the coredump to proceed and finish).
    
    Reported-by: marino

Summary of changes:
 sys/kern/kern_checkpoint.c           | 14 +++++---
 sys/kern/kern_exit.c                 | 29 ++++++++++++++--
 sys/kern/kern_sig.c                  | 66 ++++++++++++++++++++++++++++--------
 sys/kern/kern_synch.c                |  2 +-
 sys/kern/sys_process.c               |  2 +-
 sys/platform/pc64/x86_64/trap.c      |  5 +--
 sys/platform/vkernel64/x86_64/trap.c |  5 +--
 sys/sys/proc.h                       |  5 +--
 sys/vfs/procfs/procfs_ctl.c          |  6 ++--
 sys/vm/vm_pageout.c                  |  4 +--
 10 files changed, 102 insertions(+), 36 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/f5b92db707a8f80d80fd78012a3fcdda94a8dd8a


-- 
DragonFly BSD source repository



More information about the Commits mailing list