Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754748AbbBLCde (ORCPT ); Wed, 11 Feb 2015 21:33:34 -0500 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:60748 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752457AbbBLCdc (ORCPT ); Wed, 11 Feb 2015 21:33:32 -0500 Date: Thu, 12 Feb 2015 10:32:52 +0800 From: Mark Brown To: Tim Bird Cc: =?iso-8859-1?B?IkFuZGVyc3NvbiwgQmr2cm4i?= , "lgirdwood@gmail.com" , "linux-kernel@vger.kernel.org" Message-ID: <20150212023252.GS2593@finisterre.sirena.org.uk> References: <54D3A96B.2020704@sonymobile.com> <20150205174353.GA21293@sirena.org.uk> <54D3B858.9060103@sonymobile.com> <20150205192740.GL21293@sirena.org.uk> <20150205220844.GA3218@sonymobile.com> <20150206003212.GR21293@sirena.org.uk> <20150206005239.GD3218@sonymobile.com> <20150206114953.GT21293@sirena.org.uk> <54D51C5D.7050708@sonymobile.com> <54DB8F9C.1070104@sonymobile.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="1IOPqZ3f1xe/JZlz" Content-Disposition: inline In-Reply-To: <54DB8F9C.1070104@sonymobile.com> X-Cookie: What is the sound of one hand clapping? User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: 210.177.145.249 X-SA-Exim-Mail-From: broonie@sirena.org.uk Subject: Re: [PATCH] regulator: Support different config and dev of_nodes in regulator_register 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 Content-Length: 2034 Lines: 52 --1IOPqZ3f1xe/JZlz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Feb 11, 2015 at 09:21:32AM -0800, Tim Bird wrote: > Also, when registering a regulator, you can pass a different > of_node in config (struct regulator_config) than the one in dev > (struct device) > However, this has problems in the current code, as the test in > regulator_dev_lookup requires that the device_node found by of_get_regulator() > match the dev.of_node in the regulator in the regulator list. ... > It took me a while to figure this out, because a regulator defined > with dev.of_node != config.of_node worked fine, when accessed > directly by name (not using a supply-name). I only had problems > when I accessed the regulator using the "-supply" indirection technique > in DT. I'm not quite sure exactly what you've done here but I'm pretty sure there's some confusion somewhere since the -supply based lookups are of course what everything in mainline is doing except for CPU supplies. The fact that you are using of_get_regulator_init_data() is a bit of a red flag here, you shouldn't have to use that unless your bindings are in some way unusual. --1IOPqZ3f1xe/JZlz Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJU3BDPAAoJECTWi3JdVIfQlFYH/A8XEnCCWO4iukYakKhhQFEH 40T51PDckEV++mJAfJDWdQac/0oXrN7ry7XSwjcxwFq4ir3BBGzIjL7cBJxMKnz5 vgFD3ZO+lLN+R7DWqPXQytw9jChOgw0X7qaPdctHKVz2MP7RlA6nkOuJESzzd9nz JbpmMvjJmkDl/SKCaw2tR+uIzntxIJiowphPsDNpMlUDluJ+yEHX3TPxbGXUpvwb +fm4Jtj44I4LfPb/PEisprruwOCP2vX/C1xtcOunG0dTx6hkBfI6oOEBHTlaC4oy rOssil+vRLcDzgwPOh+tPtFLHuuQoEJX/iNWzI3SBe7AKPOoGXBmkMlYdTtdSao= =D+Ko -----END PGP SIGNATURE----- --1IOPqZ3f1xe/JZlz-- -- 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/