18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 28c2ecf20Sopenharmony_cistruct regmap; 38c2ecf20Sopenharmony_ci 48c2ecf20Sopenharmony_ci/** 58c2ecf20Sopenharmony_ci * enum icst_control_type - the type of ICST control register 68c2ecf20Sopenharmony_ci */ 78c2ecf20Sopenharmony_cienum icst_control_type { 88c2ecf20Sopenharmony_ci ICST_VERSATILE, /* The standard type, all control bits available */ 98c2ecf20Sopenharmony_ci ICST_INTEGRATOR_AP_CM, /* Only 8 bits of VDW available */ 108c2ecf20Sopenharmony_ci ICST_INTEGRATOR_AP_SYS, /* Only 8 bits of VDW available */ 118c2ecf20Sopenharmony_ci ICST_INTEGRATOR_AP_PCI, /* Odd bit pattern storage */ 128c2ecf20Sopenharmony_ci ICST_INTEGRATOR_CP_CM_CORE, /* Only 8 bits of VDW and 3 bits of OD */ 138c2ecf20Sopenharmony_ci ICST_INTEGRATOR_CP_CM_MEM, /* Only 8 bits of VDW and 3 bits of OD */ 148c2ecf20Sopenharmony_ci ICST_INTEGRATOR_IM_PD1, /* Like the Versatile, all control bits */ 158c2ecf20Sopenharmony_ci}; 168c2ecf20Sopenharmony_ci 178c2ecf20Sopenharmony_ci/** 188c2ecf20Sopenharmony_ci * struct clk_icst_desc - descriptor for the ICST VCO 198c2ecf20Sopenharmony_ci * @params: ICST parameters 208c2ecf20Sopenharmony_ci * @vco_offset: offset to the ICST VCO from the provided memory base 218c2ecf20Sopenharmony_ci * @lock_offset: offset to the ICST VCO locking register from the provided 228c2ecf20Sopenharmony_ci * memory base 238c2ecf20Sopenharmony_ci */ 248c2ecf20Sopenharmony_cistruct clk_icst_desc { 258c2ecf20Sopenharmony_ci const struct icst_params *params; 268c2ecf20Sopenharmony_ci u32 vco_offset; 278c2ecf20Sopenharmony_ci u32 lock_offset; 288c2ecf20Sopenharmony_ci}; 298c2ecf20Sopenharmony_ci 308c2ecf20Sopenharmony_cistruct clk *icst_clk_register(struct device *dev, 318c2ecf20Sopenharmony_ci const struct clk_icst_desc *desc, 328c2ecf20Sopenharmony_ci const char *name, 338c2ecf20Sopenharmony_ci const char *parent_name, 348c2ecf20Sopenharmony_ci void __iomem *base); 358c2ecf20Sopenharmony_ci 368c2ecf20Sopenharmony_cistruct clk *icst_clk_setup(struct device *dev, 378c2ecf20Sopenharmony_ci const struct clk_icst_desc *desc, 388c2ecf20Sopenharmony_ci const char *name, 398c2ecf20Sopenharmony_ci const char *parent_name, 408c2ecf20Sopenharmony_ci struct regmap *map, 418c2ecf20Sopenharmony_ci enum icst_control_type ctype); 42