1 /* SPDX-License-Identifier: BSD-3-Clause */ 2 /* 3 * Copyright (c) 2017-2020, STMicroelectronics 4 */ 5 6 #ifndef __STM32MP1_PMIC_H__ 7 #define __STM32MP1_PMIC_H__ 8 9 #include <kernel/panic.h> 10 11 #ifdef CFG_STPMIC1 12 void stm32mp_pmic_apply_boot_on_config(void); 13 void stm32mp_pmic_apply_lp_config(const char *lp_state); 14 void stm32mp_get_pmic(void); 15 void stm32mp_put_pmic(void); 16 int stm32mp_dt_pmic_status(void); 17 const char *stm32mp_pmic_get_cpu_supply_name(void); 18 #else stm32mp_pmic_apply_boot_on_config(void)19static inline void stm32mp_pmic_apply_boot_on_config(void) 20 { 21 } 22 stm32mp_pmic_apply_lp_config(const char * lp_state __unused)23static inline void stm32mp_pmic_apply_lp_config(const char *lp_state __unused) 24 { 25 } 26 stm32mp_get_pmic(void)27static inline void stm32mp_get_pmic(void) 28 { 29 panic(); 30 } 31 stm32mp_put_pmic(void)32static inline void stm32mp_put_pmic(void) 33 { 34 panic(); 35 } 36 stm32mp_dt_pmic_status(void)37static inline int stm32mp_dt_pmic_status(void) 38 { 39 return -1; 40 } 41 stm32mp_pmic_get_cpu_supply_name(void)42static inline const char *stm32mp_pmic_get_cpu_supply_name(void) 43 { 44 return NULL; 45 } 46 #endif 47 48 #endif /*__STM32MP1_PMIC_H__*/ 49