Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Oct 2001 13:48:04 -0700 (PDT)
From:      Matt Dillon <dillon@FreeBSD.org>
To:        cvs-committers@FreeBSD.org.cvs-all@FreeBSD.org
Subject:   cvs commit: src/sys/kern kern_mutex.c kern_prot.c src/sys/sys mutex.h
Message-ID:  <200110262048.f9QKm5A67668@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
dillon      2001/10/26 13:48:04 PDT

  Modified files:
    sys/kern             kern_mutex.c kern_prot.c 
    sys/sys              mutex.h 
  Log:
  Add mtx_lock_giant() and mtx_unlock_giant() wrappers for sysctl management
  of Giant during the Giant unwinding phase, and start work on instrumenting
  Giant for the file and proc mutexes.
  
  These wrappers allow developers to turn on and off Giant around various
  subsystems.  DEVELOPERS SHOULD NEVER TURN OFF GIANT AROUND A SUBSYSTEM JUST
  BECAUSE THE SYSCTL EXISTS!  General developers should only considering
  turning on Giant for a subsystem whos default is off (to help track down
  bugs).  Only developers working on particular subsystems who know what
  they are doing should consider turning off Giant.
  
  These wrappers will greatly improve our ability to unwind Giant and test
  the kernel on a (mostly) subsystem by subsystem basis.   They allow Giant
  unwinding developers (GUDs) to emplace appropriate subsystem and structural
  mutexes in the main tree and then request that the larger community test
  the work by turning off Giant around the subsystem(s), without the larger
  community having to mess around with patches.  These wrappers also allow
  GUDs to boot into a (more likely to be) working system in the midst of
  their unwinding work and to test that work under more controlled
  circumstances.
  
  There is a master sysctl, kern.giant.all, which defaults to 0 (off).  If
  turned on it overrides *ALL* other kern.giant sysctls and forces Giant to
  be turned on for all wrapped subsystems.  If turned off then Giant around
  individual subsystems are controlled by various other kern.giant.XXX sysctls.
  
  Code which overlaps multiple subsystems must have all related subsystem Giant
  sysctls turned off in order to run without Giant.
  
  Revision  Changes    Path
  1.73      +42 -0     src/sys/kern/kern_mutex.c
  1.116     +10 -7     src/sys/kern/kern_prot.c
  1.44      +8 -0      src/sys/sys/mutex.h

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200110262048.f9QKm5A67668>