DragonFly commits List (threaded) for 2008-01
DragonFly BSD
DragonFly commits List (threaded) for 2008-01
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

cvs commit: src/sys/kern kern_lock.c


From: Simon Schubert <corecode@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 9 Jan 2008 02:59:12 -0800 (PST)

corecode    2008/01/09 02:59:12 PST

DragonFly src repository

  Modified files:
    sys/kern             kern_lock.c 
  Log:
  Fix lockuninit.
  
  lockuninit was acquiring the spinlock embedded in struct lock, thus
  incrementing the per-thread spinlock count. However, spin_uninit does
  not decrement the count, resulting in a panic when trying to sleep
  ("lwkt_switch: still holding %d exclusive spinlocks!"). From now on,
  require that the caller already holds the struct lock in question so
  that lockuninit can rely on it being the sole owner of the lock.
  
  Lots of help from: corecode@, aggelos
  
  Comment from Aggelos: "That's what you get when commiting code without
  any in-tree users."
  
  Submitted-by: nant@
  
  Revision  Changes    Path
  1.27      +8 -2      src/sys/kern/kern_lock.c


http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_lock.c.diff?r1=1.26&r2=1.27&f=u



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]