Hello,
I just have a question about the usage of printk in multi-processor
platforms. If the program on two CPUs both try to call printk to output
something, will the program running on one CPUs get blocked (or just
spinning there) till the other is done with printk()?
Thanks,
Liang
On 11/9/05, John Smith <[email protected]> wrote:
>
> I just have a question about the usage of printk in multi-processor
> platforms. If the program on two CPUs both try to call printk to output
> something, will the program running on one CPUs get blocked (or just
> spinning there) till the other is done with printk()?
>
I think yes, but for a very less time as printk holds the spin_lock to
logbuf_lock which will make to wait the printk on other CPU, and then
printk just copies the content to log_buffer and then call
release_console_sem which actually send the data to console later !
--
Fawad Lateef