From: Stuart M. <Stu...@st...> - 2000-07-03 10:47:14
|
Folks I've found what was causing the 'slab poisoning' problem which I reported a few days ago. There is a bug in the kernel when setting the interrupt mask bits in the status register when returning from an exception. This can result in interrupts being re-enabled when they should not be. The particular sequence of events which caused this in my situation was: - kernel is executing in the slab memory allocator free function - executes a spin_lock_irqsave which disables interrupts - takes a floating point exception - on return from the exception interrupts are erroneously re-enabled - an interrupt from the Ethernet controller occurs - interrupt handler calls the slab allocator to allocate a packet - packet which is returned is one which has been freed but not yet poisoned, and so fails the poison test A patch is attached which fixes this, which I'll check this in in the next few days if nobody objects. It also feels like it improves overall reliability, although I've not got any data to back this up. I'm surprised nobody else is seeing these problems. Are we the only people using SH4 perhaps? One thing I did spot while doing this. The irq_imask technique of interrupt masking will not work with interrupts at priority 15. Not really a problem, but it might be worth adding a comment somewhere before this trips somebody up. Stuart |