From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750839AbVHWHTH (ORCPT ); Tue, 23 Aug 2005 03:19:07 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750850AbVHWHTH (ORCPT ); Tue, 23 Aug 2005 03:19:07 -0400 Received: from ylpvm15-ext.prodigy.net ([207.115.57.46]:52455 "EHLO ylpvm15.prodigy.net") by vger.kernel.org with ESMTP id S1750845AbVHWHTF (ORCPT ); Tue, 23 Aug 2005 03:19:05 -0400 X-ORBL: [67.117.73.34] Date: Tue, 23 Aug 2005 00:18:43 -0700 From: Tony Lindgren To: Andrew Morton Cc: "Luck, Tony" , linux-kernel@vger.kernel.org, jasonuhl@sgi.com Subject: Re: CONFIG_PRINTK_TIME woes Message-ID: <20050823071842.GB29951@atomide.com> References: <20050821021322.3986dd4a.akpm@osdl.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050821021322.3986dd4a.akpm@osdl.org> User-Agent: Mutt/1.5.6+20040907i Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org * Andrew Morton [050821 02:15]: > "Luck, Tony" wrote: > > > > It has been pointed out to me that ia64 doesn't boot > > with CONFIG_PRINTK_TIME=y. The issue is the call to > > sched_clock() ... which on ia64 accesses some per-cpu > > data to adjust for possible variations in processor > > speed between different cpus. Since the per-cpu page > > is not set up for the first few printk() calls, we die. > > > > Is this an issue on any other architecture? Most versions > > of sched_clock() seem to just scale jiffies into nanoseconds, > > so I guess they don't. s390, sparc64, x86 and x86_64 all > > have more sophisticated versions but they don't appear to me > > to have limitations on how early they might be called. CONFIG_PRINTK_TIME also has a problem on at least ARM OMAP where the IO mapping to read the clock may not be initialized when sched_clock() is called for the first time. I'd hate to have to test for something for CONFIG_PRINTK_TIME every time sched_clock() is being called. The quick fix would seem to be to only allow CONFIG_PRINTK_TIME from kernel cmdline to make it happen a bit later. So basically make int printk_time = 0 until command line is evaluated. Tony