Subject: Re: kprintf locking problem.
To: Ross Harvey <ross@ghs.com>
From: Anders Magnusson <ragge@ludd.luth.se>
List: tech-smp
Date: 06/03/2001 19:04:06
> 
> I don't think that your problem is the printf lock. You have a general
> problem with the slave attempting to print when the master is spinning
> on _any_ lock, since the slave can't proceed until it prints, but the
> master won't acquire its lock until the slave proceeds.
> 
If the master CPU is spinning on a lock that is not taken by a 
__cpu_simple_lock(), then it will be handled by the SPINLOCK_SPIN_HOOK.
But you're right, if there is a printf inside another spinlock
then the same problem rises. That is a good reason to just do the check
inside __cpu_simple_lock(), and everything would be fine.

-- Ragge