core.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /*
  2. * Copyright (C) 2015 Dialog Semiconductor Ltd.
  3. *
  4. * This program is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU General Public License
  6. * as published by the Free Software Foundation; either version 2
  7. * of the License, or (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. */
  14. #ifndef __MFD_DA9062_CORE_H__
  15. #define __MFD_DA9062_CORE_H__
  16. #include <linux/interrupt.h>
  17. #include <linux/mfd/da9062/registers.h>
  18. /* Interrupts */
  19. enum da9062_irqs {
  20. /* IRQ A */
  21. DA9062_IRQ_ONKEY,
  22. DA9062_IRQ_ALARM,
  23. DA9062_IRQ_TICK,
  24. DA9062_IRQ_WDG_WARN,
  25. DA9062_IRQ_SEQ_RDY,
  26. /* IRQ B*/
  27. DA9062_IRQ_TEMP,
  28. DA9062_IRQ_LDO_LIM,
  29. DA9062_IRQ_DVC_RDY,
  30. DA9062_IRQ_VDD_WARN,
  31. /* IRQ C */
  32. DA9062_IRQ_GPI0,
  33. DA9062_IRQ_GPI1,
  34. DA9062_IRQ_GPI2,
  35. DA9062_IRQ_GPI3,
  36. DA9062_IRQ_GPI4,
  37. DA9062_NUM_IRQ,
  38. };
  39. struct da9062 {
  40. struct device *dev;
  41. struct regmap *regmap;
  42. struct regmap_irq_chip_data *regmap_irq;
  43. };
  44. #endif /* __MFD_DA9062_CORE_H__ */