[PATCH 04/11] clk: sunxi-ng: sun60i-a733: Add USB2 bus and sys clocks
From: Alastair D'Silva
Date: Fri Nov 27 2026 - 02:33:21 EST
Implement CLK_BUS_USB2 and CLK_USB2_SYS gate clocks for the A733 USB 3.0
controller.
Signed-off-by: Alastair D'Silva <alastair@xxxxxxxxxxx>
---
drivers/clk/sunxi-ng/ccu-sun60i-a733.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/sunxi-ng/ccu-sun60i-a733.c b/drivers/clk/sunxi-ng/ccu-sun60i-a733.c
index 958a2a2bcf76..ef22e82a4e05 100644
--- a/drivers/clk/sunxi-ng/ccu-sun60i-a733.c
+++ b/drivers/clk/sunxi-ng/ccu-sun60i-a733.c
@@ -1317,6 +1317,8 @@ static SUNXI_CCU_M_DATA_WITH_MUX_GATE(usb2_mf_clk, "usb2-mf", usb2_mf_utmi_paren
BIT(31), /* gate */
0);
+static SUNXI_CCU_GATE_HWS(bus_usb2_clk, "bus-usb2", ahb_hws, 0x135c, BIT(0), 0);
+
static SUNXI_CCU_M_DATA_WITH_MUX_GATE(usb2_u3_utmi_clk, "usb2-u3-utmi", usb2_mf_utmi_parents,
0x1360,
0, 5, /* M */
@@ -1569,6 +1571,8 @@ static SUNXI_CCU_M_HW_WITH_MUX_GATE(isp_clk, "isp", isp_parents, 0x1860,
static SUNXI_CCU_GATE_DATA(res_dcap_24m_clk, "res-dcap-24m", hosc, 0x1a00, BIT(3), 0);
+static SUNXI_CCU_GATE_HWS(usb2_sys_clk, "usb2-sys", mbus_hws, 0x1b30, BIT(0), 0);
+
static const struct clk_parent_data apb2jtag_parents[] = {
{ .hw = &sys_24M_clk.hw },
{ .fw_name = "losc" },
@@ -1855,6 +1859,8 @@ static struct ccu_common *sun60i_a733_ccu_clks[] = {
&usb2_mf_clk.common,
&usb2_u3_utmi_clk.common,
&usb2_u2_pipe_clk.common,
+ &bus_usb2_clk.common,
+ &usb2_sys_clk.common,
&pcie_aux_clk.common,
&pcie_axi_slv_clk.common,
&serdes_phy_clk.common,
@@ -2189,8 +2195,10 @@ static struct clk_hw_onecell_data sun60i_a733_hw_clks = {
[CLK_FANOUT1] = &fanout1_clk.common.hw,
[CLK_FANOUT2] = &fanout2_clk.common.hw,
[CLK_FANOUT3] = &fanout3_clk.common.hw,
+ [CLK_BUS_USB2] = &bus_usb2_clk.common.hw,
+ [CLK_USB2_SYS] = &usb2_sys_clk.common.hw,
},
- .num = CLK_FANOUT3 + 1,
+ .num = CLK_USB2_SYS + 1,
};
static const struct ccu_reset_map sun60i_a733_ccu_resets[] = {
--
2.53.0