Browse Source

touch: trinket: enable touch driver

Enable synaptics_tcm touch driver for trinket target.

Change-Id: I7c6233b4f345c52a01ebebb92da2cb7d546ef24f
Signed-off-by: Surya Teja Kudiri <[email protected]>
Surya Teja Kudiri 1 year ago
parent
commit
c4e8550d3b
6 changed files with 36 additions and 0 deletions
  1. 13 0
      Android.mk
  2. 5 0
      Kbuild
  3. 5 0
      config/gki_trinkettouch.conf
  4. 9 0
      config/gki_trinkettouchconf.h
  5. 2 0
      touch_driver_board.mk
  6. 2 0
      touch_driver_product.mk

+ 13 - 0
Android.mk

@@ -250,6 +250,19 @@ else ifeq ($(TARGET_BOARD_PLATFORM), bengal)
        include $(DLKM_DIR)/Build_external_kernelmodule.mk
        ###########################################################
 
+else ifeq ($(TARGET_BOARD_PLATFORM), trinket)
+
+       ###########################################################
+       include $(CLEAR_VARS)
+       LOCAL_SRC_FILES   := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
+       LOCAL_MODULE              := synaptics_tcm_ts.ko
+       LOCAL_MODULE_KBUILD_NAME  := synaptics_tcm_ts.ko
+       LOCAL_MODULE_TAGS         := optional
+       #LOCAL_MODULE_DEBUG_ENABLE := true
+       LOCAL_MODULE_PATH         := $(KERNEL_MODULES_OUT)
+       include $(DLKM_DIR)/Build_external_kernelmodule.mk
+       ###########################################################
+
 else
 
        ###########################################################

+ 5 - 0
Kbuild

@@ -41,6 +41,11 @@ ifeq ($(CONFIG_ARCH_CROW), y)
         LINUX_INC += -include $(TOUCH_ROOT)/config/gki_crowtouchconf.h
 endif
 
+ifeq ($(CONFIG_ARCH_TRINKET), y)
+        include $(TOUCH_ROOT)/config/gki_trinkettouch.conf
+        LINUX_INC += -include $(TOUCH_ROOT)/config/gki_trinkettouchconf.h
+endif
+
 LINUX_INC +=	-Iinclude/linux \
 		-Iinclude/linux/drm \
 		-Iinclude/linux/gunyah \

+ 5 - 0
config/gki_trinkettouch.conf

@@ -0,0 +1,5 @@
+export CONFIG_MSM_TOUCH=m
+export CONFIG_TOUCHSCREEN_SYNAPTICS_TCM=y
+export CONFIG_TOUCHSCREEN_SYNAPTICS_TCM_I2C=y
+export CONFIG_TOUCHSCREEN_SYNAPTICS_TCM_CORE=y
+export CONFIG_TOUCHSCREEN_SYNAPTICS_TCM_TOUCH=y

+ 9 - 0
config/gki_trinkettouchconf.h

@@ -0,0 +1,9 @@
+/*
+* Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
+* SPDX-License-Identifier: GPL-2.0-only
+*/
+
+#define CONFIG_TOUCHSCREEN_SYNAPTICS_TCM 1
+#define CONFIG_TOUCHSCREEN_SYNAPTICS_TCM_I2C 1
+#define CONFIG_TOUCHSCREEN_SYNAPTICS_TCM_CORE 1
+#define CONFIG_TOUCHSCREEN_SYNAPTICS_TCM_TOUCH 1

+ 2 - 0
touch_driver_board.mk

@@ -33,6 +33,8 @@ ifeq ($(TOUCH_DLKM_ENABLE),  true)
                         else ifeq ($(TARGET_BOARD_PLATFORM), bengal)
                                 BOARD_VENDOR_KERNEL_MODULES += $(KERNEL_MODULES_OUT)/synaptics_tcm_ts.ko \
                                         $(KERNEL_MODULES_OUT)/nt36xxx-i2c.ko
+                        else ifeq ($(TARGET_BOARD_PLATFORM), trinket)
+                                BOARD_VENDOR_KERNEL_MODULES += $(KERNEL_MODULES_OUT)/synaptics_tcm_ts.ko
                         else
                                 BOARD_VENDOR_KERNEL_MODULES += $(KERNEL_MODULES_OUT)/nt36xxx-i2c.ko \
                                         $(KERNEL_MODULES_OUT)/goodix_ts.ko \

+ 2 - 0
touch_driver_product.mk

@@ -31,6 +31,8 @@ ifeq ($(TOUCH_DLKM_ENABLE),  true)
         else ifeq ($(TARGET_BOARD_PLATFORM), bengal)
                 PRODUCT_PACKAGES += $(KERNEL_MODULES_OUT)/synaptics_tcm_ts.ko \
                         $(KERNEL_MODULES_OUT)/nt36xxx-i2c.ko
+        else ifeq ($(TARGET_BOARD_PLATFORM), trinket)
+                PRODUCT_PACKAGES += $(KERNEL_MODULES_OUT)/synaptics_tcm_ts.ko
         else
                 PRODUCT_PACKAGES += $(KERNEL_MODULES_OUT)/nt36xxx-i2c.ko \
                         $(KERNEL_MODULES_OUT)/goodix_ts.ko \