From: Jagan Teki <jagan@amarulasolutions.com>
To: u-boot@lists.denx.de
Subject: [RFC 2/7] clk: rk3399: Enable/Disable the USB2PHY clk
Date: Fri, 1 May 2020 03:15:24 +0530 [thread overview]
Message-ID: <20200430214529.18887-3-jagan@amarulasolutions.com> (raw)
In-Reply-To: <20200430214529.18887-1-jagan@amarulasolutions.com>
Enable/Disable the USB2PHY clk for rk3399.
CLK is clear in enable and set in disable functionality.
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
---
drivers/clk/rockchip/clk_rk3399.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/clk/rockchip/clk_rk3399.c b/drivers/clk/rockchip/clk_rk3399.c
index 7feba92f9e..b1c89ea127 100644
--- a/drivers/clk/rockchip/clk_rk3399.c
+++ b/drivers/clk/rockchip/clk_rk3399.c
@@ -1091,6 +1091,12 @@ static int rk3399_clk_enable(struct clk *clk)
case SCLK_MACREF_OUT:
rk_clrreg(&priv->cru->clkgate_con[5], BIT(6));
break;
+ case SCLK_USB2PHY0_REF:
+ rk_clrreg(&priv->cru->clkgate_con[6], BIT(5));
+ break;
+ case SCLK_USB2PHY1_REF:
+ rk_clrreg(&priv->cru->clkgate_con[6], BIT(6));
+ break;
case ACLK_GMAC:
rk_clrreg(&priv->cru->clkgate_con[32], BIT(0));
break;
@@ -1167,6 +1173,12 @@ static int rk3399_clk_disable(struct clk *clk)
case SCLK_MACREF_OUT:
rk_setreg(&priv->cru->clkgate_con[5], BIT(6));
break;
+ case SCLK_USB2PHY0_REF:
+ rk_setreg(&priv->cru->clkgate_con[6], BIT(5));
+ break;
+ case SCLK_USB2PHY1_REF:
+ rk_setreg(&priv->cru->clkgate_con[6], BIT(6));
+ break;
case ACLK_GMAC:
rk_setreg(&priv->cru->clkgate_con[32], BIT(0));
break;
--
2.17.1
next prev parent reply other threads:[~2020-04-30 21:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-30 21:45 [RFC 0/7] rockchip: Add PHY drivers Jagan Teki
2020-04-30 21:45 ` [RFC 1/7] phy: Add Rockchip PCIe PHY driver Jagan Teki
2020-04-30 21:45 ` Jagan Teki [this message]
2020-04-30 21:45 ` [RFC 3/7] phy: rockchip: Add Rockchip USB2PHY driver Jagan Teki
2020-04-30 21:45 ` [RFC 4/7] arm64: dts: rk3399: Move u2phy into root port Jagan Teki
2020-04-30 21:45 ` [RFC 5/7] arm64: dts: rk3399: Move pcie_phy " Jagan Teki
2020-04-30 21:45 ` [RFC 6/7] pci: rockchip: Switch to generic-phy Jagan Teki
2020-04-30 21:45 ` [RFC 7/7] pci: rockchip: Drop legacy PHY driver Jagan Teki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200430214529.18887-3-jagan@amarulasolutions.com \
--to=jagan@amarulasolutions.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox