diff options
author | Atlas Luo <atlas.luo@starfivetech.com> | 2025-04-22 11:04:18 +0300 |
---|---|---|
committer | Atlas Luo <atlas.luo@starfivetech.com> | 2025-04-22 11:04:18 +0300 |
commit | 37e783d70e94c91eda08d107cdb5e8f859bab13d (patch) | |
tree | 0ccc4bfe3f03fe011817a77e9aa602f1187344fb /drivers | |
parent | 406f6e7e89c1e18f64ac3495aa4fae60af78eaba (diff) | |
parent | 0b2f8d6f0d861403f996ff8d6a9b8cc743af7b2a (diff) | |
download | linux-JH7110_VisionFive2_6.6.y_devel.tar.xz |
Merge tag 'JH7110_SDK_6.6_v5.14.1' into vf2-6.6.y-develJH7110_VF2_6.6_v5.14.1JH7110_VisionFive2_6.6.y_devel
Update tag JH7110_SDK_6.6_v5.14.1
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/phy/starfive/phy-jh7110-usb.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/phy/starfive/phy-jh7110-usb.c b/drivers/phy/starfive/phy-jh7110-usb.c index 426a2d44272a..42dfd57a7fb2 100644 --- a/drivers/phy/starfive/phy-jh7110-usb.c +++ b/drivers/phy/starfive/phy-jh7110-usb.c @@ -18,6 +18,8 @@ #include <linux/usb/of.h> #define USB_125M_CLK_RATE 125000000 +#define USB_CLK_MODE_OFF 0x0 +#define USB_CLK_MODE_RX_NORMAL_PWR BIT(1) #define USB_LS_KEEPALIVE_OFF 0x4 #define USB_LS_KEEPALIVE_ENABLE BIT(4) @@ -78,6 +80,7 @@ static int jh7110_usb2_phy_init(struct phy *_phy) { struct jh7110_usb2_phy *phy = phy_get_drvdata(_phy); int ret; + unsigned int val; ret = clk_set_rate(phy->usb_125m_clk, USB_125M_CLK_RATE); if (ret) @@ -87,6 +90,10 @@ static int jh7110_usb2_phy_init(struct phy *_phy) if (ret) return ret; + val = readl(phy->regs + USB_CLK_MODE_OFF); + val |= USB_CLK_MODE_RX_NORMAL_PWR; + writel(val, phy->regs + USB_CLK_MODE_OFF); + return 0; } |