dbx500-prcmu.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * Copyright (C) ST-Ericsson SA 2010
  4. *
  5. * Author: Bengt Jonsson <bengt.jonsson@stericsson.com> for ST-Ericsson,
  6. * Jonas Aaberg <jonas.aberg@stericsson.com> for ST-Ericsson
  7. */
  8. #ifndef DBX500_REGULATOR_H
  9. #define DBX500_REGULATOR_H
  10. #include <linux/platform_device.h>
  11. /**
  12. * struct dbx500_regulator_info - dbx500 regulator information
  13. * @desc: regulator description
  14. * @is_enabled: status of the regulator
  15. * @epod_id: id for EPOD (power domain)
  16. * @is_ramret: RAM retention switch for EPOD (power domain)
  17. *
  18. */
  19. struct dbx500_regulator_info {
  20. struct regulator_desc desc;
  21. bool is_enabled;
  22. u16 epod_id;
  23. bool is_ramret;
  24. bool exclude_from_power_state;
  25. };
  26. void power_state_active_enable(void);
  27. int power_state_active_disable(void);
  28. #ifdef CONFIG_REGULATOR_DEBUG
  29. int ux500_regulator_debug_init(struct platform_device *pdev,
  30. struct dbx500_regulator_info *regulator_info,
  31. int num_regulators);
  32. int ux500_regulator_debug_exit(void);
  33. #else
  34. static inline int ux500_regulator_debug_init(struct platform_device *pdev,
  35. struct dbx500_regulator_info *regulator_info,
  36. int num_regulators)
  37. {
  38. return 0;
  39. }
  40. static inline int ux500_regulator_debug_exit(void)
  41. {
  42. return 0;
  43. }
  44. #endif
  45. #endif