staging: hikey9xx: phy-hi3670-usb3: change some DT properties
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 17 Sep 2020 10:42:11 +0000 (12:42 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Sep 2020 16:50:26 +0000 (18:50 +0200)
Do some changes at the DT properties in order to make it
follow the phy-hi3660-usb3 example and to simplify
usb3-phy-tx-vboost-lvl name.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/da128b9943bcb6a3d44a9512cedc7fa7a4aedee6.1600338981.git.mchehab+huawei@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/hikey9xx/phy-hi3670-usb3.c

index cb0bfcbbfbfab3972c5457060bf33ef76a0ab83f..42dbc20a0b9aa82d298b9ce9acdb929eff1e68b7 100644 (file)
@@ -627,18 +627,18 @@ static int hi3670_phy_probe(struct platform_device *pdev)
                return PTR_ERR(priv->sctrl);
        }
 
-       priv->usb31misc = syscon_regmap_lookup_by_phandle(dev->of_node,
-                                                         "hisilicon,usb31-misc-syscon");
+       /* node of hi3670 phy is a sub-node of usb3_otg_bc */
+       priv->usb31misc = syscon_node_to_regmap(dev->parent->of_node);
        if (IS_ERR(priv->usb31misc)) {
-               dev_err(dev, "no hisilicon,usb31-misc-syscon\n");
+               dev_err(dev, "no hisilicon,usb3-otg-bc-syscon\n");
                return PTR_ERR(priv->usb31misc);
        }
 
-       if (of_property_read_u32(dev->of_node, "eye-diagram-param",
+       if (of_property_read_u32(dev->of_node, "hisilicon,eye-diagram-param",
                                 &priv->eye_diagram_param))
                priv->eye_diagram_param = KIRIN970_USB_DEFAULT_PHY_PARAM;
 
-       if (of_property_read_u32(dev->of_node, "usb3-phy-tx-vboost-lvl",
+       if (of_property_read_u32(dev->of_node, "hisilicon,tx-vboost-lvl",
                                 &priv->tx_vboost_lvl))
                priv->eye_diagram_param = KIRIN970_USB_DEFAULT_PHY_VBOOST;