Re: [RFC V2 12/21] rv/reactor: Add the printk reactor
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: Re: [RFC V2 12/21] rv/reactor: Add the printk reactor
- From: John Ogness <john.ogness@xxxxxxxxxxxxx>
- Date: Tue, 15 Feb 2022 11:09:55 +0106
- Cc: Jonathan Corbet <corbet@xxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Peter Zijlstra <peterz@xxxxxxxxxxxxx>, Will Deacon <will@xxxxxxxxxx>, Catalin Marinas <catalin.marinas@xxxxxxx>, Marco Elver <elver@xxxxxxxxxx>, Dmitry Vyukov <dvyukov@xxxxxxxxxx>, "Paul E. McKenney" <paulmck@xxxxxxxxxx>, Gabriele Paoloni <gpaoloni@xxxxxxxxxx>, Juri Lelli <juri.lelli@xxxxxxxxxx>, Clark Williams <williams@xxxxxxxxxx>, linux-doc@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, linux-trace-devel@xxxxxxxxxxxxxxx
- In-reply-to: <c1657d1c-0d2b-4aa3-c1ed-2ae6fdfcda86@kernel.org>
- References: <cover.1644830251.git.bristot@kernel.org> <fad2d358d57dfffc084d482684ecc1d13b62b262.1644830251.git.bristot@kernel.org> <10cf6003-6d2b-056b-11bb-3ae9c342a369@linuxfoundation.org> <c1657d1c-0d2b-4aa3-c1ed-2ae6fdfcda86@kernel.org>
On 2022-02-14, Daniel Bristot de Oliveira <bristot@xxxxxxxxxx> wrote:
> On 2/14/22 18:25, Shuah Khan wrote:
>> On 2/14/22 3:45 AM, Daniel Bristot de Oliveira wrote:
>>> Note: do not use this reactor with rq_lock taken, it will lock the
>>> system until printk can handle that.
>>
>> Please give more details on "lock the system" and how locking
>> would impact users and system operation
>
> It is a deadlock on the rq_lock. Hopefully the new printk
> implementation handles that better.
I suggest using printk_deferred() for this reactor for now. With
printk_deferred() the message and timestamp are immediately and
locklessly stored in the buffer, and the printing is performed in a
separate context. printk_deferred() is safe for all contexts.
John
[Index of Archives]
[Linux USB Development]
[Linux USB Development]
[Linux Audio Users]
[Yosemite Hiking]
[Linux Kernel]
[Linux SCSI]