From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1945933AbbHGRHd (ORCPT ); Fri, 7 Aug 2015 13:07:33 -0400 Received: from bear.ext.ti.com ([192.94.94.41]:41128 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932315AbbHGRHO (ORCPT ); Fri, 7 Aug 2015 13:07:14 -0400 Message-ID: <55C4E597.1010701@ti.com> Date: Fri, 7 Aug 2015 20:06:31 +0300 From: Grygorii Strashko User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.8.0 MIME-Version: 1.0 To: Tomeu Vizoso , Rob Herring CC: "devicetree@vger.kernel.org" , "linux-acpi@vger.kernel.org" , Arnd Bergmann , Stephen Warren , Linus Walleij , Dmitry Torokhov , "Rafael J. Wysocki" , "linux-kernel@vger.kernel.org" , Rob Herring , Javier Martinez Canillas , Mark Brown , Thierry Reding , "linux-arm-kernel@lists.infradead.org" Subject: Re: [PATCH v3 01/18] platform: delay OF device-driver matches until late_initcall References: <1438870315-18689-1-git-send-email-tomeu.vizoso@collabora.com> <1438870315-18689-2-git-send-email-tomeu.vizoso@collabora.com> In-Reply-To: Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 08/07/2015 10:11 AM, Tomeu Vizoso wrote: > On 6 August 2015 at 22:19, Rob Herring wrote: >> On Thu, Aug 6, 2015 at 9:11 AM, Tomeu Vizoso wrote: >>> Delay matches of platform devices with OF nodes until late_initcall, >>> when we are sure that all built-in drivers have been registered already. >>> This is needed to prevent deferred probes because of some drivers not >>> having registered yet. >>> >>> The reason why only platform devices are delayed is that some other >>> devices are expected to be probed earlier than late_initcall, for >>> example, the system PNP driver needs to probe its devices in >>> fs_initcall. >>> >>> Additionally, only platform devices with OF nodes are delayed because >>> some machines may depend on oter platform devices being registered at >>> specific times. >> >> How do we know that these probes occur before the unused clocks and >> regulators are turned off? Just getting lucky (as is deferred probe)? >> Can we do this one level earlier so we have a level left to do things >> after probe. > > Those are already late_initcall_sync so I guess we're fine. I wouldn't be so sure :( FYI: http://git.ti.com/ti-linux-kernel/ti-linux-kernel/commit/763d643bbfc0f445c6685c541fcae3c370e4314a -- regards, -grygorii