Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753302AbbDGLHs (ORCPT ); Tue, 7 Apr 2015 07:07:48 -0400 Received: from mail-wi0-f177.google.com ([209.85.212.177]:36046 "EHLO mail-wi0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752570AbbDGLHq (ORCPT ); Tue, 7 Apr 2015 07:07:46 -0400 Date: Tue, 7 Apr 2015 13:07:41 +0200 From: Ingo Molnar To: Alexander Kuleshov Cc: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Greg Kroah-Hartman , linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] x86/earlyprintk: setup earlyprintk as possible Message-ID: <20150407110741.GB14136@gmail.com> References: <1428404540-16601-1-git-send-email-kuleshovmail@gmail.com> <1428404578-17480-1-git-send-email-kuleshovmail@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1428404578-17480-1-git-send-email-kuleshovmail@gmail.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1585 Lines: 42 * Alexander Kuleshov wrote: > As setup_early_printk passed to the early_param, it will be usable only after > 'parse_early_param' function will be called from the 'setup_arch'. So we have > earlyprintk during early boot and decompression. Next point after decompression > of the kernel where we can use early_printk is after call of the > 'parse_early_param'. > > This patch removes 'earlyprintk' from the early_param and setup it right after > boot data copying. So 'early_printk' function will be usabable after > decompression of kernel and before parse_early_param will be called. > > Kernel with this patch was tested with qemu-i386. early_printk function works > after early_printk initialization. > > Signed-off-by: Alexander Kuleshov > --- > arch/x86/kernel/head32.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/arch/x86/kernel/head32.c b/arch/x86/kernel/head32.c > index 2911ef3..dd0aadc 100644 > --- a/arch/x86/kernel/head32.c > +++ b/arch/x86/kernel/head32.c > @@ -34,6 +34,9 @@ asmlinkage __visible void __init i386_start_kernel(void) > cr4_init_shadow(); > sanitize_boot_params(&boot_params); > > + /* setup earlyprintk as early as possible */ > + setup_early_printk(boot_command_line); So why not at the beginning of the function? Thanks, Ingo -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/