max8998_pmic.h 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. /*
  2. * Copyright (C) 2011 Samsung Electronics
  3. * Lukasz Majewski <l.majewski@samsung.com>
  4. *
  5. * See file CREDITS for list of people who contributed to this
  6. * project.
  7. *
  8. * This program is free software; you can redistribute it and/or
  9. * modify it under the terms of the GNU General Public License as
  10. * published by the Free Software Foundation; either version 2 of
  11. * the License, or (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program; if not, write to the Free Software
  20. * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  21. * MA 02111-1307 USA
  22. */
  23. #ifndef __MAX8998_PMIC_H_
  24. #define __MAX8998_PMIC_H_
  25. /* MAX 8998 registers */
  26. enum {
  27. MAX8998_REG_IRQ1,
  28. MAX8998_REG_IRQ2,
  29. MAX8998_REG_IRQ3,
  30. MAX8998_REG_IRQ4,
  31. MAX8998_REG_IRQM1,
  32. MAX8998_REG_IRQM2,
  33. MAX8998_REG_IRQM3,
  34. MAX8998_REG_IRQM4,
  35. MAX8998_REG_STATUS1,
  36. MAX8998_REG_STATUS2,
  37. MAX8998_REG_STATUSM1,
  38. MAX8998_REG_STATUSM2,
  39. MAX8998_REG_CHGR1,
  40. MAX8998_REG_CHGR2,
  41. MAX8998_REG_LDO_ACTIVE_DISCHARGE1,
  42. MAX8998_REG_LDO_ACTIVE_DISCHARGE2,
  43. MAX8998_REG_BUCK_ACTIVE_DISCHARGE3,
  44. MAX8998_REG_ONOFF1,
  45. MAX8998_REG_ONOFF2,
  46. MAX8998_REG_ONOFF3,
  47. MAX8998_REG_ONOFF4,
  48. MAX8998_REG_BUCK1_VOLTAGE1,
  49. MAX8998_REG_BUCK1_VOLTAGE2,
  50. MAX8998_REG_BUCK1_VOLTAGE3,
  51. MAX8998_REG_BUCK1_VOLTAGE4,
  52. MAX8998_REG_BUCK2_VOLTAGE1,
  53. MAX8998_REG_BUCK2_VOLTAGE2,
  54. MAX8998_REG_BUCK3,
  55. MAX8998_REG_BUCK4,
  56. MAX8998_REG_LDO2_LDO3,
  57. MAX8998_REG_LDO4,
  58. MAX8998_REG_LDO5,
  59. MAX8998_REG_LDO6,
  60. MAX8998_REG_LDO7,
  61. MAX8998_REG_LDO8_LDO9,
  62. MAX8998_REG_LDO10_LDO11,
  63. MAX8998_REG_LDO12,
  64. MAX8998_REG_LDO13,
  65. MAX8998_REG_LDO14,
  66. MAX8998_REG_LDO15,
  67. MAX8998_REG_LDO16,
  68. MAX8998_REG_LDO17,
  69. MAX8998_REG_BKCHR,
  70. MAX8998_REG_LBCNFG1,
  71. MAX8998_REG_LBCNFG2,
  72. PMIC_NUM_OF_REGS,
  73. };
  74. #define MAX8998_LDO3 (1 << 2)
  75. #define MAX8998_LDO4 (1 << 1)
  76. #define MAX8998_LDO7 (1 << 6)
  77. #define MAX8998_LDO8 (1 << 5)
  78. #define MAX8998_LDO17 (1 << 4)
  79. #define MAX8998_SAFEOUT1 (1 << 4)
  80. #define MAX8998_I2C_ADDR (0xCC >> 1)
  81. enum { LDO_OFF, LDO_ON };
  82. #endif /* __MAX8998_PMIC_H_ */