fts.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. #ifndef _LINUX_FTS_I2C_H_
  2. #define _LINUX_FTS_I2C_H_
  3. #define FTS_SUPPORT_NOISE_PARAM
  4. #if defined(CONFIG_SEC_LOCALE_KOR_FRESCO)
  5. #define FTS_SUPPORT_TA_MODE
  6. #endif
  7. #if defined(CONFIG_SEC_T10_PROJECT)
  8. #define FTS_SUPPORT_TOUCH_KEY
  9. #endif
  10. #ifdef FTS_SUPPORT_NOISE_PARAM
  11. #define MAX_NOISE_PARAM 5
  12. struct fts_noise_param {
  13. unsigned short pAddr[MAX_NOISE_PARAM];
  14. unsigned short pData[MAX_NOISE_PARAM];
  15. };
  16. #endif
  17. #ifdef FTS_SUPPORT_TOUCH_KEY
  18. /* TSP Key Feature*/
  19. #define KEY_PRESS 1
  20. #define KEY_RELEASE 0
  21. #define TOUCH_KEY_NULL 0
  22. /* support 4 touch key */
  23. #define TOUCH_KEY_D_MENU 0x01
  24. #define TOUCH_KEY_RECENT 0x02
  25. #define TOUCH_KEY_BACK 0x04
  26. #define TOUCH_KEY_D_BACK 0x08
  27. struct fts_touchkey {
  28. unsigned int value;
  29. unsigned int keycode;
  30. char *name;
  31. };
  32. #endif
  33. #ifdef FTS_SUPPORT_TA_MODE
  34. struct fts_callbacks {
  35. void (*inform_charger) (struct fts_callbacks *, int);
  36. };
  37. #endif
  38. struct fts_i2c_platform_data {
  39. bool factory_flatform;
  40. bool recovery_mode;
  41. bool support_hover;
  42. bool support_mshover;
  43. int max_x;
  44. int max_y;
  45. int max_width;
  46. unsigned char panel_revision; /* to identify panel info */
  47. const char *firmware_name;
  48. const char *project_name;
  49. int (*power) (bool enable);
  50. void (*register_cb)(void *);
  51. #ifdef FTS_SUPPORT_TA_MODE
  52. struct fts_callbacks callbacks;
  53. bool charging_mode;
  54. #endif
  55. void (*enable_sync)(bool on);
  56. unsigned gpio;
  57. int irq_type;
  58. #ifdef FTS_SUPPORT_TOUCH_KEY
  59. unsigned int num_touchkey;
  60. struct fts_touchkey *touchkey;
  61. int (*led_power_on) (void);
  62. int (*led_power_off) (void);
  63. #endif
  64. };
  65. #define SEC_TSP_FACTORY_TEST
  66. #ifdef SEC_TSP_FACTORY_TEST
  67. extern struct class *sec_class;
  68. #endif
  69. #endif