[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20121106090137.GH5044@opensource.wolfsonmicro.com>
Date: Tue, 6 Nov 2012 10:01:38 +0100
From: Mark Brown <broonie@...nsource.wolfsonmicro.com>
To: Qing Xu <qingx@...vell.com>
Cc: lrg@...com, sameo@...ux.intel.com, grant.likely@...retlab.ca,
rob.herring@...xeda.com, haojian.zhuang@...il.com,
cxie4@...vell.com, linux-kernel@...r.kernel.org,
devicetree-discuss@...ts.ozlabs.org
Subject: Re: [PATCH 5/7] mfd: max8925: support dt for regulator
On Tue, Nov 06, 2012 at 03:44:52PM +0800, Qing Xu wrote:
> From: Qing Xu <qingx@...vell.com>
>
> Signed-off-by: Qing Xu <qingx@...vell.com>
> ---
> drivers/regulator/max8925-regulator.c | 35 ++++++++++++++++++++++++++++++++-
> 1 files changed, 34 insertions(+), 1 deletions(-)
There is no binding document here, documentation is required for all new
bindings.
> + nproot = of_find_node_by_name(nproot, "regulators");
> + if (!nproot) {
> + dev_err(&pdev->dev, "failed to find regulators node\n");
> + return -ENODEV;
> + }
> + for_each_child_of_node(nproot, np) {
> + if (!of_node_cmp(np->name, info->desc.name)) {
> + config->init_data =
> + of_get_regulator_init_data(&pdev->dev, np);
> + config->of_node = np;
> + break;
> + }
> + }
You appear to be open coding something like the standard helpers in
of_regulator.h, you should use those helpers.
Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)
Powered by blists - more mailing lists