lkml.org 
[lkml]   [2014]   [Nov]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/5] regulator: rt5033: Add RT5033 Regulator device driver
On Fri, Nov 07, 2014 at 11:52:04AM +0900, Beomho Seo wrote:

> +static int rt5033_regulator_dt_parse_data(struct device *dev)
> +{
> + int ret;
> + struct device_node *np;
> +
> + np = of_get_child_by_name(dev->parent->of_node, "regulators");
> + if (!np) {
> + dev_err(dev, "Failed to get child node for regulators\n");
> + return -EINVAL;
> + }
> +
> + ret = of_regulator_match(dev, np, rt5033_regulator_matches,
> + ARRAY_SIZE(rt5033_regulator_matches));
> + if (ret < 0)
> + return ret;

Please convert this to use regulators_node in the descriptor to match
the regulators, then you don't need any specific code.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2014-11-07 12:01    [W:0.063 / U:0.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site