]> Git Repo - linux.git/commitdiff
USB: chipidea: msm: fix ulpi-node lookup
authorJohan Hovold <[email protected]>
Mon, 13 Nov 2017 10:12:58 +0000 (11:12 +0100)
committerPeter Chen <[email protected]>
Wed, 13 Dec 2017 01:50:52 +0000 (09:50 +0800)
Fix child-node lookup during probe, which ended up searching the whole
device tree depth-first starting at the parent rather than just matching
on its children.

Note that the original premature free of the parent node has already
been fixed separately, but that fix was apparently never backported to
stable.

Fixes: 47654a162081 ("usb: chipidea: msm: Restore wrapper settings after reset")
Fixes: b74c43156c0c ("usb: chipidea: msm: ci_hdrc_msm_probe() missing of_node_get()")
Cc: stable <[email protected]> # 4.10: b74c43156c0c
Cc: Stephen Boyd <[email protected]>
Cc: Frank Rowand <[email protected]>
Signed-off-by: Johan Hovold <[email protected]>
Signed-off-by: Peter Chen <[email protected]>
drivers/usb/chipidea/ci_hdrc_msm.c

index 3593ce0ec641d848f1a15438ffb76295558ab9a6..880009987460affefa3aac2bf61aee6174195f81 100644 (file)
@@ -247,7 +247,7 @@ static int ci_hdrc_msm_probe(struct platform_device *pdev)
        if (ret)
                goto err_mux;
 
-       ulpi_node = of_find_node_by_name(of_node_get(pdev->dev.of_node), "ulpi");
+       ulpi_node = of_get_child_by_name(pdev->dev.of_node, "ulpi");
        if (ulpi_node) {
                phy_node = of_get_next_available_child(ulpi_node, NULL);
                ci->hsic = of_device_is_compatible(phy_node, "qcom,usb-hsic-phy");
This page took 0.060515 seconds and 4 git commands to generate.