Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

pmdomain: imx: gpcv2: use proper helper for property detection

Starting with commit c141ecc3cecd7 ("of: Warn when of_property_read_bool()
is used on non-boolean properties"), probing the gpcv2 device on i.MX8M
SoCs leads to warnings when LOCKDEP is enabled.

Fix this by checking property presence with of_property_present as
intended.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Link: https://lore.kernel.org/r/20250218-gpcv2-of-property-present-v1-1-3bb1a9789654@pengutronix.de
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

authored by

Ahmad Fatoum and committed by
Ulf Hansson
6568cb40 6d137f81

+1 -1
+1 -1
drivers/pmdomain/imx/gpcv2.c
··· 1361 1361 } 1362 1362 1363 1363 if (IS_ENABLED(CONFIG_LOCKDEP) && 1364 - of_property_read_bool(domain->dev->of_node, "power-domains")) 1364 + of_property_present(domain->dev->of_node, "power-domains")) 1365 1365 lockdep_set_subclass(&domain->genpd.mlock, 1); 1366 1366 1367 1367 ret = of_genpd_add_provider_simple(domain->dev->of_node,