From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753073AbbHGMTh (ORCPT ); Fri, 7 Aug 2015 08:19:37 -0400 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:32831 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750735AbbHGMTf (ORCPT ); Fri, 7 Aug 2015 08:19:35 -0400 Date: Fri, 7 Aug 2015 13:19:13 +0100 From: Mark Brown To: Tomeu Vizoso Cc: linux-kernel@vger.kernel.org, Rob Herring , Stephen Warren , Javier Martinez Canillas , Thierry Reding , "Rafael J. Wysocki" , linux-arm-kernel@lists.infradead.org, Dmitry Torokhov , devicetree@vger.kernel.org, Linus Walleij , linux-acpi@vger.kernel.org, Arnd Bergmann Message-ID: <20150807121913.GS20873@sirena.org.uk> References: <1438870315-18689-1-git-send-email-tomeu.vizoso@collabora.com> <1438870315-18689-3-git-send-email-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="Eyt/adkQmNUuLj+l" Content-Disposition: inline In-Reply-To: <1438870315-18689-3-git-send-email-tomeu.vizoso@collabora.com> X-Cookie: Please take note: User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: 146.198.193.35 X-SA-Exim-Mail-From: broonie@sirena.org.uk Subject: Re: [PATCH v3 02/18] of/platform: add of_platform_probe X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on mezzanine.sirena.org.uk) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --Eyt/adkQmNUuLj+l Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Aug 06, 2015 at 04:11:39PM +0200, Tomeu Vizoso wrote: > Walks the OF tree up and finds the closest ancestor that has a platform > 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 platform device should cause its > descendants to be probed as well. This sounds like it's going to break in the case where we have MFDs that represent their functions in DT (not a pattern I'm a fan of but it's a thing people do). We'll walk back to the platform device for the MFD function, try to probe it and then give up. Perhaps that's good enough anyway but it's not clear to me why we don't just try every parent we find? I'm also not a fan of the fact that the interface here is explicitly saying that we want to probe a platform device, that's an implementation detail that callers shouldn't need to know about. From the point of view of the callers what they're trying to do is kick any dependencies into being instantiated, the fact that we currently try to accomplish it with platform devices isn't something they care about. --Eyt/adkQmNUuLj+l Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJVxKJAAAoJECTWi3JdVIfQgzMH+wRH8m35h1fgololbPQJ40+Z 03tYcjBBpwQUa8upmWcOlkzA8pFDUYQpMh4ewr3cAQsjybStngo8x+chJ3kqpswc C5LG1d/BonT2OJOANArLNfQdNoi0GQ77gBkpKVzWu3fzQaURHBfOwH3kB4b50TLY p6FlDJrPQt1ThWV/riNrRx/Cbem2BDPjrrzDRoK5ujAppc/otK4OLHZKiBtkQG1f RipxHP3QFpoV3bhI05E1ZP+BYVCU2wumJ2x3rlLzLj9E59DSN/YoyvTVFh9DZHdO hRZFhf2O0unK3zsDK9h1iebu2JrYJ3KHQFuAqf1C44C8Lbpo1/7qShhJjoaA0Uk= =gfpn -----END PGP SIGNATURE----- --Eyt/adkQmNUuLj+l--