From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753390AbbJZIRQ (ORCPT ); Mon, 26 Oct 2015 04:17:16 -0400 Received: from mail-oi0-f46.google.com ([209.85.218.46]:35263 "EHLO mail-oi0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753250AbbJZIQt (ORCPT ); Mon, 26 Oct 2015 04:16:49 -0400 MIME-Version: 1.0 In-Reply-To: <1442844182-27787-5-git-send-email-tomeu.vizoso@collabora.com> References: <1442844182-27787-1-git-send-email-tomeu.vizoso@collabora.com> <1442844182-27787-5-git-send-email-tomeu.vizoso@collabora.com> Date: Mon, 26 Oct 2015 09:16:48 +0100 X-Google-Sender-Auth: Jv50emPVix8n0osTnA10HTxSDkM Message-ID: Subject: Re: [PATCH v6 04/22] of: add function to allow probing a device from a OF node From: Geert Uytterhoeven To: Tomeu Vizoso Cc: "linux-kernel@vger.kernel.org" , "devicetree@vger.kernel.org" , ACPI Devel Maling List , Arnd Bergmann , Stephen Warren , Greg Kroah-Hartman , Linus Walleij , Dmitry Torokhov , "Rafael J. Wysocki" , Rob Herring , Javier Martinez Canillas , Mark Brown , Thierry Reding , Alan Stern , "linux-arm-kernel@lists.infradead.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 21, 2015 at 4:02 PM, Tomeu Vizoso wrote: > Walks the OF tree up and finds the closest ancestor that has a struct > device associated with it, probing it if isn't bound to a driver yet. > > The above should ensure that the dependency represented by the passed OF > node is available, because probing a device should cause its descendants > to be probed as well (when they get registered). > > Subsystems can use this when looking up resources for drivers, to reduce > the chances of deferred probes because of the probing order of devices. > > Signed-off-by: Tomeu Vizoso Don't know to which response I should post this comment, so I'm responding to the original email. Some subsystems already do this. If you call e.g. syscon_regmap_lookup_by_phandle(), it will call of_syscon_register() if the syscon device pointed to hasn't been registered yet. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds