Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1424416AbWKPVGu (ORCPT ); Thu, 16 Nov 2006 16:06:50 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1424615AbWKPVGu (ORCPT ); Thu, 16 Nov 2006 16:06:50 -0500 Received: from mail.timesys.com ([65.117.135.102]:32211 "EHLO postfix.timesys.com") by vger.kernel.org with ESMTP id S1424572AbWKPVGu (ORCPT ); Thu, 16 Nov 2006 16:06:50 -0500 Subject: Re: BUG: cpufreq notification broken From: Thomas Gleixner Reply-To: tglx@timesys.com To: Alan Stern Cc: LKML , Linus Torvalds , john stultz , Ingo Molnar , David Miller , Arjan van de Ven , Andrew Morton , Andi Kleen In-Reply-To: References: Content-Type: text/plain Date: Thu, 16 Nov 2006 22:09:28 +0100 Message-Id: <1163711368.10333.41.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.6.1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1463 Lines: 36 On Thu, 2006-11-16 at 15:27 -0500, Alan Stern wrote: > > Hmm, there are no static initializers for srcu and the only way to fix > > this up is to move the arch calls to postcore_init. > > If you can find a way to invoke init_cpufreq_transition_notifier_list > earlier than core_initcall time, that would be okay. I did it this way > because it was easiest, but earlier should be just as good. > > The only requirement is that alloc_percpu() has to be working, so that the > SRCU per-cpu data values can be set up. I don't know how early in the > boot process you can do per-cpu memory allocation. > > As an alternative approach, initialization of srcu_notifiers could be > broken up into two pieces, one of which could be done statically. The > part that has to be done dynamically (the SRCU initialization) wouldn't > mess up the notifier chain. Provided the dynamic part is carried out > while the system is still single-threaded, it would be safe. There is another issue with this SRCU change: The notification comes actually after the real change, which is bad. We try to make the TSC usable by backing it with pm_timer accross such states, but this behaviour breaks the safety code. tglx - 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/