--- linux-2.6.11-rc1/kernel/printk.c 2005-01-14 12:36:00 +0100 +++ linux-2.6.11-rc1-vs1.9.4-rc2/kernel/printk.c 2005-01-15 11:27:52 +0100 @@ -524,6 +527,8 @@ asmlinkage int printk(const char *fmt, . return r; } +static volatile int printk_cpu = -1; + asmlinkage int vprintk(const char *fmt, va_list args) { unsigned long flags; --- linux-2.6.11-rc1/kernel/printk.c 2005-01-14 12:36:00 +0100 +++ linux-2.6.11-rc1-vs1.9.4-rc2/kernel/printk.c 2005-01-15 11:27:52 +0100 @@ -532,11 +537,12 @@ asmlinkage int vprintk(const char *fmt, static char printk_buf[1024]; static int log_level_unknown = 1; - if (unlikely(oops_in_progress)) + if (unlikely(oops_in_progress && printk_cpu == smp_processor_id())) zap_locks(); /* This stops the holder of console_sem just where we want him */ spin_lock_irqsave(&logbuf_lock, flags); + printk_cpu = smp_processor_id(); /* Emit the output into the temporary buffer */ printed_len = vscnprintf(printk_buf, sizeof(printk_buf), fmt, args);