From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kevin Hilman Subject: Re: [PATCH] OMAP3: PM: introduce a new powerdomain walk helper Date: Mon, 05 Oct 2009 09:46:52 -0700 Message-ID: <87r5th23gj.fsf@deeprootsystems.com> References: <1254380515-32175-1-git-send-email-dedekind1@gmail.com> <4AC9D5F1.8080400@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mail-pz0-f188.google.com ([209.85.222.188]:40074 "EHLO mail-pz0-f188.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753626AbZJEQrc (ORCPT ); Mon, 5 Oct 2009 12:47:32 -0400 Received: by pzk26 with SMTP id 26so2908657pzk.4 for ; Mon, 05 Oct 2009 09:46:55 -0700 (PDT) In-Reply-To: <4AC9D5F1.8080400@gmail.com> (Artem Bityutskiy's message of "Mon\, 05 Oct 2009 14\:18\:09 +0300") Sender: linux-omap-owner@vger.kernel.org List-Id: linux-omap@vger.kernel.org To: Artem Bityutskiy Cc: Tony Lindgren , linux-omap@vger.kernel.org, Artem Bityutskiy Artem Bityutskiy writes: > On 10/01/2009 10:01 AM, Artem Bityutskiy wrote: >> From: Artem Bityutskiy >> >> The 'pwrdm_for_each()' function walks powerdomains with a spinlock >> locked, so the the callbacks cannot do anything which may sleep. >> This patch introduces a 'pwrdm_for_each_nolock()' helper which does >> the same, but without the spinlock locked. This fixes the following >> lockdep warning: >> >> [ 0.000000] WARNING: at kernel/lockdep.c:2460 lockdep_trace_alloc+0xac/0xec() >> [ 0.000000] Modules linked in: >> (unwind_backtrace+0x0/0xdc) from [] (warn_slowpath_common+0x48/0x60) >> (warn_slowpath_common+0x48/0x60) from [] (lockdep_trace_alloc+0xac/0xec) >> (lockdep_trace_alloc+0xac/0xec) from [] (kmem_cache_alloc+0x1c/0xd0) >> (kmem_cache_alloc+0x1c/0xd0) from [] (d_alloc+0x1c/0x1a4) >> (d_alloc+0x1c/0x1a4) from [] (__lookup_hash+0xd8/0x118) >> (__lookup_hash+0xd8/0x118) from [] (lookup_one_len+0x84/0x94) >> (lookup_one_len+0x84/0x94) from [] (debugfs_create_file+0x8c/0x20c) >> (debugfs_create_file+0x8c/0x20c) from [] (debugfs_create_dir+0x1c/0x20) >> (debugfs_create_dir+0x1c/0x20) from [] (pwrdms_setup+0x60/0x90) >> (pwrdms_setup+0x60/0x90) from [] (pwrdm_for_each+0x30/0x80) >> (pwrdm_for_each+0x30/0x80) from [] (pm_dbg_init+0x7c/0x14c) >> (pm_dbg_init+0x7c/0x14c) from [] (do_one_initcall+0x5c/0x1b8) >> (do_one_initcall+0x5c/0x1b8) from [] (kernel_init+0x90/0x10c) >> (kernel_init+0x90/0x10c) from [] (kernel_thread_exit+0x0/0x8) >> >> Signed-off-by: Artem Bityutskiy > > I guess this patch was actually for Tony, as this warning is seen on l-o. > Tony, any plans to pick this up? Actually, I'll queue this in my PM fixes queue for the -rc series. Kevin