Merge tag 'usb-6.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
[platform/kernel/linux-starfive.git] / drivers / usb / typec / anx7411.c
index e205f40..b8f3b75 100644 (file)
@@ -1105,7 +1105,7 @@ static int anx7411_typec_switch_probe(struct anx7411_data *ctx,
        int ret;
        struct device_node *node;
 
-       node = of_find_node_by_name(dev->of_node, "orientation_switch");
+       node = of_get_child_by_name(dev->of_node, "orientation_switch");
        if (!node)
                return 0;
 
@@ -1115,7 +1115,7 @@ static int anx7411_typec_switch_probe(struct anx7411_data *ctx,
                return ret;
        }
 
-       node = of_find_node_by_name(dev->of_node, "mode_switch");
+       node = of_get_child_by_name(dev->of_node, "mode_switch");
        if (!node) {
                dev_err(dev, "no typec mux exist");
                ret = -ENODEV;