From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933744AbcCPHaV (ORCPT ); Wed, 16 Mar 2016 03:30:21 -0400 Received: from LGEAMRELO12.lge.com ([156.147.23.52]:42400 "EHLO lgeamrelo12.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932269AbcCPHaS (ORCPT ); Wed, 16 Mar 2016 03:30:18 -0400 X-Original-SENDERIP: 156.147.1.126 X-Original-MAILFROM: byungchul.park@lge.com X-Original-SENDERIP: 10.177.222.33 X-Original-MAILFROM: byungchul.park@lge.com Date: Wed, 16 Mar 2016 16:30:07 +0900 From: Byungchul Park To: Sergey Senozhatsky Cc: Sergey Senozhatsky , Jan Kara , Andrew Morton , Jan Kara , Petr Mladek , Tejun Heo , Tetsuo Handa , linux-kernel@vger.kernel.org Subject: Re: [RFC][PATCH v4 1/2] printk: Make printk() completely async Message-ID: <20160316073007.GL5220@X58A-UD3R> References: <1457964820-4642-1-git-send-email-sergey.senozhatsky@gmail.com> <1457964820-4642-2-git-send-email-sergey.senozhatsky@gmail.com> <20160315100323.GF17942@quack.suse.cz> <20160315140738.GA773@swordfish> <20160316053944.GJ5220@X58A-UD3R> <20160316065851.GC3217@swordfish> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160316065851.GC3217@swordfish> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 16, 2016 at 03:58:51PM +0900, Sergey Senozhatsky wrote: > I don't have a very clear vision (at the moment) of how to fix printk recursion > caused by logbuf lock of console_sem corruptions, etc. Should spin_dump > be aware of the locks that can be taken by printk()? Hm, I can't even count all > the locks that possibly can be taken by printk->console_drivers and most likely > don't even see all of the cases where printk can recurse. Disable lock debug > in vprintk_emit() the same way lockdep is desabled? Hm... > > Ingo's POV is that printk must be reworked and become smarter in this aspect. Yeah, it must be smarter... :-( > > > I mean that it would be better to keep the wake_up and friend out of the > > critical section by logbuf_lock. > > in this case wake_up_process() can recurse us forever. I said they should be kept *out of* the critical section. :-) Otherwise, it can recurse us forever. Do you mean the wake_up_process() in console_unlock? If so, it must be handled by some ways, e.g. my patch you know. Thanks, Byungchul > > -ss