Skip to content

Commit aecf425

Browse files
Dong Aishengabelvesa
authored andcommitted
clk: imx: scu: bypass cpu clock save and restore
CPU clock is managed by ATF. No need save and restore. Signed-off-by: Dong Aisheng <[email protected]> Reviewed-by: Abel Vesa <[email protected]> Signed-off-by: Abel Vesa <[email protected]>
1 parent b192d04 commit aecf425

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

drivers/clk/imx/clk-scu.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -538,6 +538,11 @@ static int imx_clk_scu_probe(struct platform_device *pdev)
538538
static int __maybe_unused imx_clk_scu_suspend(struct device *dev)
539539
{
540540
struct clk_scu *clk = dev_get_drvdata(dev);
541+
u32 rsrc_id = clk->rsrc_id;
542+
543+
if ((rsrc_id == IMX_SC_R_A35) || (rsrc_id == IMX_SC_R_A53) ||
544+
(rsrc_id == IMX_SC_R_A72))
545+
return 0;
541546

542547
clk->rate = clk_hw_get_rate(&clk->hw);
543548
clk->is_enabled = clk_hw_is_enabled(&clk->hw);
@@ -554,8 +559,13 @@ static int __maybe_unused imx_clk_scu_suspend(struct device *dev)
554559
static int __maybe_unused imx_clk_scu_resume(struct device *dev)
555560
{
556561
struct clk_scu *clk = dev_get_drvdata(dev);
562+
u32 rsrc_id = clk->rsrc_id;
557563
int ret = 0;
558564

565+
if ((rsrc_id == IMX_SC_R_A35) || (rsrc_id == IMX_SC_R_A53) ||
566+
(rsrc_id == IMX_SC_R_A72))
567+
return 0;
568+
559569
if (clk->rate) {
560570
ret = clk_scu_set_rate(&clk->hw, clk->rate, 0);
561571
dev_dbg(dev, "restore rate %d %s\n", clk->rate,

0 commit comments

Comments
 (0)