.. | .. |
---|
239 | 239 | .set_rate = clk_pllv2_set_rate, |
---|
240 | 240 | }; |
---|
241 | 241 | |
---|
242 | | -struct clk *imx_clk_pllv2(const char *name, const char *parent, |
---|
| 242 | +struct clk_hw *imx_clk_hw_pllv2(const char *name, const char *parent, |
---|
243 | 243 | void __iomem *base) |
---|
244 | 244 | { |
---|
245 | 245 | struct clk_pllv2 *pll; |
---|
246 | | - struct clk *clk; |
---|
247 | | - struct clk_init_data init = {}; |
---|
| 246 | + struct clk_hw *hw; |
---|
| 247 | + struct clk_init_data init; |
---|
| 248 | + int ret; |
---|
248 | 249 | |
---|
249 | 250 | pll = kzalloc(sizeof(*pll), GFP_KERNEL); |
---|
250 | 251 | if (!pll) |
---|
.. | .. |
---|
259 | 260 | init.num_parents = 1; |
---|
260 | 261 | |
---|
261 | 262 | pll->hw.init = &init; |
---|
| 263 | + hw = &pll->hw; |
---|
262 | 264 | |
---|
263 | | - clk = clk_register(NULL, &pll->hw); |
---|
264 | | - if (IS_ERR(clk)) |
---|
| 265 | + ret = clk_hw_register(NULL, hw); |
---|
| 266 | + if (ret) { |
---|
265 | 267 | kfree(pll); |
---|
| 268 | + return ERR_PTR(ret); |
---|
| 269 | + } |
---|
266 | 270 | |
---|
267 | | - return clk; |
---|
| 271 | + return hw; |
---|
268 | 272 | } |
---|