diff options
author | Rob Herring <robh@kernel.org> | 2018-12-05 20:50:37 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-12-06 20:56:51 +0100 |
commit | c32569e358adea225f053ef9d97a4c8c18be8743 (patch) | |
tree | 7bf7a137177f49182556d5c375384cd91f0c4369 /drivers/regulator/max8997-regulator.c | |
parent | regulator: Allow regulator nodes to contain their own init data (diff) | |
download | linux-c32569e358adea225f053ef9d97a4c8c18be8743.tar.xz linux-c32569e358adea225f053ef9d97a4c8c18be8743.zip |
regulator: Use of_node_name_eq for node name comparisons
Convert string compares of DT node names to use of_node_name_eq helper
instead. This removes direct access to the node name pointer.
For instances using of_node_cmp, this has the side effect of now using
case sensitive comparisons. This should not matter for any FDT based
system which all of these are.
Cc: Liam Girdwood <lgirdwood@gmail.com>
Cc: Mark Brown <broonie@kernel.org>
Cc: Support Opensource <support.opensource@diasemi.com>
Cc: Sangbeom Kim <sbkim73@samsung.com>
Cc: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Cc: linux-samsung-soc@vger.kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/regulator/max8997-regulator.c')
-rw-r--r-- | drivers/regulator/max8997-regulator.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/max8997-regulator.c b/drivers/regulator/max8997-regulator.c index 3bf5ddfaaea8..4d2487279a0a 100644 --- a/drivers/regulator/max8997-regulator.c +++ b/drivers/regulator/max8997-regulator.c @@ -925,7 +925,7 @@ static int max8997_pmic_dt_parse_pdata(struct platform_device *pdev, pdata->regulators = rdata; for_each_child_of_node(regulators_np, reg_np) { for (i = 0; i < ARRAY_SIZE(regulators); i++) - if (!of_node_cmp(reg_np->name, regulators[i].name)) + if (of_node_name_eq(reg_np, regulators[i].name)) break; if (i == ARRAY_SIZE(regulators)) { |