[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150720173153.GH11162@sirena.org.uk>
Date: Mon, 20 Jul 2015 18:31:53 +0100
From: Mark Brown <broonie@...nel.org>
To: Henry Chen <henryc.chen@...iatek.com>
Cc: Liam Girdwood <lgirdwood@...il.com>,
Matthias Brugger <matthias.bgg@...il.com>,
Mark Rutland <mark.rutland@....com>,
Sascha Hauer <kernel@...gutronix.de>,
linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org, eddie.huang@...iatek.com,
srv_heupstream@...iatek.com
Subject: Re: [PATCH 2/2] regulator: MT6311: Add support for MT6311 regulator
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.
>
> +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 = of_get_child_by_name(dev->of_node, "regulators");
> + if (!node) {
> + dev_err(dev, "regulators node not found\n");
> + return ERR_PTR(-ENODEV);
> + }
> +
> + num = 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.
Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)
Powered by blists - more mailing lists