Skip to content

Commit 07b293c

Browse files
YueHaibingthierryreding
authored andcommitted
clk: tegra: Fix build error without CONFIG_PM_SLEEP
If CONFIG_PM_SLEEP is n, build fails: drivers/clk/tegra/clk-tegra210.c:3426:13: error: tegra210_clk_suspend undeclared here (not in a function); did you mean tegra_clk_ndspeed? .suspend = tegra210_clk_suspend, ^~~~~~~~~~~~~~~~~~~~ tegra_clk_ndspeed drivers/clk/tegra/clk-tegra210.c:3427:12: error: tegra210_clk_resume undeclared here (not in a function); did you mean tegra210_clk_suspend? .resume = tegra210_clk_resume, Use ifdef to guard this. Reported-by: Hulk Robot <[email protected]> Fixes: 27d10d5 ("clk: tegra: Add suspend and resume support on Tegra210") Signed-off-by: YueHaibing <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
1 parent 5699d16 commit 07b293c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/clk/tegra/clk-tegra210.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3423,8 +3423,10 @@ static void tegra210_cpu_clock_resume(void)
34233423
#endif
34243424

34253425
static struct syscore_ops tegra_clk_syscore_ops = {
3426+
#ifdef CONFIG_PM_SLEEP
34263427
.suspend = tegra210_clk_suspend,
34273428
.resume = tegra210_clk_resume,
3429+
#endif
34283430
};
34293431

34303432
static struct tegra_cpu_car_ops tegra210_cpu_car_ops = {

0 commit comments

Comments
 (0)