From bdd6af7b03125abceeeb01c55e495e0e4c087b09 Mon Sep 17 00:00:00 2001 From: Jianxin Pan Date: Sun, 31 Mar 2019 00:32:00 +0800 Subject: [PATCH] compile: fix smarthome compile error [1/1] PD#SWPL-6186 Problem: smarthome compile error Solution: fix smarthome compile error Verify: compile OK Change-Id: I6909374b8abbeac8ccb4bca760208d309d24f4bd Signed-off-by: Jianxin Pan --- include/linux/amlogic/power_ctrl.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/include/linux/amlogic/power_ctrl.h b/include/linux/amlogic/power_ctrl.h index 46cc3cd1b9a9..5b6f7213539e 100644 --- a/include/linux/amlogic/power_ctrl.h +++ b/include/linux/amlogic/power_ctrl.h @@ -19,7 +19,25 @@ #define _POWER_CTRL_H_ #include +#ifdef CONFIG_AMLOGIC_POWER int power_ctrl_sleep(bool power_on, unsigned int shift); int power_ctrl_iso(bool power_on, unsigned int shift); int power_ctrl_mempd0(bool power_on, unsigned int mask_val, unsigned int shift); +#else +static inline int power_ctrl_sleep(bool power_on, unsigned int shift) +{ + return -EINVAL; +} + +static inline int power_ctrl_iso(bool power_on, unsigned int shift) +{ + return -EINVAL; +} + +static inline int power_ctrl_mempd0(bool power_on, unsigned int mask_val, + unsigned int shift) +{ + return -EINVAL; +} +#endif #endif /*_POWER_CTRL_H_*/