Re: [PATCH] x86/irq: Use printk_deferred() on raw_spin_lock() protected sections

From: Peter Zijlstra
Date: Thu Sep 24 2020 - 06:28:37 EST


On Mon, Sep 21, 2020 at 06:22:12PM +0200, Daniel Bristot de Oliveira wrote:
> While testing hotplug I got this BUG:

>
> It was caused by printk() inside a code section protected by a
> raw_spin_lock() that ended up calling a serial console that
> uses a regular spin_lock().
>
> Use the printk_deferred() to avoid calling the serial console
> in a raw_spin_lock() protected section.

I consider printk_deferred() to be a bug, can't we just wait for the new
printk implementation to land so we don't need all this nonsense?