Kbuild 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218
  1. KDIR := $(TOP)/kernel_platform/common
  2. ifeq ($(CONFIG_ARCH_WAIPIO), y)
  3. include $(TOUCH_ROOT)/config/gki_waipiotouch.conf
  4. LINUX_INC += -include $(TOUCH_ROOT)/config/gki_waipiotouchconf.h
  5. endif
  6. ifeq ($(CONFIG_ARCH_KALAMA), y)
  7. include $(TOUCH_ROOT)/config/gki_kalamatouch.conf
  8. LINUX_INC += -include $(TOUCH_ROOT)/config/gki_kalamatouchconf.h
  9. endif
  10. ifeq ($(CONFIG_ARCH_KHAJE), y)
  11. include $(TOUCH_ROOT)/config/gki_khajetouch.conf
  12. LINUX_INC += -include $(TOUCH_ROOT)/config/gki_khajetouchconf.h
  13. endif
  14. ifeq ($(CONFIG_ARCH_PINEAPPLE), y)
  15. include $(TOUCH_ROOT)/config/gki_pineappletouch.conf
  16. LINUX_INC += -include $(TOUCH_ROOT)/config/gki_pineappletouchconf.h
  17. endif
  18. ifeq ($(CONFIG_ARCH_MONACO), y)
  19. include $(TOUCH_ROOT)/config/gki_monacotouch.conf
  20. LINUX_INC += -include $(TOUCH_ROOT)/config/gki_monacotouchconf.h
  21. endif
  22. ifeq ($(CONFIG_ARCH_KONA), y)
  23. include $(TOUCH_ROOT)/config/gki_konatouch.conf
  24. LINUX_INC += -include $(TOUCH_ROOT)/config/gki_konatouchconf.h
  25. endif
  26. LINUX_INC += -Iinclude/linux \
  27. -Iinclude/linux/drm \
  28. -Iinclude/linux/gunyah \
  29. -Iinclude/linux/input
  30. CDEFINES += -DANI_LITTLE_BYTE_ENDIAN \
  31. -DANI_LITTLE_BIT_ENDIAN \
  32. -DDOT11F_LITTLE_ENDIAN_HOST \
  33. -DANI_COMPILER_TYPE_GCC \
  34. -DANI_OS_TYPE_ANDROID=6 \
  35. -DPTT_SOCK_SVC_ENABLE \
  36. -Wall\
  37. -Werror\
  38. -D__linux__
  39. KBUILD_CPPFLAGS += $(CDEFINES)
  40. ccflags-y += $(LINUX_INC)
  41. ifeq ($(call cc-option-yn, -Wmaybe-uninitialized),y)
  42. EXTRA_CFLAGS += -Wmaybe-uninitialized
  43. endif
  44. ifeq ($(call cc-option-yn, -Wheader-guard),y)
  45. EXTRA_CFLAGS += -Wheader-guard
  46. endif
  47. ######### CONFIG_MSM_TOUCH ########
  48. ifeq ($(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX), y)
  49. LINUX_INC += -include $(TOUCH_ROOT)/synaptics_dsx/synaptics_dsx.h
  50. LINUX_INC += -include $(TOUCH_ROOT)/synaptics_dsx/synaptics_dsx_core.h
  51. synaptics_dsx-y := \
  52. ./synaptics_dsx/synaptics_dsx_core.o \
  53. ./synaptics_dsx/synaptics_dsx_i2c.o
  54. obj-$(CONFIG_MSM_TOUCH) += synaptics_dsx.o
  55. endif
  56. ifeq ($(CONFIG_TOUCH_FOCALTECH), y)
  57. LINUX_INC += -include $(TOUCH_ROOT)/focaltech_touch/focaltech_common.h
  58. LINUX_INC += -include $(TOUCH_ROOT)/focaltech_touch/focaltech_config.h
  59. LINUX_INC += -include $(TOUCH_ROOT)/focaltech_touch/focaltech_core.h
  60. LINUX_INC += -include $(TOUCH_ROOT)/focaltech_touch/focaltech_flash.h
  61. focaltech_fts-y := \
  62. ./focaltech_touch/focaltech_core.o \
  63. ./focaltech_touch/focaltech_ex_fun.o \
  64. ./focaltech_touch/focaltech_ex_mode.o \
  65. ./focaltech_touch/focaltech_gesture.o \
  66. ./focaltech_touch/focaltech_esdcheck.o \
  67. ./focaltech_touch/focaltech_point_report_check.o \
  68. ./focaltech_touch/focaltech_i2c.o \
  69. ./focaltech_touch/focaltech_flash.o \
  70. ./focaltech_touch/focaltech_flash/focaltech_upgrade_ft3518.o
  71. obj-$(CONFIG_MSM_TOUCH) += focaltech_fts.o
  72. endif
  73. ifeq ($(CONFIG_TOUCHSCREEN_NT36XXX_I2C), y)
  74. LINUX_INC += -include $(TOUCH_ROOT)/nt36xxx/nt36xxx.h
  75. LINUX_INC += -include $(TOUCH_ROOT)/nt36xxx/nt36xxx_mem_map.h
  76. LINUX_INC += -include $(TOUCH_ROOT)/nt36xxx/nt36xxx_mp_ctrlram.h
  77. nt36xxx-i2c-y := \
  78. ./nt36xxx/nt36xxx.o \
  79. ./nt36xxx/nt36xxx_fw_update.o \
  80. ./nt36xxx/nt36xxx_ext_proc.o \
  81. ./nt36xxx/nt36xxx_mp_ctrlram.o
  82. obj-$(CONFIG_MSM_TOUCH) += nt36xxx-i2c.o
  83. endif
  84. ifeq ($(CONFIG_TOUCHSCREEN_GOODIX_BRL), y)
  85. LINUX_INC += -include $(TOUCH_ROOT)/goodix_berlin_driver/goodix_ts_core.h
  86. LINUX_INC += -include $(TOUCH_ROOT)/qts/qts_core.h
  87. LINUX_INC += -include $(TOUCH_ROOT)/qts/qts_core_common.h
  88. goodix_ts-y := \
  89. ./goodix_berlin_driver/goodix_ts_core.o \
  90. ./goodix_berlin_driver/goodix_brl_hw.o \
  91. ./goodix_berlin_driver/goodix_cfg_bin.o \
  92. ./goodix_berlin_driver/goodix_ts_utils.o \
  93. ./goodix_berlin_driver/goodix_brl_fwupdate.o \
  94. ./goodix_berlin_driver/goodix_ts_tools.o \
  95. ./goodix_berlin_driver/goodix_ts_gesture.o \
  96. ./goodix_berlin_driver/goodix_ts_inspect.o \
  97. ./goodix_berlin_driver/goodix_brl_spi.o \
  98. ./goodix_berlin_driver/goodix_brl_i2c.o \
  99. ./qts/qts_core.o
  100. obj-$(CONFIG_MSM_TOUCH) += goodix_ts.o
  101. endif
  102. ifeq ($(CONFIG_TOUCHSCREEN_ATMEL_MXT), y)
  103. atmel_mxt_ts-y := \
  104. ./atmel_mxt/atmel_mxt_ts.o
  105. obj-$(CONFIG_MSM_TOUCH) += atmel_mxt_ts.o
  106. endif
  107. ifeq ($(CONFIG_TOUCHSCREEN_DUMMY), y)
  108. dummy_ts-y := ./dummy_touch/dummy_touch.o
  109. obj-$(CONFIG_MSM_TOUCH) += dummy_ts.o
  110. endif
  111. ifeq ($(CONFIG_TOUCHSCREEN_SYNAPTICS_TCM), y)
  112. synaptics_tcm_ts-y := \
  113. ./synaptics_tcm/synaptics_tcm_core.o \
  114. ./synaptics_tcm/synaptics_tcm_i2c.o \
  115. ./synaptics_tcm/synaptics_tcm_touch.o
  116. obj-$(CONFIG_MSM_TOUCH) += synaptics_tcm_ts.o
  117. endif
  118. ifneq ($(CONFIG_ARCH_PINEAPPLE), y)
  119. ifeq ($(CONFIG_TOUCHSCREEN_PARADE), y)
  120. LINUX_INC += -include $(TOUCH_ROOT)/pt/pt_regs.h
  121. LINUX_INC += -include $(TOUCH_ROOT)/pt/pt_core.h
  122. LINUX_INC += -include $(TOUCH_ROOT)/pt/pt_platform.h
  123. pt_ts-y := \
  124. ./pt/pt_core.o \
  125. ./pt/pt_mt_common.o \
  126. ./pt/pt_platform.o \
  127. ./pt/pt_devtree.o \
  128. ./pt/pt_btn.o \
  129. ./pt/pt_mtb.o \
  130. ./pt/pt_proximity.o
  131. obj-$(CONFIG_MSM_TOUCH) += pt_ts.o
  132. endif
  133. ifeq ($(CONFIG_TOUCHSCREEN_PARADE_I2C), y)
  134. LINUX_INC += -include $(TOUCH_ROOT)/pt/pt_regs.h
  135. pt_i2c-y := \
  136. ./pt/pt_i2c.o
  137. obj-$(CONFIG_MSM_TOUCH) += pt_i2c.o
  138. endif
  139. ifeq ($(CONFIG_TOUCHSCREEN_PARADE_DEVICE_ACCESS), y)
  140. LINUX_INC += -include $(TOUCH_ROOT)/pt/pt_regs.h
  141. pt_device_access-y := \
  142. ./pt/pt_device_access.o
  143. obj-$(CONFIG_MSM_TOUCH) += pt_device_access.o
  144. endif
  145. ifeq ($(CONFIG_TOUCHSCREEN_RM_TS), y)
  146. LINUX_INC += -include $(TOUCH_ROOT)/raydium/Config.h
  147. LINUX_INC += -include $(TOUCH_ROOT)/raydium/drv_interface.h
  148. LINUX_INC += -include $(TOUCH_ROOT)/raydium/rad_fw_image_30.h
  149. LINUX_INC += -include $(TOUCH_ROOT)/raydium/raydium_driver.h
  150. LINUX_INC += -include $(TOUCH_ROOT)/raydium/raydium_selftest.h
  151. LINUX_INC += -include $(TOUCH_ROOT)/raydium/tpselftest_30.h
  152. LINUX_INC += -include $(TOUCH_ROOT)/raydium/chip_raydium/f303_ic_control.h
  153. LINUX_INC += -include $(TOUCH_ROOT)/raydium/chip_raydium/f303_ic_reg.h
  154. LINUX_INC += -include $(TOUCH_ROOT)/raydium/chip_raydium/f303_ic_test.h
  155. LINUX_INC += -include $(TOUCH_ROOT)/raydium/chip_raydium/ic_drv_global.h
  156. LINUX_INC += -include $(TOUCH_ROOT)/raydium/chip_raydium/ic_drv_interface.h
  157. raydium_ts-y := \
  158. ./raydium/drv_interface.o \
  159. ./raydium/raydium_driver.o \
  160. ./raydium/raydium_fw_update.o \
  161. ./raydium/raydium_selftest.o \
  162. ./raydium/raydium_sysfs.o \
  163. ./raydium/chip_raydium/f303_ic_control.o \
  164. ./raydium/chip_raydium/f303_ic_test.o \
  165. ./raydium/chip_raydium/ic_drv_global.o \
  166. ./raydium/chip_raydium/ic_drv_interface.o
  167. obj-$(CONFIG_MSM_TOUCH) += raydium_ts.o
  168. endif
  169. endif # pineapple
  170. CDEFINES += -DBUILD_TIMESTAMP=\"$(shell date -u +'%Y-%m-%dT%H:%M:%SZ')\"