xref: /OK3568_Linux_fs/kernel/include/linux/clk/ti.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun /*
2*4882a593Smuzhiyun  * TI clock drivers support
3*4882a593Smuzhiyun  *
4*4882a593Smuzhiyun  * Copyright (C) 2013 Texas Instruments, Inc.
5*4882a593Smuzhiyun  *
6*4882a593Smuzhiyun  * This program is free software; you can redistribute it and/or modify
7*4882a593Smuzhiyun  * it under the terms of the GNU General Public License version 2 as
8*4882a593Smuzhiyun  * published by the Free Software Foundation.
9*4882a593Smuzhiyun  *
10*4882a593Smuzhiyun  * This program is distributed "as is" WITHOUT ANY WARRANTY of any
11*4882a593Smuzhiyun  * kind, whether express or implied; without even the implied warranty
12*4882a593Smuzhiyun  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13*4882a593Smuzhiyun  * GNU General Public License for more details.
14*4882a593Smuzhiyun  */
15*4882a593Smuzhiyun #ifndef __LINUX_CLK_TI_H__
16*4882a593Smuzhiyun #define __LINUX_CLK_TI_H__
17*4882a593Smuzhiyun 
18*4882a593Smuzhiyun #include <linux/clk-provider.h>
19*4882a593Smuzhiyun #include <linux/clkdev.h>
20*4882a593Smuzhiyun 
21*4882a593Smuzhiyun /**
22*4882a593Smuzhiyun  * struct clk_omap_reg - OMAP register declaration
23*4882a593Smuzhiyun  * @offset: offset from the master IP module base address
24*4882a593Smuzhiyun  * @index: index of the master IP module
25*4882a593Smuzhiyun  */
26*4882a593Smuzhiyun struct clk_omap_reg {
27*4882a593Smuzhiyun 	void __iomem *ptr;
28*4882a593Smuzhiyun 	u16 offset;
29*4882a593Smuzhiyun 	u8 index;
30*4882a593Smuzhiyun 	u8 flags;
31*4882a593Smuzhiyun };
32*4882a593Smuzhiyun 
33*4882a593Smuzhiyun /**
34*4882a593Smuzhiyun  * struct dpll_data - DPLL registers and integration data
35*4882a593Smuzhiyun  * @mult_div1_reg: register containing the DPLL M and N bitfields
36*4882a593Smuzhiyun  * @mult_mask: mask of the DPLL M bitfield in @mult_div1_reg
37*4882a593Smuzhiyun  * @div1_mask: mask of the DPLL N bitfield in @mult_div1_reg
38*4882a593Smuzhiyun  * @clk_bypass: struct clk_hw pointer to the clock's bypass clock input
39*4882a593Smuzhiyun  * @clk_ref: struct clk_hw pointer to the clock's reference clock input
40*4882a593Smuzhiyun  * @control_reg: register containing the DPLL mode bitfield
41*4882a593Smuzhiyun  * @enable_mask: mask of the DPLL mode bitfield in @control_reg
42*4882a593Smuzhiyun  * @last_rounded_rate: cache of the last rate result of omap2_dpll_round_rate()
43*4882a593Smuzhiyun  * @last_rounded_m: cache of the last M result of omap2_dpll_round_rate()
44*4882a593Smuzhiyun  * @last_rounded_m4xen: cache of the last M4X result of
45*4882a593Smuzhiyun  *			omap4_dpll_regm4xen_round_rate()
46*4882a593Smuzhiyun  * @last_rounded_lpmode: cache of the last lpmode result of
47*4882a593Smuzhiyun  *			 omap4_dpll_lpmode_recalc()
48*4882a593Smuzhiyun  * @max_multiplier: maximum valid non-bypass multiplier value (actual)
49*4882a593Smuzhiyun  * @last_rounded_n: cache of the last N result of omap2_dpll_round_rate()
50*4882a593Smuzhiyun  * @min_divider: minimum valid non-bypass divider value (actual)
51*4882a593Smuzhiyun  * @max_divider: maximum valid non-bypass divider value (actual)
52*4882a593Smuzhiyun  * @max_rate: maximum clock rate for the DPLL
53*4882a593Smuzhiyun  * @modes: possible values of @enable_mask
54*4882a593Smuzhiyun  * @autoidle_reg: register containing the DPLL autoidle mode bitfield
55*4882a593Smuzhiyun  * @idlest_reg: register containing the DPLL idle status bitfield
56*4882a593Smuzhiyun  * @autoidle_mask: mask of the DPLL autoidle mode bitfield in @autoidle_reg
57*4882a593Smuzhiyun  * @freqsel_mask: mask of the DPLL jitter correction bitfield in @control_reg
58*4882a593Smuzhiyun  * @dcc_mask: mask of the DPLL DCC correction bitfield @mult_div1_reg
59*4882a593Smuzhiyun  * @dcc_rate: rate atleast which DCC @dcc_mask must be set
60*4882a593Smuzhiyun  * @idlest_mask: mask of the DPLL idle status bitfield in @idlest_reg
61*4882a593Smuzhiyun  * @lpmode_mask: mask of the DPLL low-power mode bitfield in @control_reg
62*4882a593Smuzhiyun  * @m4xen_mask: mask of the DPLL M4X multiplier bitfield in @control_reg
63*4882a593Smuzhiyun  * @auto_recal_bit: bitshift of the driftguard enable bit in @control_reg
64*4882a593Smuzhiyun  * @recal_en_bit: bitshift of the PRM_IRQENABLE_* bit for recalibration IRQs
65*4882a593Smuzhiyun  * @recal_st_bit: bitshift of the PRM_IRQSTATUS_* bit for recalibration IRQs
66*4882a593Smuzhiyun  * @flags: DPLL type/features (see below)
67*4882a593Smuzhiyun  *
68*4882a593Smuzhiyun  * Possible values for @flags:
69*4882a593Smuzhiyun  * DPLL_J_TYPE: "J-type DPLL" (only some 36xx, 4xxx DPLLs)
70*4882a593Smuzhiyun  *
71*4882a593Smuzhiyun  * @freqsel_mask is only used on the OMAP34xx family and AM35xx.
72*4882a593Smuzhiyun  *
73*4882a593Smuzhiyun  * XXX Some DPLLs have multiple bypass inputs, so it's not technically
74*4882a593Smuzhiyun  * correct to only have one @clk_bypass pointer.
75*4882a593Smuzhiyun  *
76*4882a593Smuzhiyun  * XXX The runtime-variable fields (@last_rounded_rate, @last_rounded_m,
77*4882a593Smuzhiyun  * @last_rounded_n) should be separated from the runtime-fixed fields
78*4882a593Smuzhiyun  * and placed into a different structure, so that the runtime-fixed data
79*4882a593Smuzhiyun  * can be placed into read-only space.
80*4882a593Smuzhiyun  */
81*4882a593Smuzhiyun struct dpll_data {
82*4882a593Smuzhiyun 	struct clk_omap_reg	mult_div1_reg;
83*4882a593Smuzhiyun 	u32			mult_mask;
84*4882a593Smuzhiyun 	u32			div1_mask;
85*4882a593Smuzhiyun 	struct clk_hw		*clk_bypass;
86*4882a593Smuzhiyun 	struct clk_hw		*clk_ref;
87*4882a593Smuzhiyun 	struct clk_omap_reg	control_reg;
88*4882a593Smuzhiyun 	u32			enable_mask;
89*4882a593Smuzhiyun 	unsigned long		last_rounded_rate;
90*4882a593Smuzhiyun 	u16			last_rounded_m;
91*4882a593Smuzhiyun 	u8			last_rounded_m4xen;
92*4882a593Smuzhiyun 	u8			last_rounded_lpmode;
93*4882a593Smuzhiyun 	u16			max_multiplier;
94*4882a593Smuzhiyun 	u8			last_rounded_n;
95*4882a593Smuzhiyun 	u8			min_divider;
96*4882a593Smuzhiyun 	u16			max_divider;
97*4882a593Smuzhiyun 	unsigned long		max_rate;
98*4882a593Smuzhiyun 	u8			modes;
99*4882a593Smuzhiyun 	struct clk_omap_reg	autoidle_reg;
100*4882a593Smuzhiyun 	struct clk_omap_reg	idlest_reg;
101*4882a593Smuzhiyun 	u32			autoidle_mask;
102*4882a593Smuzhiyun 	u32			freqsel_mask;
103*4882a593Smuzhiyun 	u32			idlest_mask;
104*4882a593Smuzhiyun 	u32			dco_mask;
105*4882a593Smuzhiyun 	u32			sddiv_mask;
106*4882a593Smuzhiyun 	u32			dcc_mask;
107*4882a593Smuzhiyun 	unsigned long		dcc_rate;
108*4882a593Smuzhiyun 	u32			lpmode_mask;
109*4882a593Smuzhiyun 	u32			m4xen_mask;
110*4882a593Smuzhiyun 	u8			auto_recal_bit;
111*4882a593Smuzhiyun 	u8			recal_en_bit;
112*4882a593Smuzhiyun 	u8			recal_st_bit;
113*4882a593Smuzhiyun 	u8			flags;
114*4882a593Smuzhiyun };
115*4882a593Smuzhiyun 
116*4882a593Smuzhiyun struct clk_hw_omap;
117*4882a593Smuzhiyun 
118*4882a593Smuzhiyun /**
119*4882a593Smuzhiyun  * struct clk_hw_omap_ops - OMAP clk ops
120*4882a593Smuzhiyun  * @find_idlest: find idlest register information for a clock
121*4882a593Smuzhiyun  * @find_companion: find companion clock register information for a clock,
122*4882a593Smuzhiyun  *		    basically converts CM_ICLKEN* <-> CM_FCLKEN*
123*4882a593Smuzhiyun  * @allow_idle: enables autoidle hardware functionality for a clock
124*4882a593Smuzhiyun  * @deny_idle: prevent autoidle hardware functionality for a clock
125*4882a593Smuzhiyun  */
126*4882a593Smuzhiyun struct clk_hw_omap_ops {
127*4882a593Smuzhiyun 	void	(*find_idlest)(struct clk_hw_omap *oclk,
128*4882a593Smuzhiyun 			       struct clk_omap_reg *idlest_reg,
129*4882a593Smuzhiyun 			       u8 *idlest_bit, u8 *idlest_val);
130*4882a593Smuzhiyun 	void	(*find_companion)(struct clk_hw_omap *oclk,
131*4882a593Smuzhiyun 				  struct clk_omap_reg *other_reg,
132*4882a593Smuzhiyun 				  u8 *other_bit);
133*4882a593Smuzhiyun 	void	(*allow_idle)(struct clk_hw_omap *oclk);
134*4882a593Smuzhiyun 	void	(*deny_idle)(struct clk_hw_omap *oclk);
135*4882a593Smuzhiyun };
136*4882a593Smuzhiyun 
137*4882a593Smuzhiyun /**
138*4882a593Smuzhiyun  * struct clk_hw_omap - OMAP struct clk
139*4882a593Smuzhiyun  * @node: list_head connecting this clock into the full clock list
140*4882a593Smuzhiyun  * @enable_reg: register to write to enable the clock (see @enable_bit)
141*4882a593Smuzhiyun  * @enable_bit: bitshift to write to enable/disable the clock (see @enable_reg)
142*4882a593Smuzhiyun  * @flags: see "struct clk.flags possibilities" above
143*4882a593Smuzhiyun  * @clksel_reg: for clksel clks, register va containing src/divisor select
144*4882a593Smuzhiyun  * @dpll_data: for DPLLs, pointer to struct dpll_data for this clock
145*4882a593Smuzhiyun  * @clkdm_name: clockdomain name that this clock is contained in
146*4882a593Smuzhiyun  * @clkdm: pointer to struct clockdomain, resolved from @clkdm_name at runtime
147*4882a593Smuzhiyun  * @ops: clock ops for this clock
148*4882a593Smuzhiyun  */
149*4882a593Smuzhiyun struct clk_hw_omap {
150*4882a593Smuzhiyun 	struct clk_hw		hw;
151*4882a593Smuzhiyun 	struct list_head	node;
152*4882a593Smuzhiyun 	unsigned long		fixed_rate;
153*4882a593Smuzhiyun 	u8			fixed_div;
154*4882a593Smuzhiyun 	struct clk_omap_reg	enable_reg;
155*4882a593Smuzhiyun 	u8			enable_bit;
156*4882a593Smuzhiyun 	unsigned long		flags;
157*4882a593Smuzhiyun 	struct clk_omap_reg	clksel_reg;
158*4882a593Smuzhiyun 	struct dpll_data	*dpll_data;
159*4882a593Smuzhiyun 	const char		*clkdm_name;
160*4882a593Smuzhiyun 	struct clockdomain	*clkdm;
161*4882a593Smuzhiyun 	const struct clk_hw_omap_ops	*ops;
162*4882a593Smuzhiyun 	u32			context;
163*4882a593Smuzhiyun 	int			autoidle_count;
164*4882a593Smuzhiyun };
165*4882a593Smuzhiyun 
166*4882a593Smuzhiyun /*
167*4882a593Smuzhiyun  * struct clk_hw_omap.flags possibilities
168*4882a593Smuzhiyun  *
169*4882a593Smuzhiyun  * XXX document the rest of the clock flags here
170*4882a593Smuzhiyun  *
171*4882a593Smuzhiyun  * ENABLE_REG_32BIT: (OMAP1 only) clock control register must be accessed
172*4882a593Smuzhiyun  *     with 32bit ops, by default OMAP1 uses 16bit ops.
173*4882a593Smuzhiyun  * CLOCK_IDLE_CONTROL: (OMAP1 only) clock has autoidle support.
174*4882a593Smuzhiyun  * CLOCK_NO_IDLE_PARENT: (OMAP1 only) when clock is enabled, its parent
175*4882a593Smuzhiyun  *     clock is put to no-idle mode.
176*4882a593Smuzhiyun  * ENABLE_ON_INIT: Clock is enabled on init.
177*4882a593Smuzhiyun  * INVERT_ENABLE: By default, clock enable bit behavior is '1' enable, '0'
178*4882a593Smuzhiyun  *     disable. This inverts the behavior making '0' enable and '1' disable.
179*4882a593Smuzhiyun  * CLOCK_CLKOUTX2: (OMAP4 only) DPLL CLKOUT and CLKOUTX2 GATE_CTRL
180*4882a593Smuzhiyun  *     bits share the same register.  This flag allows the
181*4882a593Smuzhiyun  *     omap4_dpllmx*() code to determine which GATE_CTRL bit field
182*4882a593Smuzhiyun  *     should be used.  This is a temporary solution - a better approach
183*4882a593Smuzhiyun  *     would be to associate clock type-specific data with the clock,
184*4882a593Smuzhiyun  *     similar to the struct dpll_data approach.
185*4882a593Smuzhiyun  */
186*4882a593Smuzhiyun #define ENABLE_REG_32BIT	(1 << 0)	/* Use 32-bit access */
187*4882a593Smuzhiyun #define CLOCK_IDLE_CONTROL	(1 << 1)
188*4882a593Smuzhiyun #define CLOCK_NO_IDLE_PARENT	(1 << 2)
189*4882a593Smuzhiyun #define ENABLE_ON_INIT		(1 << 3)	/* Enable upon framework init */
190*4882a593Smuzhiyun #define INVERT_ENABLE		(1 << 4)	/* 0 enables, 1 disables */
191*4882a593Smuzhiyun #define CLOCK_CLKOUTX2		(1 << 5)
192*4882a593Smuzhiyun 
193*4882a593Smuzhiyun /* CM_CLKEN_PLL*.EN* bit values - not all are available for every DPLL */
194*4882a593Smuzhiyun #define DPLL_LOW_POWER_STOP	0x1
195*4882a593Smuzhiyun #define DPLL_LOW_POWER_BYPASS	0x5
196*4882a593Smuzhiyun #define DPLL_LOCKED		0x7
197*4882a593Smuzhiyun 
198*4882a593Smuzhiyun /* DPLL Type and DCO Selection Flags */
199*4882a593Smuzhiyun #define DPLL_J_TYPE		0x1
200*4882a593Smuzhiyun 
201*4882a593Smuzhiyun /* Static memmap indices */
202*4882a593Smuzhiyun enum {
203*4882a593Smuzhiyun 	TI_CLKM_CM = 0,
204*4882a593Smuzhiyun 	TI_CLKM_CM2,
205*4882a593Smuzhiyun 	TI_CLKM_PRM,
206*4882a593Smuzhiyun 	TI_CLKM_SCRM,
207*4882a593Smuzhiyun 	TI_CLKM_CTRL,
208*4882a593Smuzhiyun 	TI_CLKM_CTRL_AUX,
209*4882a593Smuzhiyun 	TI_CLKM_PLLSS,
210*4882a593Smuzhiyun 	CLK_MAX_MEMMAPS
211*4882a593Smuzhiyun };
212*4882a593Smuzhiyun 
213*4882a593Smuzhiyun /**
214*4882a593Smuzhiyun  * struct ti_clk_ll_ops - low-level ops for clocks
215*4882a593Smuzhiyun  * @clk_readl: pointer to register read function
216*4882a593Smuzhiyun  * @clk_writel: pointer to register write function
217*4882a593Smuzhiyun  * @clk_rmw: pointer to register read-modify-write function
218*4882a593Smuzhiyun  * @clkdm_clk_enable: pointer to clockdomain enable function
219*4882a593Smuzhiyun  * @clkdm_clk_disable: pointer to clockdomain disable function
220*4882a593Smuzhiyun  * @clkdm_lookup: pointer to clockdomain lookup function
221*4882a593Smuzhiyun  * @cm_wait_module_ready: pointer to CM module wait ready function
222*4882a593Smuzhiyun  * @cm_split_idlest_reg: pointer to CM module function to split idlest reg
223*4882a593Smuzhiyun  *
224*4882a593Smuzhiyun  * Low-level ops are generally used by the basic clock types (clk-gate,
225*4882a593Smuzhiyun  * clk-mux, clk-divider etc.) to provide support for various low-level
226*4882a593Smuzhiyun  * hadrware interfaces (direct MMIO, regmap etc.), and is initialized
227*4882a593Smuzhiyun  * by board code. Low-level ops also contain some other platform specific
228*4882a593Smuzhiyun  * operations not provided directly by clock drivers.
229*4882a593Smuzhiyun  */
230*4882a593Smuzhiyun struct ti_clk_ll_ops {
231*4882a593Smuzhiyun 	u32	(*clk_readl)(const struct clk_omap_reg *reg);
232*4882a593Smuzhiyun 	void	(*clk_writel)(u32 val, const struct clk_omap_reg *reg);
233*4882a593Smuzhiyun 	void	(*clk_rmw)(u32 val, u32 mask, const struct clk_omap_reg *reg);
234*4882a593Smuzhiyun 	int	(*clkdm_clk_enable)(struct clockdomain *clkdm, struct clk *clk);
235*4882a593Smuzhiyun 	int	(*clkdm_clk_disable)(struct clockdomain *clkdm,
236*4882a593Smuzhiyun 				     struct clk *clk);
237*4882a593Smuzhiyun 	struct clockdomain * (*clkdm_lookup)(const char *name);
238*4882a593Smuzhiyun 	int	(*cm_wait_module_ready)(u8 part, s16 prcm_mod, u16 idlest_reg,
239*4882a593Smuzhiyun 					u8 idlest_shift);
240*4882a593Smuzhiyun 	int	(*cm_split_idlest_reg)(struct clk_omap_reg *idlest_reg,
241*4882a593Smuzhiyun 				       s16 *prcm_inst, u8 *idlest_reg_id);
242*4882a593Smuzhiyun };
243*4882a593Smuzhiyun 
244*4882a593Smuzhiyun #define to_clk_hw_omap(_hw) container_of(_hw, struct clk_hw_omap, hw)
245*4882a593Smuzhiyun 
246*4882a593Smuzhiyun bool omap2_clk_is_hw_omap(struct clk_hw *hw);
247*4882a593Smuzhiyun int omap2_clk_disable_autoidle_all(void);
248*4882a593Smuzhiyun int omap2_clk_enable_autoidle_all(void);
249*4882a593Smuzhiyun int omap2_clk_allow_idle(struct clk *clk);
250*4882a593Smuzhiyun int omap2_clk_deny_idle(struct clk *clk);
251*4882a593Smuzhiyun unsigned long omap2_dpllcore_recalc(struct clk_hw *hw,
252*4882a593Smuzhiyun 				    unsigned long parent_rate);
253*4882a593Smuzhiyun int omap2_reprogram_dpllcore(struct clk_hw *clk, unsigned long rate,
254*4882a593Smuzhiyun 			     unsigned long parent_rate);
255*4882a593Smuzhiyun void omap2xxx_clkt_dpllcore_init(struct clk_hw *hw);
256*4882a593Smuzhiyun void omap2xxx_clkt_vps_init(void);
257*4882a593Smuzhiyun unsigned long omap2_get_dpll_rate(struct clk_hw_omap *clk);
258*4882a593Smuzhiyun 
259*4882a593Smuzhiyun void ti_dt_clk_init_retry_clks(void);
260*4882a593Smuzhiyun void ti_dt_clockdomains_setup(void);
261*4882a593Smuzhiyun int ti_clk_setup_ll_ops(struct ti_clk_ll_ops *ops);
262*4882a593Smuzhiyun 
263*4882a593Smuzhiyun struct regmap;
264*4882a593Smuzhiyun 
265*4882a593Smuzhiyun int omap2_clk_provider_init(struct device_node *parent, int index,
266*4882a593Smuzhiyun 			    struct regmap *syscon, void __iomem *mem);
267*4882a593Smuzhiyun void omap2_clk_legacy_provider_init(int index, void __iomem *mem);
268*4882a593Smuzhiyun 
269*4882a593Smuzhiyun int omap3430_dt_clk_init(void);
270*4882a593Smuzhiyun int omap3630_dt_clk_init(void);
271*4882a593Smuzhiyun int am35xx_dt_clk_init(void);
272*4882a593Smuzhiyun int dm814x_dt_clk_init(void);
273*4882a593Smuzhiyun int dm816x_dt_clk_init(void);
274*4882a593Smuzhiyun int omap4xxx_dt_clk_init(void);
275*4882a593Smuzhiyun int omap5xxx_dt_clk_init(void);
276*4882a593Smuzhiyun int dra7xx_dt_clk_init(void);
277*4882a593Smuzhiyun int am33xx_dt_clk_init(void);
278*4882a593Smuzhiyun int am43xx_dt_clk_init(void);
279*4882a593Smuzhiyun int omap2420_dt_clk_init(void);
280*4882a593Smuzhiyun int omap2430_dt_clk_init(void);
281*4882a593Smuzhiyun 
282*4882a593Smuzhiyun struct ti_clk_features {
283*4882a593Smuzhiyun 	u32 flags;
284*4882a593Smuzhiyun 	long fint_min;
285*4882a593Smuzhiyun 	long fint_max;
286*4882a593Smuzhiyun 	long fint_band1_max;
287*4882a593Smuzhiyun 	long fint_band2_min;
288*4882a593Smuzhiyun 	u8 dpll_bypass_vals;
289*4882a593Smuzhiyun 	u8 cm_idlest_val;
290*4882a593Smuzhiyun };
291*4882a593Smuzhiyun 
292*4882a593Smuzhiyun #define TI_CLK_DPLL_HAS_FREQSEL			BIT(0)
293*4882a593Smuzhiyun #define TI_CLK_DPLL4_DENY_REPROGRAM		BIT(1)
294*4882a593Smuzhiyun #define TI_CLK_DISABLE_CLKDM_CONTROL		BIT(2)
295*4882a593Smuzhiyun #define TI_CLK_ERRATA_I810			BIT(3)
296*4882a593Smuzhiyun #define TI_CLK_CLKCTRL_COMPAT			BIT(4)
297*4882a593Smuzhiyun #define TI_CLK_DEVICE_TYPE_GP			BIT(5)
298*4882a593Smuzhiyun 
299*4882a593Smuzhiyun void ti_clk_setup_features(struct ti_clk_features *features);
300*4882a593Smuzhiyun const struct ti_clk_features *ti_clk_get_features(void);
301*4882a593Smuzhiyun bool ti_clk_is_in_standby(struct clk *clk);
302*4882a593Smuzhiyun int omap3_noncore_dpll_save_context(struct clk_hw *hw);
303*4882a593Smuzhiyun void omap3_noncore_dpll_restore_context(struct clk_hw *hw);
304*4882a593Smuzhiyun 
305*4882a593Smuzhiyun int omap3_core_dpll_save_context(struct clk_hw *hw);
306*4882a593Smuzhiyun void omap3_core_dpll_restore_context(struct clk_hw *hw);
307*4882a593Smuzhiyun 
308*4882a593Smuzhiyun extern const struct clk_hw_omap_ops clkhwops_omap2xxx_dpll;
309*4882a593Smuzhiyun 
310*4882a593Smuzhiyun #ifdef CONFIG_ATAGS
311*4882a593Smuzhiyun int omap3430_clk_legacy_init(void);
312*4882a593Smuzhiyun int omap3430es1_clk_legacy_init(void);
313*4882a593Smuzhiyun int omap36xx_clk_legacy_init(void);
314*4882a593Smuzhiyun int am35xx_clk_legacy_init(void);
315*4882a593Smuzhiyun #else
omap3430_clk_legacy_init(void)316*4882a593Smuzhiyun static inline int omap3430_clk_legacy_init(void) { return -ENXIO; }
omap3430es1_clk_legacy_init(void)317*4882a593Smuzhiyun static inline int omap3430es1_clk_legacy_init(void) { return -ENXIO; }
omap36xx_clk_legacy_init(void)318*4882a593Smuzhiyun static inline int omap36xx_clk_legacy_init(void) { return -ENXIO; }
am35xx_clk_legacy_init(void)319*4882a593Smuzhiyun static inline int am35xx_clk_legacy_init(void) { return -ENXIO; }
320*4882a593Smuzhiyun #endif
321*4882a593Smuzhiyun 
322*4882a593Smuzhiyun 
323*4882a593Smuzhiyun #endif
324