tca6416_keypad.h 847 B

12345678910111213141516171819202122232425262728293031323334
  1. /*
  2. * tca6416 keypad platform support
  3. *
  4. * Copyright (C) 2010 Texas Instruments
  5. *
  6. * Author: Sriramakrishnan <srk@ti.com>
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License version 2 as
  10. * published by the Free Software Foundation.
  11. */
  12. #ifndef _TCA6416_KEYS_H
  13. #define _TCA6416_KEYS_H
  14. #include <linux/types.h>
  15. struct tca6416_button {
  16. /* Configuration parameters */
  17. int code; /* input event code (KEY_*, SW_*) */
  18. int active_low;
  19. int type; /* input event type (EV_KEY, EV_SW) */
  20. };
  21. struct tca6416_keys_platform_data {
  22. struct tca6416_button *buttons;
  23. int nbuttons;
  24. unsigned int rep:1; /* enable input subsystem auto repeat */
  25. uint16_t pinmask;
  26. uint16_t invert;
  27. int irq_is_gpio;
  28. int use_polling; /* use polling if Interrupt is not connected*/
  29. };
  30. #endif