From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755209AbcCWOce (ORCPT ); Wed, 23 Mar 2016 10:32:34 -0400 Received: from mail-pf0-f172.google.com ([209.85.192.172]:32861 "EHLO mail-pf0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753574AbcCWOcd (ORCPT ); Wed, 23 Mar 2016 10:32:33 -0400 Date: Wed, 23 Mar 2016 23:30:20 +0900 From: Sergey Senozhatsky To: Jan Kara Cc: Petr Mladek , Sergey Senozhatsky , Sergey Senozhatsky , Andrew Morton , Jan Kara , Tejun Heo , Tetsuo Handa , linux-kernel@vger.kernel.org, Byungchul Park Subject: Re: [RFC][PATCH v6 1/2] printk: Make printk() completely async Message-ID: <20160323143020.GA596@swordfish> References: <1458581130-8677-1-git-send-email-sergey.senozhatsky@gmail.com> <1458581130-8677-2-git-send-email-sergey.senozhatsky@gmail.com> <20160322163612.GB5522@pathway.suse.cz> <20160323012238.GB641@swordfish> <20160323092541.GC5522@pathway.suse.cz> <20160323132011.GG4512@quack.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160323132011.GG4512@quack.suse.cz> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, On (03/23/16 14:20), Jan Kara wrote: [..] > > I though that it actually could be an advantage. console_verbore() is > > called also by oops_begin() and it does not need to be fatal. But you > > are right that it does not need to be the righ approach. > > If we oops, I want printk to be sync regardless whether the machine is able > to live afterwards or not. You never know in advance... That's why I've > chosen the console_verbose() trigger and I still think it is better than > oops_in_progress or special console_panic() trigger. console_verbose() is good enough. well, with special console_panic() trigger we can have better control and distinguish between "print a lot" and "things are bad for sure, print in sync mode". there are 2 archs that call console_verbose() in setup_arch(): - arch/microblaze/kernel/setup.c : void __init setup_arch(char **cmdline_p) : { : *cmdline_p = boot_command_line; : : console_verbose(); <<<< : : unflatten_device_tree(); : : setup_cpuinfo(); : : microblaze_cache_init(); : : setup_memory(); - arch/nios2/kernel/setup.c : void __init setup_arch(char **cmdline_p) : { : int bootmap_size; : : console_verbose(); <<<< : : #ifdef CONFIG_EARLY_PRINTK : setup_early_printk(); : #endif so printk will never work in async mode there. hm... should we care? -ss