From f4740d0ff87498244adddba3e2449e720cb2d70b Mon Sep 17 00:00:00 2001 From: Kevin Kim Date: Thu, 11 Oct 2018 16:44:04 +0900 Subject: [PATCH] Revert "ODROID-C3: usb/phy: GPIO pin init for usb3.0 hub enable/reset." Change-Id: I5053768a046418ae06b4500ccf62f3d3c9cce2cf --- .../dts/amlogic/mesong12_odroid_common.dtsi | 6 +--- drivers/amlogic/usb/phy/phy-aml-new-usb3-v2.c | 30 ------------------- 2 files changed, 1 insertion(+), 35 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/mesong12_odroid_common.dtsi b/arch/arm64/boot/dts/amlogic/mesong12_odroid_common.dtsi index 4f2cc44e781e..46426965a18f 100644 --- a/arch/arm64/boot/dts/amlogic/mesong12_odroid_common.dtsi +++ b/arch/arm64/boot/dts/amlogic/mesong12_odroid_common.dtsi @@ -297,11 +297,7 @@ portnum = <1>; otg = <1>; gpio-vbus-power = "GPIOH_6"; - hub-en = "GPIOH_5"; - hub-rst = "GPIOH_4"; - gpios = <&gpio GPIOH_6 GPIO_ACTIVE_HIGH - &gpio GPIOH_5 GPIO_ACTIVE_HIGH - &gpio GPIOH_4 GPIO_ACTIVE_HIGH>; + gpios = <&gpio GPIOH_6 GPIO_ACTIVE_HIGH>; }; &dwc3 { diff --git a/drivers/amlogic/usb/phy/phy-aml-new-usb3-v2.c b/drivers/amlogic/usb/phy/phy-aml-new-usb3-v2.c index bf15ed17258a..3f360b589a79 100644 --- a/drivers/amlogic/usb/phy/phy-aml-new-usb3-v2.c +++ b/drivers/amlogic/usb/phy/phy-aml-new-usb3-v2.c @@ -491,10 +491,6 @@ static int amlogic_new_usb3_v2_probe(struct platform_device *pdev) int otg = 0; int ret; struct device_node *tsi_pci; -#if defined(CONFIG_ARCH_MESON64_ODROID_COMMON) - struct gpio_desc *huben_gd = NULL; - struct gpio_desc *hubrst_gd = NULL; -#endif gpio_name = of_get_property(dev->of_node, "gpio-vbus-power", NULL); if (gpio_name) { @@ -505,32 +501,6 @@ static int amlogic_new_usb3_v2_probe(struct platform_device *pdev) return -1; } -#if defined(CONFIG_ARCH_MESON64_ODROID_COMMON) - gpio_name = of_get_property(dev->of_node, "hub-en", NULL); - if (gpio_name) { - huben_gd = gpiod_get_index(&pdev->dev, - NULL, 1, GPIOD_OUT_HIGH); - if (IS_ERR(huben_gd)) - return -1; - gpiod_direction_output(huben_gd, 1); - mdelay(20); - gpiod_put(huben_gd); - } - - gpio_name = of_get_property(dev->of_node, "hub-rst", NULL); - if (gpio_name) { - hubrst_gd = gpiod_get_index(&pdev->dev, - NULL, 2, GPIOD_OUT_HIGH); - if (IS_ERR(hubrst_gd)) - return -1; - gpiod_direction_output(hubrst_gd, 0); - mdelay(20); - gpiod_direction_output(hubrst_gd, 1); - mdelay(20); - gpiod_put(hubrst_gd); - } -#endif - prop = of_get_property(dev->of_node, "portnum", NULL); if (prop) portnum = of_read_ulong(prop, 1);