Fix a number of interrupt related issues.
authorMatthew Dillon <dillon@dragonflybsd.org>
Thu, 2 Oct 2003 22:27:00 +0000 (22:27 +0000)
committerMatthew Dillon <dillon@dragonflybsd.org>
Thu, 2 Oct 2003 22:27:00 +0000 (22:27 +0000)
commit46a3f46dae90993b147c872cad68435c2a8480a2
tree269b112ffd665e3e2d613437c4fdfcb13a1a7086
parentcde87949d1246fea3bd4161367f10732e2a3c727
Fix a number of interrupt related issues.

* Don't access kernel_map in free(), defer such operations to malloc()

* Fix a slab allocator panic due to mishandling of malloc size slab
  limit checks on machines with small amounts of memory (the slab allocator
  reduces the size of the zone on low-memory machines but did not handle the
  reduced size properly).

* Add thread->td_nest_count to prevent splz recursions from underflowing
  the kernel stack.  This can occur because we drop the critical section
  when calling sched_ithd() in order to allow it to preempt.

* Properly adjust intr_nesting_level around FAST interrupts

* Adjust the debugging printf() in lockmgr to only complain about blockable
  lock requests from interrupts.
13 files changed:
sys/i386/i386/genassym.c
sys/i386/isa/ipl.s
sys/i386/isa/ipl_funcs.c
sys/kern/kern_lock.c
sys/kern/kern_slaballoc.c
sys/kern/lwkt_thread.c
sys/platform/pc32/i386/genassym.c
sys/platform/pc32/isa/ipl.s
sys/platform/pc32/isa/ipl_funcs.c
sys/platform/vkernel/i386/genassym.c
sys/sys/globaldata.h
sys/sys/slaballoc.h
sys/sys/thread.h