Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932302AbbGTRcG (ORCPT ); Mon, 20 Jul 2015 13:32:06 -0400 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:60285 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932232AbbGTRcD (ORCPT ); Mon, 20 Jul 2015 13:32:03 -0400 Date: Mon, 20 Jul 2015 18:31:53 +0100 From: Mark Brown To: Henry Chen Cc: Liam Girdwood , Matthias Brugger , Mark Rutland , Sascha Hauer , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, eddie.huang@mediatek.com, srv_heupstream@mediatek.com Message-ID: <20150720173153.GH11162@sirena.org.uk> References: <1437377793-31558-1-git-send-email-henryc.chen@mediatek.com> <1437377793-31558-3-git-send-email-henryc.chen@mediatek.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="4CWDppHhC4Mjf/wW" Content-Disposition: inline In-Reply-To: <1437377793-31558-3-git-send-email-henryc.chen@mediatek.com> X-Cookie: Stay together, drag each other down. User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: 94.175.94.161 X-SA-Exim-Mail-From: broonie@sirena.org.uk Subject: Re: [PATCH 2/2] regulator: MT6311: Add support for MT6311 regulator 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: 2280 Lines: 65 --4CWDppHhC4Mjf/wW Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jul 20, 2015 at 03:36:33PM +0800, Henry Chen wrote: > @@ -460,6 +460,15 @@ config REGULATOR_MT6397 > This driver supports the control of different power rails of device > through regulator interface. > =20 > +config REGULATOR_MT6311 > + tristate "MediaTek MT6311 PMIC" Please keep these files sorted, MT6311 should be before MT6397. > +static struct mt6311_pdata *mt6311_parse_regulators_dt( > + struct device *dev) > +{ > + struct mt6311_pdata *pdata; > + struct device_node *node; > + int i, num, n; > + > + node =3D of_get_child_by_name(dev->of_node, "regulators"); > + if (!node) { > + dev_err(dev, "regulators node not found\n"); > + return ERR_PTR(-ENODEV); > + } > + > + num =3D of_regulator_match(dev, node, mt6311_matches, > + ARRAY_SIZE(mt6311_matches)); Please convert this to use the modern method of specifying the regulator DT bindings by providing of_match and regulators_node in the regulator_desc so the core does the mapping for yand regulators_node in the regulator_desc so the core does the mapping for yand regulators_node in the regulator_desc so the core does the mapping for yand regulators_node in the regulator_desc so the core does the mapping for you and you can delete the DT handling code. Otherwise this driver looks good. --4CWDppHhC4Mjf/wW Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJVrTCIAAoJECTWi3JdVIfQwQcH/jNzF+W90E3EW2zhhAL/zuf3 tB3Ja2hWt6duARJmVOX9CKum0/wcEcNg7Lodz8w79f58APLSHDb6AVJiIMmYDF1V nCUnJlkVCNjbKJNY0SJlMIjj6rcv4b1xfH6KcoSltCJd2PL+sKDs7LaPKaMasXhQ 14dYEWAyntUFnQsGvCO0fvZa69gTxvMsDZ9DKOvYYdPdRsGtuGyKaHqv1hixo6aZ dMzh2cKuXCagTzjycpc97beZLMmGZemawgLfyNG/LEWpsNrfSS2XE/N5NGcKLbpM 16c77j8Uaip/hjDjbBPiH7hNlMC3ZDDA2u3YyQGIxxFAUwR0zYKIPF412GfIf/M= =qP36 -----END PGP SIGNATURE----- --4CWDppHhC4Mjf/wW-- -- 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/