[PATCH 04/10] regulator: of: switch to using class_find_device_by_fwnode()

Dmitry Torokhov <[email protected]> Sun, 22 Mar 2026 18:54:22 -0700
Newsgroups org.kernel.vger.linux-fpga,dev.linux.lists.driver-core,org.infradead.lists.linux-phy,org.kernel.vger.linux-kernel,org.kernel.vger.linux-leds,org.kernel.vger.linux-spi,org.kernel.vger.netdev
Message-ID <20260322-remove-device-find-by-of-node-v1-4-b72eb22a1215@gmail.com>
In preparation to class_find_device_by_of_node() going away switch to
using class_find_device_by_fwnode().

Signed-off-by: Dmitry Torokhov <[email protected]>
---
 drivers/regulator/of_regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/of_regulator.c b/drivers/regulator/of_regulator.c
index c0cc6cc0afd8..43ec0845c940 100644
--- a/drivers/regulator/of_regulator.c
+++ b/drivers/regulator/of_regulator.c
@@ -637,7 +637,7 @@ static struct regulator_dev *of_find_regulator_by_node(struct device_node *np)
 {
 	struct device *dev;
 
-	dev = class_find_device_by_of_node(&regulator_class, np);
+	dev = class_find_device_by_fwnode(&regulator_class, of_fwnode_handle(np));
 
 	return dev ? dev_to_rdev(dev) : NULL;
 }

-- 
2.53.0.959.g497ff81fa9-goog