ath79: phy: remove named gpio exports
authorRosen Penev <rosenp@gmail.com>
Mon, 23 Dec 2024 21:35:01 +0000 (13:35 -0800)
committerHauke Mehrtens <hauke@hauke-m.de>
Sun, 12 Jan 2025 17:01:35 +0000 (18:01 +0100)
The only real user of this patch was removed and migrated to the
upstream friendly regulator. Remove this hack.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17356
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/ath79/patches-6.6/700-phy-add-ath79-usb-phys.patch

index b50e4b51a45c4618885b69ce4b66b6d871a2ca32..1c1b2f2ca1ba81f56019ea7c73841dd89e574bca 100644 (file)
@@ -51,7 +51,7 @@ Signed-off-by: John Crispin <john@phrozen.org>
  obj-$(CONFIG_PHY_LPC18XX_USB_OTG)     += phy-lpc18xx-usb-otg.o
 --- /dev/null
 +++ b/drivers/phy/phy-ar7100-usb.c
-@@ -0,0 +1,127 @@
+@@ -0,0 +1,117 @@
 +/*
 + * Copyright (C) 2018 John Crispin <john@phrozen.org>
 + *
@@ -144,16 +144,6 @@ Signed-off-by: John Crispin <john@phrozen.org>
 +      if (IS_ERR(priv->phy))
 +              return dev_err_probe(&pdev->dev, PTR_ERR(priv->phy), "failed to create PHY");
 +
-+      priv->gpio = of_get_named_gpio(pdev->dev.of_node, "gpios", 0);
-+      if (gpio_is_valid(priv->gpio)) {
-+              int ret = devm_gpio_request(&pdev->dev, priv->gpio, dev_name(&pdev->dev));
-+              if (ret)
-+                      return dev_err_probe(&pdev->dev, ret, "failed to request gpio");
-+
-+              gpio_export_with_name(gpio_to_desc(priv->gpio), 0, dev_name(&pdev->dev));
-+              gpio_set_value(priv->gpio, 1);
-+      }
-+
 +      phy_set_drvdata(priv->phy, priv);
 +
 +      phy_provider = devm_of_phy_provider_register(&pdev->dev, of_phy_simple_xlate);
@@ -181,7 +171,7 @@ Signed-off-by: John Crispin <john@phrozen.org>
 +MODULE_LICENSE("GPL");
 --- /dev/null
 +++ b/drivers/phy/phy-ar7200-usb.c
-@@ -0,0 +1,120 @@
+@@ -0,0 +1,111 @@
 +/*
 + * Copyright (C) 2015 Alban Bedel <albeu@free.fr>
 + *
@@ -268,15 +258,6 @@ Signed-off-by: John Crispin <john@phrozen.org>
 +      if (IS_ERR(priv->phy))
 +              return dev_err_probe(&pdev->dev, PTR_ERR(priv->phy), "failed to create PHY");
 +
-+      priv->gpio = of_get_named_gpio(pdev->dev.of_node, "gpios", 0);
-+      if (gpio_is_valid(priv->gpio)) {
-+              int ret = devm_gpio_request(&pdev->dev, priv->gpio, dev_name(&pdev->dev));
-+              if (ret)
-+                      return dev_err_probe(&pdev->dev, ret, "failed to request gpio");
-+              gpio_export_with_name(gpio_to_desc(priv->gpio), 0, dev_name(&pdev->dev));
-+              gpio_set_value(priv->gpio, 1);
-+      }
-+
 +      phy_set_drvdata(priv->phy, priv);
 +
 +      phy_provider = devm_of_phy_provider_register(&pdev->dev, of_phy_simple_xlate);