Commit 0d97651
mailbox: sprd: Use devm_clk_get_enabled() helpers
The devm_clk_get_enabled() helpers:
- call devm_clk_get()
- call clk_prepare_enable() and register what is needed in order to
call clk_disable_unprepare() when needed, as a managed resource.
This simplifies the code and avoids the calls to clk_disable_unprepare().
Due to clk only used in probe, not in suspend\resume, this pointer can
remove from sprd_mbox_priv to save a little memory.
Signed-off-by: Huan Yang <[email protected]>
Reviewed-by: Christophe JAILLET <[email protected]>
Reviewed-by: Baolin Wang <[email protected]>
Signed-off-by: Jassi Brar <[email protected]>1 parent e92d87c commit 0d97651
1 file changed
+4
-21
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
66 | 65 | | |
67 | 66 | | |
68 | 67 | | |
| |||
291 | 290 | | |
292 | 291 | | |
293 | 292 | | |
294 | | - | |
295 | | - | |
296 | | - | |
297 | | - | |
298 | | - | |
299 | | - | |
300 | | - | |
301 | 293 | | |
302 | 294 | | |
303 | 295 | | |
304 | 296 | | |
305 | 297 | | |
306 | 298 | | |
| 299 | + | |
307 | 300 | | |
308 | 301 | | |
309 | 302 | | |
| |||
331 | 324 | | |
332 | 325 | | |
333 | 326 | | |
334 | | - | |
335 | | - | |
| 327 | + | |
| 328 | + | |
336 | 329 | | |
337 | | - | |
338 | | - | |
339 | | - | |
340 | | - | |
341 | | - | |
342 | | - | |
343 | | - | |
344 | | - | |
345 | | - | |
346 | | - | |
347 | | - | |
| 330 | + | |
348 | 331 | | |
349 | 332 | | |
350 | 333 | | |
| |||
0 commit comments