tps62360.h 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. /*
  2. * tps62360.h -- TI tps62360
  3. *
  4. * Interface for regulator driver for TI TPS62360 Processor core supply
  5. *
  6. * Copyright (C) 2012 NVIDIA Corporation
  7. * Author: Laxman Dewangan <ldewangan@nvidia.com>
  8. *
  9. * This program is free software; you can redistribute it and/or modify
  10. * it under the terms of the GNU General Public License as published by
  11. * the Free Software Foundation; either version 2 of the License, or
  12. * (at your option) any later version.
  13. *
  14. * This program is distributed in the hope that it will be useful, but WITHOUT
  15. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  16. * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
  17. * more details.
  18. *
  19. * You should have received a copy of the GNU General Public License along
  20. * with this program; if not, write to the Free Software Foundation, Inc.,
  21. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  22. *
  23. */
  24. #ifndef __LINUX_REGULATOR_TPS62360_H
  25. #define __LINUX_REGULATOR_TPS62360_H
  26. #include <linux/regulator/machine.h>
  27. /*
  28. * struct tps62360_regulator_platform_data - tps62360 regulator platform data.
  29. *
  30. * @reg_init_data: The regulator init data.
  31. * @en_force_pwm: Enable force pwm or not.
  32. * @en_discharge: Enable discharge the output capacitor via internal
  33. * register.
  34. * @en_internal_pulldn: internal pull down enable or not.
  35. * @vsel0_gpio: Gpio number for vsel0. It should be -1 if this is tied with
  36. * fixed logic.
  37. * @vsel1_gpio: Gpio number for vsel1. It should be -1 if this is tied with
  38. * fixed logic.
  39. * @vsel0_def_state: Default state of vsel0. 1 if it is high else 0.
  40. * @vsel1_def_state: Default state of vsel1. 1 if it is high else 0.
  41. */
  42. struct tps62360_regulator_platform_data {
  43. struct regulator_init_data reg_init_data;
  44. bool en_force_pwm;
  45. bool en_discharge;
  46. bool en_internal_pulldn;
  47. int vsel0_gpio;
  48. int vsel1_gpio;
  49. int vsel0_def_state;
  50. int vsel1_def_state;
  51. };
  52. #endif /* __LINUX_REGULATOR_TPS62360_H */