[PATCH] phy: rockchip-inno-usb2: cleanup comments and make ops static

Xavier Drudis Ferran xdrudis at tinet.cat
Mon Jun 19 09:24:41 CEST 2023


Thanks to Jagan Teki for noting that three functions should be static
and comments from uclass_clk are redundant.

Signed-off-by: Xavier Drudis Ferran <xdrudis at tinet.cat>
---
 drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 25 +++----------------
 1 file changed, 3 insertions(+), 22 deletions(-)

diff --git a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
index be5f79490c..2b33b6f03c 100644
--- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
+++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
@@ -182,25 +182,12 @@ static struct phy_ops rockchip_usb2phy_ops = {
 	.of_xlate = rockchip_usb2phy_of_xlate,
 };
 
-/**
- * round_rate() - Adjust a rate to the exact rate a clock can provide.
- * @clk:	The clock to manipulate.
- * @rate:	Desidered clock rate in Hz.
- *
- * Return: rounded rate in Hz, or -ve error code.
- */
-ulong rockchip_usb2phy_clk_round_rate(struct clk *clk, ulong rate)
+static ulong rockchip_usb2phy_clk_round_rate(struct clk *clk, ulong rate)
 {
 	return 480000000;
 }
 
-/**
- * enable() - Enable a clock.
- * @clk:	The clock to manipulate.
- *
- * Return: zero on success, or -ve error code.
- */
-int rockchip_usb2phy_clk_enable(struct clk *clk)
+static int rockchip_usb2phy_clk_enable(struct clk *clk)
 {
 	struct udevice *parent = dev_get_parent(clk->dev);
 	struct rockchip_usb2phy *priv = dev_get_priv(parent);
@@ -217,13 +204,7 @@ int rockchip_usb2phy_clk_enable(struct clk *clk)
 	return 0;
 }
 
-/**
- * disable() - Disable a clock.
- * @clk:	The clock to manipulate.
- *
- * Return: zero on success, or -ve error code.
- */
-int rockchip_usb2phy_clk_disable(struct clk *clk)
+static int rockchip_usb2phy_clk_disable(struct clk *clk)
 {
 	struct udevice *parent = dev_get_parent(clk->dev);
 	struct rockchip_usb2phy *priv = dev_get_priv(parent);
-- 
2.20.1


More information about the U-Boot mailing list