1cdb8b80bSIcenowy Zheng /* 2cdb8b80bSIcenowy Zheng * Copyright (c) 2016 Icenowy Zheng <icenowy@aosc.xyz> 3cdb8b80bSIcenowy Zheng * 4cdb8b80bSIcenowy Zheng * This software is licensed under the terms of the GNU General Public 5cdb8b80bSIcenowy Zheng * License version 2, as published by the Free Software Foundation, and 6cdb8b80bSIcenowy Zheng * may be copied, distributed, and modified under those terms. 7cdb8b80bSIcenowy Zheng * 8cdb8b80bSIcenowy Zheng * This program is distributed in the hope that it will be useful, 9cdb8b80bSIcenowy Zheng * but WITHOUT ANY WARRANTY; without even the implied warranty of 10cdb8b80bSIcenowy Zheng * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11cdb8b80bSIcenowy Zheng * GNU General Public License for more details. 12cdb8b80bSIcenowy Zheng */ 13cdb8b80bSIcenowy Zheng 14cdb8b80bSIcenowy Zheng #include <linux/clk-provider.h> 15cdb8b80bSIcenowy Zheng #include <linux/of_address.h> 16cdb8b80bSIcenowy Zheng #include <linux/platform_device.h> 17cdb8b80bSIcenowy Zheng 18cdb8b80bSIcenowy Zheng #include "ccu_common.h" 19cdb8b80bSIcenowy Zheng #include "ccu_reset.h" 20cdb8b80bSIcenowy Zheng 21cdb8b80bSIcenowy Zheng #include "ccu_div.h" 22cdb8b80bSIcenowy Zheng #include "ccu_gate.h" 23cdb8b80bSIcenowy Zheng #include "ccu_mp.h" 24cdb8b80bSIcenowy Zheng #include "ccu_nm.h" 25cdb8b80bSIcenowy Zheng 26cdb8b80bSIcenowy Zheng #include "ccu-sun8i-r.h" 27cdb8b80bSIcenowy Zheng 28*6873d207SChen-Yu Tsai static const struct clk_parent_data ar100_parents[] = { 29*6873d207SChen-Yu Tsai { .fw_name = "losc" }, 30*6873d207SChen-Yu Tsai { .fw_name = "hosc" }, 31*6873d207SChen-Yu Tsai { .fw_name = "pll-periph" }, 32*6873d207SChen-Yu Tsai { .fw_name = "iosc" }, 33*6873d207SChen-Yu Tsai }; 34*6873d207SChen-Yu Tsai 3513e0dde8SChen-Yu Tsai static const struct ccu_mux_var_prediv ar100_predivs[] = { 3613e0dde8SChen-Yu Tsai { .index = 2, .shift = 8, .width = 5 }, 3713e0dde8SChen-Yu Tsai }; 38cdb8b80bSIcenowy Zheng 39cdb8b80bSIcenowy Zheng static struct ccu_div ar100_clk = { 40cdb8b80bSIcenowy Zheng .div = _SUNXI_CCU_DIV_FLAGS(4, 2, CLK_DIVIDER_POWER_OF_TWO), 41cdb8b80bSIcenowy Zheng 42cdb8b80bSIcenowy Zheng .mux = { 43cdb8b80bSIcenowy Zheng .shift = 16, 44cdb8b80bSIcenowy Zheng .width = 2, 45cdb8b80bSIcenowy Zheng 4613e0dde8SChen-Yu Tsai .var_predivs = ar100_predivs, 4713e0dde8SChen-Yu Tsai .n_var_predivs = ARRAY_SIZE(ar100_predivs), 48cdb8b80bSIcenowy Zheng }, 49cdb8b80bSIcenowy Zheng 50cdb8b80bSIcenowy Zheng .common = { 51cdb8b80bSIcenowy Zheng .reg = 0x00, 52cdb8b80bSIcenowy Zheng .features = CCU_FEATURE_VARIABLE_PREDIV, 53*6873d207SChen-Yu Tsai .hw.init = CLK_HW_INIT_PARENTS_DATA("ar100", 54cdb8b80bSIcenowy Zheng ar100_parents, 55cdb8b80bSIcenowy Zheng &ccu_div_ops, 56cdb8b80bSIcenowy Zheng 0), 57cdb8b80bSIcenowy Zheng }, 58cdb8b80bSIcenowy Zheng }; 59cdb8b80bSIcenowy Zheng 60cdb8b80bSIcenowy Zheng static CLK_FIXED_FACTOR(ahb0_clk, "ahb0", "ar100", 1, 1, 0); 61cdb8b80bSIcenowy Zheng 62cdb8b80bSIcenowy Zheng static struct ccu_div apb0_clk = { 63cdb8b80bSIcenowy Zheng .div = _SUNXI_CCU_DIV_FLAGS(0, 2, CLK_DIVIDER_POWER_OF_TWO), 64cdb8b80bSIcenowy Zheng 65cdb8b80bSIcenowy Zheng .common = { 66cdb8b80bSIcenowy Zheng .reg = 0x0c, 67*6873d207SChen-Yu Tsai .hw.init = CLK_HW_INIT_HW("apb0", 68*6873d207SChen-Yu Tsai &ahb0_clk.hw, 69cdb8b80bSIcenowy Zheng &ccu_div_ops, 70cdb8b80bSIcenowy Zheng 0), 71cdb8b80bSIcenowy Zheng }, 72cdb8b80bSIcenowy Zheng }; 73cdb8b80bSIcenowy Zheng 745a90c14cSChen-Yu Tsai static SUNXI_CCU_M(a83t_apb0_clk, "apb0", "ahb0", 0x0c, 0, 2, 0); 755a90c14cSChen-Yu Tsai 76cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_pio_clk, "apb0-pio", "apb0", 77cdb8b80bSIcenowy Zheng 0x28, BIT(0), 0); 78cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_ir_clk, "apb0-ir", "apb0", 79cdb8b80bSIcenowy Zheng 0x28, BIT(1), 0); 80cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_timer_clk, "apb0-timer", "apb0", 81cdb8b80bSIcenowy Zheng 0x28, BIT(2), 0); 82cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_rsb_clk, "apb0-rsb", "apb0", 83cdb8b80bSIcenowy Zheng 0x28, BIT(3), 0); 84cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_uart_clk, "apb0-uart", "apb0", 85cdb8b80bSIcenowy Zheng 0x28, BIT(4), 0); 86cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_i2c_clk, "apb0-i2c", "apb0", 87cdb8b80bSIcenowy Zheng 0x28, BIT(6), 0); 88cdb8b80bSIcenowy Zheng static SUNXI_CCU_GATE(apb0_twd_clk, "apb0-twd", "apb0", 89cdb8b80bSIcenowy Zheng 0x28, BIT(7), 0); 90cdb8b80bSIcenowy Zheng 9137cabc74SIcenowy Zheng static const char * const r_mod0_default_parents[] = { "osc32k", "osc24M" }; 92cdb8b80bSIcenowy Zheng static SUNXI_CCU_MP_WITH_MUX_GATE(ir_clk, "ir", 93cdb8b80bSIcenowy Zheng r_mod0_default_parents, 0x54, 94cdb8b80bSIcenowy Zheng 0, 4, /* M */ 95cdb8b80bSIcenowy Zheng 16, 2, /* P */ 96cdb8b80bSIcenowy Zheng 24, 2, /* mux */ 97cdb8b80bSIcenowy Zheng BIT(31), /* gate */ 98cdb8b80bSIcenowy Zheng 0); 99cdb8b80bSIcenowy Zheng 100*6873d207SChen-Yu Tsai static const struct clk_parent_data a83t_r_mod0_parents[] = { 101*6873d207SChen-Yu Tsai { .fw_name = "iosc" }, 102*6873d207SChen-Yu Tsai { .fw_name = "hosc" }, 103*6873d207SChen-Yu Tsai }; 1045a90c14cSChen-Yu Tsai static const struct ccu_mux_fixed_prediv a83t_ir_predivs[] = { 1055a90c14cSChen-Yu Tsai { .index = 0, .div = 16 }, 1065a90c14cSChen-Yu Tsai }; 1075a90c14cSChen-Yu Tsai static struct ccu_mp a83t_ir_clk = { 1085a90c14cSChen-Yu Tsai .enable = BIT(31), 1095a90c14cSChen-Yu Tsai 1105a90c14cSChen-Yu Tsai .m = _SUNXI_CCU_DIV(0, 4), 1115a90c14cSChen-Yu Tsai .p = _SUNXI_CCU_DIV(16, 2), 1125a90c14cSChen-Yu Tsai 1135a90c14cSChen-Yu Tsai .mux = { 1145a90c14cSChen-Yu Tsai .shift = 24, 1155a90c14cSChen-Yu Tsai .width = 2, 1165a90c14cSChen-Yu Tsai .fixed_predivs = a83t_ir_predivs, 1175a90c14cSChen-Yu Tsai .n_predivs = ARRAY_SIZE(a83t_ir_predivs), 1185a90c14cSChen-Yu Tsai }, 1195a90c14cSChen-Yu Tsai 1205a90c14cSChen-Yu Tsai .common = { 1215a90c14cSChen-Yu Tsai .reg = 0x54, 1225a90c14cSChen-Yu Tsai .features = CCU_FEATURE_VARIABLE_PREDIV, 123*6873d207SChen-Yu Tsai .hw.init = CLK_HW_INIT_PARENTS_DATA("ir", 1245a90c14cSChen-Yu Tsai a83t_r_mod0_parents, 1255a90c14cSChen-Yu Tsai &ccu_mp_ops, 1265a90c14cSChen-Yu Tsai 0), 1275a90c14cSChen-Yu Tsai }, 1285a90c14cSChen-Yu Tsai }; 1295a90c14cSChen-Yu Tsai 1305a90c14cSChen-Yu Tsai static struct ccu_common *sun8i_a83t_r_ccu_clks[] = { 131*6873d207SChen-Yu Tsai &ar100_clk.common, 1325a90c14cSChen-Yu Tsai &a83t_apb0_clk.common, 1335a90c14cSChen-Yu Tsai &apb0_pio_clk.common, 1345a90c14cSChen-Yu Tsai &apb0_ir_clk.common, 1355a90c14cSChen-Yu Tsai &apb0_timer_clk.common, 1365a90c14cSChen-Yu Tsai &apb0_rsb_clk.common, 1375a90c14cSChen-Yu Tsai &apb0_uart_clk.common, 1385a90c14cSChen-Yu Tsai &apb0_i2c_clk.common, 1395a90c14cSChen-Yu Tsai &apb0_twd_clk.common, 1405a90c14cSChen-Yu Tsai &a83t_ir_clk.common, 1415a90c14cSChen-Yu Tsai }; 1425a90c14cSChen-Yu Tsai 143cdb8b80bSIcenowy Zheng static struct ccu_common *sun8i_h3_r_ccu_clks[] = { 144cdb8b80bSIcenowy Zheng &ar100_clk.common, 145cdb8b80bSIcenowy Zheng &apb0_clk.common, 146cdb8b80bSIcenowy Zheng &apb0_pio_clk.common, 147cdb8b80bSIcenowy Zheng &apb0_ir_clk.common, 148cdb8b80bSIcenowy Zheng &apb0_timer_clk.common, 149cdb8b80bSIcenowy Zheng &apb0_uart_clk.common, 150cdb8b80bSIcenowy Zheng &apb0_i2c_clk.common, 151cdb8b80bSIcenowy Zheng &apb0_twd_clk.common, 152cdb8b80bSIcenowy Zheng &ir_clk.common, 153cdb8b80bSIcenowy Zheng }; 154cdb8b80bSIcenowy Zheng 155cdb8b80bSIcenowy Zheng static struct ccu_common *sun50i_a64_r_ccu_clks[] = { 156cdb8b80bSIcenowy Zheng &ar100_clk.common, 157cdb8b80bSIcenowy Zheng &apb0_clk.common, 158cdb8b80bSIcenowy Zheng &apb0_pio_clk.common, 159cdb8b80bSIcenowy Zheng &apb0_ir_clk.common, 160cdb8b80bSIcenowy Zheng &apb0_timer_clk.common, 161cdb8b80bSIcenowy Zheng &apb0_rsb_clk.common, 162cdb8b80bSIcenowy Zheng &apb0_uart_clk.common, 163cdb8b80bSIcenowy Zheng &apb0_i2c_clk.common, 164cdb8b80bSIcenowy Zheng &apb0_twd_clk.common, 165cdb8b80bSIcenowy Zheng &ir_clk.common, 166cdb8b80bSIcenowy Zheng }; 167cdb8b80bSIcenowy Zheng 1685a90c14cSChen-Yu Tsai static struct clk_hw_onecell_data sun8i_a83t_r_hw_clks = { 1695a90c14cSChen-Yu Tsai .hws = { 170*6873d207SChen-Yu Tsai [CLK_AR100] = &ar100_clk.common.hw, 1715a90c14cSChen-Yu Tsai [CLK_AHB0] = &ahb0_clk.hw, 1725a90c14cSChen-Yu Tsai [CLK_APB0] = &a83t_apb0_clk.common.hw, 1735a90c14cSChen-Yu Tsai [CLK_APB0_PIO] = &apb0_pio_clk.common.hw, 1745a90c14cSChen-Yu Tsai [CLK_APB0_IR] = &apb0_ir_clk.common.hw, 1755a90c14cSChen-Yu Tsai [CLK_APB0_TIMER] = &apb0_timer_clk.common.hw, 1765a90c14cSChen-Yu Tsai [CLK_APB0_RSB] = &apb0_rsb_clk.common.hw, 1775a90c14cSChen-Yu Tsai [CLK_APB0_UART] = &apb0_uart_clk.common.hw, 1785a90c14cSChen-Yu Tsai [CLK_APB0_I2C] = &apb0_i2c_clk.common.hw, 1795a90c14cSChen-Yu Tsai [CLK_APB0_TWD] = &apb0_twd_clk.common.hw, 1805a90c14cSChen-Yu Tsai [CLK_IR] = &a83t_ir_clk.common.hw, 1815a90c14cSChen-Yu Tsai }, 1825a90c14cSChen-Yu Tsai .num = CLK_NUMBER, 1835a90c14cSChen-Yu Tsai }; 1845a90c14cSChen-Yu Tsai 185cdb8b80bSIcenowy Zheng static struct clk_hw_onecell_data sun8i_h3_r_hw_clks = { 186cdb8b80bSIcenowy Zheng .hws = { 187cdb8b80bSIcenowy Zheng [CLK_AR100] = &ar100_clk.common.hw, 188cdb8b80bSIcenowy Zheng [CLK_AHB0] = &ahb0_clk.hw, 189cdb8b80bSIcenowy Zheng [CLK_APB0] = &apb0_clk.common.hw, 190cdb8b80bSIcenowy Zheng [CLK_APB0_PIO] = &apb0_pio_clk.common.hw, 191cdb8b80bSIcenowy Zheng [CLK_APB0_IR] = &apb0_ir_clk.common.hw, 192cdb8b80bSIcenowy Zheng [CLK_APB0_TIMER] = &apb0_timer_clk.common.hw, 193cdb8b80bSIcenowy Zheng [CLK_APB0_UART] = &apb0_uart_clk.common.hw, 194cdb8b80bSIcenowy Zheng [CLK_APB0_I2C] = &apb0_i2c_clk.common.hw, 195cdb8b80bSIcenowy Zheng [CLK_APB0_TWD] = &apb0_twd_clk.common.hw, 196cdb8b80bSIcenowy Zheng [CLK_IR] = &ir_clk.common.hw, 197cdb8b80bSIcenowy Zheng }, 198cdb8b80bSIcenowy Zheng .num = CLK_NUMBER, 199cdb8b80bSIcenowy Zheng }; 200cdb8b80bSIcenowy Zheng 201cdb8b80bSIcenowy Zheng static struct clk_hw_onecell_data sun50i_a64_r_hw_clks = { 202cdb8b80bSIcenowy Zheng .hws = { 203cdb8b80bSIcenowy Zheng [CLK_AR100] = &ar100_clk.common.hw, 204cdb8b80bSIcenowy Zheng [CLK_AHB0] = &ahb0_clk.hw, 205cdb8b80bSIcenowy Zheng [CLK_APB0] = &apb0_clk.common.hw, 206cdb8b80bSIcenowy Zheng [CLK_APB0_PIO] = &apb0_pio_clk.common.hw, 207cdb8b80bSIcenowy Zheng [CLK_APB0_IR] = &apb0_ir_clk.common.hw, 208cdb8b80bSIcenowy Zheng [CLK_APB0_TIMER] = &apb0_timer_clk.common.hw, 209cdb8b80bSIcenowy Zheng [CLK_APB0_RSB] = &apb0_rsb_clk.common.hw, 210cdb8b80bSIcenowy Zheng [CLK_APB0_UART] = &apb0_uart_clk.common.hw, 211cdb8b80bSIcenowy Zheng [CLK_APB0_I2C] = &apb0_i2c_clk.common.hw, 212cdb8b80bSIcenowy Zheng [CLK_APB0_TWD] = &apb0_twd_clk.common.hw, 213cdb8b80bSIcenowy Zheng [CLK_IR] = &ir_clk.common.hw, 214cdb8b80bSIcenowy Zheng }, 215cdb8b80bSIcenowy Zheng .num = CLK_NUMBER, 216cdb8b80bSIcenowy Zheng }; 217cdb8b80bSIcenowy Zheng 2185a90c14cSChen-Yu Tsai static struct ccu_reset_map sun8i_a83t_r_ccu_resets[] = { 2195a90c14cSChen-Yu Tsai [RST_APB0_IR] = { 0xb0, BIT(1) }, 2205a90c14cSChen-Yu Tsai [RST_APB0_TIMER] = { 0xb0, BIT(2) }, 2215a90c14cSChen-Yu Tsai [RST_APB0_RSB] = { 0xb0, BIT(3) }, 2225a90c14cSChen-Yu Tsai [RST_APB0_UART] = { 0xb0, BIT(4) }, 2235a90c14cSChen-Yu Tsai [RST_APB0_I2C] = { 0xb0, BIT(6) }, 2245a90c14cSChen-Yu Tsai }; 2255a90c14cSChen-Yu Tsai 226cdb8b80bSIcenowy Zheng static struct ccu_reset_map sun8i_h3_r_ccu_resets[] = { 227cdb8b80bSIcenowy Zheng [RST_APB0_IR] = { 0xb0, BIT(1) }, 228cdb8b80bSIcenowy Zheng [RST_APB0_TIMER] = { 0xb0, BIT(2) }, 229cdb8b80bSIcenowy Zheng [RST_APB0_UART] = { 0xb0, BIT(4) }, 230cdb8b80bSIcenowy Zheng [RST_APB0_I2C] = { 0xb0, BIT(6) }, 231cdb8b80bSIcenowy Zheng }; 232cdb8b80bSIcenowy Zheng 233cdb8b80bSIcenowy Zheng static struct ccu_reset_map sun50i_a64_r_ccu_resets[] = { 234cdb8b80bSIcenowy Zheng [RST_APB0_IR] = { 0xb0, BIT(1) }, 235cdb8b80bSIcenowy Zheng [RST_APB0_TIMER] = { 0xb0, BIT(2) }, 236cdb8b80bSIcenowy Zheng [RST_APB0_RSB] = { 0xb0, BIT(3) }, 237cdb8b80bSIcenowy Zheng [RST_APB0_UART] = { 0xb0, BIT(4) }, 238cdb8b80bSIcenowy Zheng [RST_APB0_I2C] = { 0xb0, BIT(6) }, 239cdb8b80bSIcenowy Zheng }; 240cdb8b80bSIcenowy Zheng 2415a90c14cSChen-Yu Tsai static const struct sunxi_ccu_desc sun8i_a83t_r_ccu_desc = { 2425a90c14cSChen-Yu Tsai .ccu_clks = sun8i_a83t_r_ccu_clks, 2435a90c14cSChen-Yu Tsai .num_ccu_clks = ARRAY_SIZE(sun8i_a83t_r_ccu_clks), 2445a90c14cSChen-Yu Tsai 2455a90c14cSChen-Yu Tsai .hw_clks = &sun8i_a83t_r_hw_clks, 2465a90c14cSChen-Yu Tsai 2475a90c14cSChen-Yu Tsai .resets = sun8i_a83t_r_ccu_resets, 2485a90c14cSChen-Yu Tsai .num_resets = ARRAY_SIZE(sun8i_a83t_r_ccu_resets), 2495a90c14cSChen-Yu Tsai }; 2505a90c14cSChen-Yu Tsai 251cdb8b80bSIcenowy Zheng static const struct sunxi_ccu_desc sun8i_h3_r_ccu_desc = { 252cdb8b80bSIcenowy Zheng .ccu_clks = sun8i_h3_r_ccu_clks, 253cdb8b80bSIcenowy Zheng .num_ccu_clks = ARRAY_SIZE(sun8i_h3_r_ccu_clks), 254cdb8b80bSIcenowy Zheng 255cdb8b80bSIcenowy Zheng .hw_clks = &sun8i_h3_r_hw_clks, 256cdb8b80bSIcenowy Zheng 257cdb8b80bSIcenowy Zheng .resets = sun8i_h3_r_ccu_resets, 258cdb8b80bSIcenowy Zheng .num_resets = ARRAY_SIZE(sun8i_h3_r_ccu_resets), 259cdb8b80bSIcenowy Zheng }; 260cdb8b80bSIcenowy Zheng 261cdb8b80bSIcenowy Zheng static const struct sunxi_ccu_desc sun50i_a64_r_ccu_desc = { 262cdb8b80bSIcenowy Zheng .ccu_clks = sun50i_a64_r_ccu_clks, 263cdb8b80bSIcenowy Zheng .num_ccu_clks = ARRAY_SIZE(sun50i_a64_r_ccu_clks), 264cdb8b80bSIcenowy Zheng 265cdb8b80bSIcenowy Zheng .hw_clks = &sun50i_a64_r_hw_clks, 266cdb8b80bSIcenowy Zheng 267cdb8b80bSIcenowy Zheng .resets = sun50i_a64_r_ccu_resets, 268cdb8b80bSIcenowy Zheng .num_resets = ARRAY_SIZE(sun50i_a64_r_ccu_resets), 269cdb8b80bSIcenowy Zheng }; 270cdb8b80bSIcenowy Zheng 271cdb8b80bSIcenowy Zheng static void __init sunxi_r_ccu_init(struct device_node *node, 272cdb8b80bSIcenowy Zheng const struct sunxi_ccu_desc *desc) 273cdb8b80bSIcenowy Zheng { 274cdb8b80bSIcenowy Zheng void __iomem *reg; 275cdb8b80bSIcenowy Zheng 276cdb8b80bSIcenowy Zheng reg = of_io_request_and_map(node, 0, of_node_full_name(node)); 277cdb8b80bSIcenowy Zheng if (IS_ERR(reg)) { 27816673931SRob Herring pr_err("%pOF: Could not map the clock registers\n", node); 279cdb8b80bSIcenowy Zheng return; 280cdb8b80bSIcenowy Zheng } 281cdb8b80bSIcenowy Zheng 282cdb8b80bSIcenowy Zheng sunxi_ccu_probe(node, reg, desc); 283cdb8b80bSIcenowy Zheng } 284cdb8b80bSIcenowy Zheng 2855a90c14cSChen-Yu Tsai static void __init sun8i_a83t_r_ccu_setup(struct device_node *node) 2865a90c14cSChen-Yu Tsai { 2875a90c14cSChen-Yu Tsai sunxi_r_ccu_init(node, &sun8i_a83t_r_ccu_desc); 2885a90c14cSChen-Yu Tsai } 2895a90c14cSChen-Yu Tsai CLK_OF_DECLARE(sun8i_a83t_r_ccu, "allwinner,sun8i-a83t-r-ccu", 2905a90c14cSChen-Yu Tsai sun8i_a83t_r_ccu_setup); 2915a90c14cSChen-Yu Tsai 292cdb8b80bSIcenowy Zheng static void __init sun8i_h3_r_ccu_setup(struct device_node *node) 293cdb8b80bSIcenowy Zheng { 294cdb8b80bSIcenowy Zheng sunxi_r_ccu_init(node, &sun8i_h3_r_ccu_desc); 295cdb8b80bSIcenowy Zheng } 296cdb8b80bSIcenowy Zheng CLK_OF_DECLARE(sun8i_h3_r_ccu, "allwinner,sun8i-h3-r-ccu", 297cdb8b80bSIcenowy Zheng sun8i_h3_r_ccu_setup); 298cdb8b80bSIcenowy Zheng 299cdb8b80bSIcenowy Zheng static void __init sun50i_a64_r_ccu_setup(struct device_node *node) 300cdb8b80bSIcenowy Zheng { 301cdb8b80bSIcenowy Zheng sunxi_r_ccu_init(node, &sun50i_a64_r_ccu_desc); 302cdb8b80bSIcenowy Zheng } 303cdb8b80bSIcenowy Zheng CLK_OF_DECLARE(sun50i_a64_r_ccu, "allwinner,sun50i-a64-r-ccu", 304cdb8b80bSIcenowy Zheng sun50i_a64_r_ccu_setup); 305