blob: 6e085c41368719d75abe5c5b279e4466e8ce3a63 [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001// SPDX-License-Identifier: GPL-2.0
huang lin3f2ef132015-11-17 14:20:16 +08002/*
3 * (C) Copyright 2015 Google, Inc
huang lin3f2ef132015-11-17 14:20:16 +08004 */
5
6#include <common.h>
Stephen Warren135aa952016-06-17 09:44:00 -06007#include <clk-uclass.h>
huang lin3f2ef132015-11-17 14:20:16 +08008#include <dm.h>
9#include <errno.h>
Simon Glass336d4612020-02-03 07:36:16 -070010#include <malloc.h>
huang lin3f2ef132015-11-17 14:20:16 +080011#include <syscon.h>
12#include <asm/io.h>
Kever Yang15f09a12019-03-28 11:01:23 +080013#include <asm/arch-rockchip/clock.h>
14#include <asm/arch-rockchip/cru_rk3036.h>
15#include <asm/arch-rockchip/hardware.h>
huang lin3f2ef132015-11-17 14:20:16 +080016#include <dm/lists.h>
Simon Glass898d6432016-01-21 19:43:38 -070017#include <dt-bindings/clock/rk3036-cru.h>
Heiko Stübnerabd01282016-07-22 23:51:06 +020018#include <linux/log2.h>
huang lin3f2ef132015-11-17 14:20:16 +080019
huang lin3f2ef132015-11-17 14:20:16 +080020enum {
21 VCO_MAX_HZ = 2400U * 1000000,
22 VCO_MIN_HZ = 600 * 1000000,
23 OUTPUT_MAX_HZ = 2400U * 1000000,
24 OUTPUT_MIN_HZ = 24 * 1000000,
25};
26
27#define RATE_TO_DIV(input_rate, output_rate) \
28 ((input_rate) / (output_rate) - 1);
29
30#define DIV_TO_RATE(input_rate, div) ((input_rate) / ((div) + 1))
31
32#define PLL_DIVISORS(hz, _refdiv, _postdiv1, _postdiv2) {\
33 .refdiv = _refdiv,\
34 .fbdiv = (u32)((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ),\
35 .postdiv1 = _postdiv1, .postdiv2 = _postdiv2};\
36 _Static_assert(((u64)hz * _refdiv * _postdiv1 * _postdiv2 / OSC_HZ) *\
37 OSC_HZ / (_refdiv * _postdiv1 * _postdiv2) == hz,\
38 #hz "Hz cannot be hit with PLL "\
39 "divisors on line " __stringify(__LINE__));
40
Kever Yang6a464d92017-06-13 10:03:11 +080041/* use integer mode*/
huang lin3f2ef132015-11-17 14:20:16 +080042static const struct pll_div apll_init_cfg = PLL_DIVISORS(APLL_HZ, 1, 3, 1);
43static const struct pll_div gpll_init_cfg = PLL_DIVISORS(GPLL_HZ, 2, 2, 1);
44
huang lin3f2ef132015-11-17 14:20:16 +080045static int rkclk_set_pll(struct rk3036_cru *cru, enum rk_clk_id clk_id,
46 const struct pll_div *div)
47{
48 int pll_id = rk_pll_id(clk_id);
49 struct rk3036_pll *pll = &cru->pll[pll_id];
50
51 /* All PLLs have same VCO and output frequency range restrictions. */
52 uint vco_hz = OSC_HZ / 1000 * div->fbdiv / div->refdiv * 1000;
53 uint output_hz = vco_hz / div->postdiv1 / div->postdiv2;
54
55 debug("PLL at %p: fbdiv=%d, refdiv=%d, postdiv1=%d, postdiv2=%d,\
56 vco=%u Hz, output=%u Hz\n",
57 pll, div->fbdiv, div->refdiv, div->postdiv1,
58 div->postdiv2, vco_hz, output_hz);
59 assert(vco_hz >= VCO_MIN_HZ && vco_hz <= VCO_MAX_HZ &&
60 output_hz >= OUTPUT_MIN_HZ && output_hz <= OUTPUT_MAX_HZ);
61
Kever Yang6a464d92017-06-13 10:03:11 +080062 /* use integer mode */
63 rk_setreg(&pll->con1, 1 << PLL_DSMPD_SHIFT);
huang lin3f2ef132015-11-17 14:20:16 +080064
65 rk_clrsetreg(&pll->con0,
Kever Yang37943aa2017-05-15 20:52:15 +080066 PLL_POSTDIV1_MASK | PLL_FBDIV_MASK,
huang lin3f2ef132015-11-17 14:20:16 +080067 (div->postdiv1 << PLL_POSTDIV1_SHIFT) | div->fbdiv);
Kever Yang37943aa2017-05-15 20:52:15 +080068 rk_clrsetreg(&pll->con1, PLL_POSTDIV2_MASK | PLL_REFDIV_MASK,
69 (div->postdiv2 << PLL_POSTDIV2_SHIFT |
70 div->refdiv << PLL_REFDIV_SHIFT));
huang lin3f2ef132015-11-17 14:20:16 +080071
72 /* waiting for pll lock */
73 while (readl(&pll->con1) & (1 << PLL_LOCK_STATUS_SHIFT))
74 udelay(1);
75
76 return 0;
77}
78
79static void rkclk_init(struct rk3036_cru *cru)
80{
81 u32 aclk_div;
82 u32 hclk_div;
83 u32 pclk_div;
84
85 /* pll enter slow-mode */
86 rk_clrsetreg(&cru->cru_mode_con,
Kever Yang37943aa2017-05-15 20:52:15 +080087 GPLL_MODE_MASK | APLL_MODE_MASK,
huang lin3f2ef132015-11-17 14:20:16 +080088 GPLL_MODE_SLOW << GPLL_MODE_SHIFT |
89 APLL_MODE_SLOW << APLL_MODE_SHIFT);
90
91 /* init pll */
92 rkclk_set_pll(cru, CLK_ARM, &apll_init_cfg);
93 rkclk_set_pll(cru, CLK_GENERAL, &gpll_init_cfg);
94
95 /*
Kever Yang37943aa2017-05-15 20:52:15 +080096 * select apll as cpu/core clock pll source and
97 * set up dependent divisors for PERI and ACLK clocks.
huang lin3f2ef132015-11-17 14:20:16 +080098 * core hz : apll = 1:1
99 */
100 aclk_div = APLL_HZ / CORE_ACLK_HZ - 1;
101 assert((aclk_div + 1) * CORE_ACLK_HZ == APLL_HZ && aclk_div < 0x7);
102
103 pclk_div = APLL_HZ / CORE_PERI_HZ - 1;
104 assert((pclk_div + 1) * CORE_PERI_HZ == APLL_HZ && pclk_div < 0xf);
105
106 rk_clrsetreg(&cru->cru_clksel_con[0],
Kever Yang37943aa2017-05-15 20:52:15 +0800107 CORE_CLK_PLL_SEL_MASK | CORE_DIV_CON_MASK,
huang lin3f2ef132015-11-17 14:20:16 +0800108 CORE_CLK_PLL_SEL_APLL << CORE_CLK_PLL_SEL_SHIFT |
109 0 << CORE_DIV_CON_SHIFT);
110
111 rk_clrsetreg(&cru->cru_clksel_con[1],
Kever Yang37943aa2017-05-15 20:52:15 +0800112 CORE_ACLK_DIV_MASK | CORE_PERI_DIV_MASK,
huang lin3f2ef132015-11-17 14:20:16 +0800113 aclk_div << CORE_ACLK_DIV_SHIFT |
114 pclk_div << CORE_PERI_DIV_SHIFT);
115
116 /*
Kever Yang1960b012017-05-15 20:52:16 +0800117 * select apll as pd_bus bus clock source and
huang lin3f2ef132015-11-17 14:20:16 +0800118 * set up dependent divisors for PCLK/HCLK and ACLK clocks.
119 */
Kever Yang1960b012017-05-15 20:52:16 +0800120 aclk_div = GPLL_HZ / BUS_ACLK_HZ - 1;
121 assert((aclk_div + 1) * BUS_ACLK_HZ == GPLL_HZ && aclk_div <= 0x1f);
huang lin3f2ef132015-11-17 14:20:16 +0800122
Kever Yang1960b012017-05-15 20:52:16 +0800123 pclk_div = GPLL_HZ / BUS_PCLK_HZ - 1;
124 assert((pclk_div + 1) * BUS_PCLK_HZ == GPLL_HZ && pclk_div <= 0x7);
huang lin3f2ef132015-11-17 14:20:16 +0800125
Kever Yang1960b012017-05-15 20:52:16 +0800126 hclk_div = GPLL_HZ / BUS_HCLK_HZ - 1;
127 assert((hclk_div + 1) * BUS_HCLK_HZ == GPLL_HZ && hclk_div <= 0x3);
huang lin3f2ef132015-11-17 14:20:16 +0800128
129 rk_clrsetreg(&cru->cru_clksel_con[0],
Kever Yang37943aa2017-05-15 20:52:15 +0800130 BUS_ACLK_PLL_SEL_MASK | BUS_ACLK_DIV_MASK,
Kever Yang1960b012017-05-15 20:52:16 +0800131 BUS_ACLK_PLL_SEL_GPLL << BUS_ACLK_PLL_SEL_SHIFT |
Kever Yang37943aa2017-05-15 20:52:15 +0800132 aclk_div << BUS_ACLK_DIV_SHIFT);
huang lin3f2ef132015-11-17 14:20:16 +0800133
134 rk_clrsetreg(&cru->cru_clksel_con[1],
Kever Yang37943aa2017-05-15 20:52:15 +0800135 BUS_PCLK_DIV_MASK | BUS_HCLK_DIV_MASK,
136 pclk_div << BUS_PCLK_DIV_SHIFT |
137 hclk_div << BUS_HCLK_DIV_SHIFT);
huang lin3f2ef132015-11-17 14:20:16 +0800138
139 /*
Kever Yang37943aa2017-05-15 20:52:15 +0800140 * select gpll as pd_peri bus clock source and
huang lin3f2ef132015-11-17 14:20:16 +0800141 * set up dependent divisors for PCLK/HCLK and ACLK clocks.
142 */
143 aclk_div = GPLL_HZ / PERI_ACLK_HZ - 1;
144 assert((aclk_div + 1) * PERI_ACLK_HZ == GPLL_HZ && aclk_div < 0x1f);
145
Heiko Stübnerabd01282016-07-22 23:51:06 +0200146 hclk_div = ilog2(PERI_ACLK_HZ / PERI_HCLK_HZ);
huang lin3f2ef132015-11-17 14:20:16 +0800147 assert((1 << hclk_div) * PERI_HCLK_HZ ==
Kever Yang1960b012017-05-15 20:52:16 +0800148 PERI_ACLK_HZ && (hclk_div < 0x4));
huang lin3f2ef132015-11-17 14:20:16 +0800149
Heiko Stübnerabd01282016-07-22 23:51:06 +0200150 pclk_div = ilog2(PERI_ACLK_HZ / PERI_PCLK_HZ);
huang lin3f2ef132015-11-17 14:20:16 +0800151 assert((1 << pclk_div) * PERI_PCLK_HZ ==
152 PERI_ACLK_HZ && pclk_div < 0x8);
153
154 rk_clrsetreg(&cru->cru_clksel_con[10],
Kever Yang37943aa2017-05-15 20:52:15 +0800155 PERI_PLL_SEL_MASK | PERI_PCLK_DIV_MASK |
156 PERI_HCLK_DIV_MASK | PERI_ACLK_DIV_MASK,
huang lin3f2ef132015-11-17 14:20:16 +0800157 PERI_PLL_GPLL << PERI_PLL_SEL_SHIFT |
158 pclk_div << PERI_PCLK_DIV_SHIFT |
159 hclk_div << PERI_HCLK_DIV_SHIFT |
160 aclk_div << PERI_ACLK_DIV_SHIFT);
161
162 /* PLL enter normal-mode */
163 rk_clrsetreg(&cru->cru_mode_con,
Kever Yang37943aa2017-05-15 20:52:15 +0800164 GPLL_MODE_MASK | APLL_MODE_MASK,
huang lin3f2ef132015-11-17 14:20:16 +0800165 GPLL_MODE_NORM << GPLL_MODE_SHIFT |
166 APLL_MODE_NORM << APLL_MODE_SHIFT);
167}
168
169/* Get pll rate by id */
170static uint32_t rkclk_pll_get_rate(struct rk3036_cru *cru,
171 enum rk_clk_id clk_id)
172{
173 uint32_t refdiv, fbdiv, postdiv1, postdiv2;
174 uint32_t con;
175 int pll_id = rk_pll_id(clk_id);
176 struct rk3036_pll *pll = &cru->pll[pll_id];
177 static u8 clk_shift[CLK_COUNT] = {
178 0xff, APLL_MODE_SHIFT, DPLL_MODE_SHIFT, 0xff,
179 GPLL_MODE_SHIFT, 0xff
180 };
Kever Yang37943aa2017-05-15 20:52:15 +0800181 static u32 clk_mask[CLK_COUNT] = {
182 0xffffffff, APLL_MODE_MASK, DPLL_MODE_MASK, 0xffffffff,
183 GPLL_MODE_MASK, 0xffffffff
huang lin3f2ef132015-11-17 14:20:16 +0800184 };
185 uint shift;
186 uint mask;
187
188 con = readl(&cru->cru_mode_con);
189 shift = clk_shift[clk_id];
190 mask = clk_mask[clk_id];
191
Kever Yang37943aa2017-05-15 20:52:15 +0800192 switch ((con & mask) >> shift) {
huang lin3f2ef132015-11-17 14:20:16 +0800193 case GPLL_MODE_SLOW:
194 return OSC_HZ;
195 case GPLL_MODE_NORM:
196
197 /* normal mode */
198 con = readl(&pll->con0);
Kever Yang37943aa2017-05-15 20:52:15 +0800199 postdiv1 = (con & PLL_POSTDIV1_MASK) >> PLL_POSTDIV1_SHIFT;
200 fbdiv = (con & PLL_FBDIV_MASK) >> PLL_FBDIV_SHIFT;
huang lin3f2ef132015-11-17 14:20:16 +0800201 con = readl(&pll->con1);
Kever Yang37943aa2017-05-15 20:52:15 +0800202 postdiv2 = (con & PLL_POSTDIV2_MASK) >> PLL_POSTDIV2_SHIFT;
203 refdiv = (con & PLL_REFDIV_MASK) >> PLL_REFDIV_SHIFT;
huang lin3f2ef132015-11-17 14:20:16 +0800204 return (24 * fbdiv / (refdiv * postdiv1 * postdiv2)) * 1000000;
205 case GPLL_MODE_DEEP:
206 default:
207 return 32768;
208 }
209}
210
211static ulong rockchip_mmc_get_clk(struct rk3036_cru *cru, uint clk_general_rate,
Simon Glass898d6432016-01-21 19:43:38 -0700212 int periph)
huang lin3f2ef132015-11-17 14:20:16 +0800213{
214 uint src_rate;
215 uint div, mux;
216 u32 con;
217
218 switch (periph) {
Simon Glass898d6432016-01-21 19:43:38 -0700219 case HCLK_EMMC:
Xu Ziyuan7f0cfe42017-04-16 17:44:43 +0800220 case SCLK_EMMC:
huang lin3f2ef132015-11-17 14:20:16 +0800221 con = readl(&cru->cru_clksel_con[12]);
Kever Yang37943aa2017-05-15 20:52:15 +0800222 mux = (con & EMMC_PLL_MASK) >> EMMC_PLL_SHIFT;
223 div = (con & EMMC_DIV_MASK) >> EMMC_DIV_SHIFT;
huang lin3f2ef132015-11-17 14:20:16 +0800224 break;
Simon Glass898d6432016-01-21 19:43:38 -0700225 case HCLK_SDIO:
Xu Ziyuan7f0cfe42017-04-16 17:44:43 +0800226 case SCLK_SDIO:
huang lin3f2ef132015-11-17 14:20:16 +0800227 con = readl(&cru->cru_clksel_con[12]);
Kever Yang37943aa2017-05-15 20:52:15 +0800228 mux = (con & MMC0_PLL_MASK) >> MMC0_PLL_SHIFT;
229 div = (con & MMC0_DIV_MASK) >> MMC0_DIV_SHIFT;
huang lin3f2ef132015-11-17 14:20:16 +0800230 break;
231 default:
232 return -EINVAL;
233 }
234
235 src_rate = mux == EMMC_SEL_24M ? OSC_HZ : clk_general_rate;
Kever Yang3a94d752017-07-27 12:54:01 +0800236 return DIV_TO_RATE(src_rate, div) / 2;
huang lin3f2ef132015-11-17 14:20:16 +0800237}
238
239static ulong rockchip_mmc_set_clk(struct rk3036_cru *cru, uint clk_general_rate,
Simon Glass898d6432016-01-21 19:43:38 -0700240 int periph, uint freq)
huang lin3f2ef132015-11-17 14:20:16 +0800241{
242 int src_clk_div;
243 int mux;
244
245 debug("%s: clk_general_rate=%u\n", __func__, clk_general_rate);
246
247 /* mmc clock auto divide 2 in internal */
Kever Yang3a94d752017-07-27 12:54:01 +0800248 src_clk_div = DIV_ROUND_UP(clk_general_rate / 2, freq);
huang lin3f2ef132015-11-17 14:20:16 +0800249
Kever Yang217273c2017-07-27 12:54:02 +0800250 if (src_clk_div > 128) {
Kever Yang3a94d752017-07-27 12:54:01 +0800251 src_clk_div = DIV_ROUND_UP(OSC_HZ / 2, freq);
Kever Yang217273c2017-07-27 12:54:02 +0800252 assert(src_clk_div - 1 < 128);
huang lin3f2ef132015-11-17 14:20:16 +0800253 mux = EMMC_SEL_24M;
254 } else {
255 mux = EMMC_SEL_GPLL;
256 }
257
258 switch (periph) {
Simon Glass898d6432016-01-21 19:43:38 -0700259 case HCLK_EMMC:
Xu Ziyuan7f0cfe42017-04-16 17:44:43 +0800260 case SCLK_EMMC:
huang lin3f2ef132015-11-17 14:20:16 +0800261 rk_clrsetreg(&cru->cru_clksel_con[12],
Kever Yang37943aa2017-05-15 20:52:15 +0800262 EMMC_PLL_MASK | EMMC_DIV_MASK,
huang lin3f2ef132015-11-17 14:20:16 +0800263 mux << EMMC_PLL_SHIFT |
264 (src_clk_div - 1) << EMMC_DIV_SHIFT);
265 break;
Simon Glass898d6432016-01-21 19:43:38 -0700266 case HCLK_SDIO:
Xu Ziyuan7f0cfe42017-04-16 17:44:43 +0800267 case SCLK_SDIO:
huang lin3f2ef132015-11-17 14:20:16 +0800268 rk_clrsetreg(&cru->cru_clksel_con[11],
Kever Yang37943aa2017-05-15 20:52:15 +0800269 MMC0_PLL_MASK | MMC0_DIV_MASK,
huang lin3f2ef132015-11-17 14:20:16 +0800270 mux << MMC0_PLL_SHIFT |
271 (src_clk_div - 1) << MMC0_DIV_SHIFT);
272 break;
273 default:
274 return -EINVAL;
275 }
276
277 return rockchip_mmc_get_clk(cru, clk_general_rate, periph);
278}
279
Stephen Warren135aa952016-06-17 09:44:00 -0600280static ulong rk3036_clk_get_rate(struct clk *clk)
huang lin3f2ef132015-11-17 14:20:16 +0800281{
Stephen Warren135aa952016-06-17 09:44:00 -0600282 struct rk3036_clk_priv *priv = dev_get_priv(clk->dev);
huang lin3f2ef132015-11-17 14:20:16 +0800283
Stephen Warren135aa952016-06-17 09:44:00 -0600284 switch (clk->id) {
285 case 0 ... 63:
286 return rkclk_pll_get_rate(priv->cru, clk->id);
287 default:
288 return -ENOENT;
289 }
huang lin3f2ef132015-11-17 14:20:16 +0800290}
291
Stephen Warren135aa952016-06-17 09:44:00 -0600292static ulong rk3036_clk_set_rate(struct clk *clk, ulong rate)
huang lin3f2ef132015-11-17 14:20:16 +0800293{
Stephen Warren135aa952016-06-17 09:44:00 -0600294 struct rk3036_clk_priv *priv = dev_get_priv(clk->dev);
295 ulong new_rate, gclk_rate;
huang lin3f2ef132015-11-17 14:20:16 +0800296
Stephen Warren135aa952016-06-17 09:44:00 -0600297 gclk_rate = rkclk_pll_get_rate(priv->cru, CLK_GENERAL);
298 switch (clk->id) {
299 case 0 ... 63:
300 return 0;
Simon Glass898d6432016-01-21 19:43:38 -0700301 case HCLK_EMMC:
Xu Ziyuan7f0cfe42017-04-16 17:44:43 +0800302 case SCLK_EMMC:
Stephen Warren135aa952016-06-17 09:44:00 -0600303 new_rate = rockchip_mmc_set_clk(priv->cru, gclk_rate,
304 clk->id, rate);
huang lin3f2ef132015-11-17 14:20:16 +0800305 break;
306 default:
307 return -ENOENT;
308 }
309
310 return new_rate;
311}
312
313static struct clk_ops rk3036_clk_ops = {
314 .get_rate = rk3036_clk_get_rate,
315 .set_rate = rk3036_clk_set_rate,
huang lin3f2ef132015-11-17 14:20:16 +0800316};
317
Kever Yangaccaaea2018-04-24 11:27:06 +0800318static int rk3036_clk_ofdata_to_platdata(struct udevice *dev)
huang lin3f2ef132015-11-17 14:20:16 +0800319{
huang lin3f2ef132015-11-17 14:20:16 +0800320 struct rk3036_clk_priv *priv = dev_get_priv(dev);
321
Kever Yang7ae028b2018-02-11 11:53:05 +0800322 priv->cru = dev_read_addr_ptr(dev);
Kever Yangaccaaea2018-04-24 11:27:06 +0800323
324 return 0;
325}
326
327static int rk3036_clk_probe(struct udevice *dev)
328{
329 struct rk3036_clk_priv *priv = dev_get_priv(dev);
330
huang lin3f2ef132015-11-17 14:20:16 +0800331 rkclk_init(priv->cru);
332
333 return 0;
334}
335
huang lin3f2ef132015-11-17 14:20:16 +0800336static int rk3036_clk_bind(struct udevice *dev)
337{
Stephen Warren135aa952016-06-17 09:44:00 -0600338 int ret;
Kever Yangf24e36d2017-11-03 15:16:13 +0800339 struct udevice *sys_child;
340 struct sysreset_reg *priv;
huang lin3f2ef132015-11-17 14:20:16 +0800341
342 /* The reset driver does not have a device node, so bind it here */
Kever Yangf24e36d2017-11-03 15:16:13 +0800343 ret = device_bind_driver(dev, "rockchip_sysreset", "sysreset",
344 &sys_child);
345 if (ret) {
346 debug("Warning: No sysreset driver: ret=%d\n", ret);
347 } else {
348 priv = malloc(sizeof(struct sysreset_reg));
349 priv->glb_srst_fst_value = offsetof(struct rk3036_cru,
350 cru_glb_srst_fst_value);
351 priv->glb_srst_snd_value = offsetof(struct rk3036_cru,
352 cru_glb_srst_snd_value);
353 sys_child->priv = priv;
354 }
huang lin3f2ef132015-11-17 14:20:16 +0800355
Heiko Stuebnera5ada252019-11-09 00:06:30 +0100356#if CONFIG_IS_ENABLED(RESET_ROCKCHIP)
Elaine Zhang538f67c2017-12-19 18:22:38 +0800357 ret = offsetof(struct rk3036_cru, cru_softrst_con[0]);
358 ret = rockchip_reset_bind(dev, ret, 9);
359 if (ret)
360 debug("Warning: software reset driver bind faile\n");
361#endif
362
huang lin3f2ef132015-11-17 14:20:16 +0800363 return 0;
364}
365
366static const struct udevice_id rk3036_clk_ids[] = {
367 { .compatible = "rockchip,rk3036-cru" },
368 { }
369};
370
Simon Glass92ac73e2016-10-01 20:04:50 -0600371U_BOOT_DRIVER(rockchip_rk3036_cru) = {
huang lin3f2ef132015-11-17 14:20:16 +0800372 .name = "clk_rk3036",
373 .id = UCLASS_CLK,
374 .of_match = rk3036_clk_ids,
375 .priv_auto_alloc_size = sizeof(struct rk3036_clk_priv),
Kever Yangaccaaea2018-04-24 11:27:06 +0800376 .ofdata_to_platdata = rk3036_clk_ofdata_to_platdata,
huang lin3f2ef132015-11-17 14:20:16 +0800377 .ops = &rk3036_clk_ops,
378 .bind = rk3036_clk_bind,
379 .probe = rk3036_clk_probe,
380};