kernel - Major MPSAFE Infrastructure 2
authorMatthew Dillon <dillon@apollo.backplane.com>
Fri, 27 Aug 2010 08:55:46 +0000 (01:55 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sat, 28 Aug 2010 00:06:41 +0000 (17:06 -0700)
commitc57248528eb11d4c5d4fadfdac323e3d4eb3d424
tree4c1adf488b1cedcf3ee58dc97f7fc3831576dbd6
parent77912481ac5f5d886b07c9f7038b03eba09b2bca
kernel - Major MPSAFE Infrastructure 2

* Refactor buffer cache code which assumes content-stable data across
  a non-blocking BUF_LOCK().  This is no longer true.  The content must
  be reverified after the BUF_LOCK() succeeds.

* Make setting and clearing B_DELWRI atomic with buffer reassignment.

* Release cached mplock when looping in the scheduler and run
  check_splz() to avoid livelocking cpus.

* Refactor the mplock contention handling code to handle both the mplock
  and token contention.  Generate a 2uS delay for all but one cpu to
  try to avoid livelocks.

* Do not splz() from inside a spinlock, it will just panic.

* Fix the token description field for 'systat -pv 1'.

* Optimize MP_LOCK macros a bit.
15 files changed:
sys/kern/kern_mplock.c
sys/kern/kern_spinlock.c
sys/kern/kern_umtx.c
sys/kern/lwkt_thread.c
sys/kern/lwkt_token.c
sys/kern/vfs_bio.c
sys/kern/vfs_subr.c
sys/kern/vfs_vm.c
sys/platform/pc32/i386/machdep.c
sys/platform/pc32/isa/clock.c
sys/platform/pc64/isa/clock.c
sys/platform/pc64/x86_64/machdep.c
sys/platform/vkernel/i386/cpu_regs.c
sys/platform/vkernel64/x86_64/cpu_regs.c
sys/sys/mplock2.h