Loading Documentation/devicetree/bindings/input/touchscreen/maxim-sti.txt 0 → 100644 +47 −0 Original line number Original line Diff line number Diff line Maxim STI touch controller: Required properties: - spi-max-frequency: Maximum SPI frequency supported by the controller. - avdd-supply: analog power supply. - dvdd-supply: digial power supply. - maxim_sti,irq-gpio: irq gpio. - maxim_sti,reset-gpio: reset gpio. - maxim_sti,touch_fusion: path to touch_fusion daemon. - maxim_sti,config_file: path to config file. - maxim_sti,fw_name: name of firmware file. Optional properties: - pinctrl-names : this should be defined if a target uses pinctrl framework. See "pinctrl" in documentation/devicetree/bindings/pinctrl/msm-pinctrl.txt. It should specify the names of the configs that pinctrl can install in driver. Following are the pinctrl configs that can be installed: "pmx_ts_active" : active configuration of pins. This should specify active config defined in pin groups of interrupt and reset gpios. "pmx_ts_suspend" : disabled configuration of pins. This should specify sleep config defined in pin groups of interrupt and reset gpios. Example: &spi_13 { /* BLSP1 QUP3 */ status = "ok"; maxim_sti@0 { compatible = "maxim,maxim_sti"; reg = <0>; interrupt-parent = <&msm_gpio>; interrupts = <65 0>; spi-max-frequency = <16000000>; avdd-supply = <&pm8950_l17>; dvdd-supply = <&pm8950_l6>; spi-supply = <&pm8950_l5>; maxim_sti,irq-gpio = <&msm_gpio 65 0x00>; maxim_sti,reset-gpio = <&msm_gpio 64 0x00>; maxim_sti,touch_fusion = "/vendor/bin/touch_fusion"; maxim_sti,config_file = "/vendor/firmware/touch_fusion_panel_id_0x%04x.cfg"; maxim_sti,fw_name = "maxim_fp35.bin"; pinctrl-names = "pmx_ts_active","pmx_ts_suspend","pmx_ts_release"; pinctrl-0 = <&ts_int_active &ts_reset_active>; pinctrl-1 = <&ts_int_suspend &ts_reset_suspend>; pinctrl-2 = <&ts_release>; }; }; drivers/input/touchscreen/Kconfig +12 −0 Original line number Original line Diff line number Diff line Loading @@ -1103,5 +1103,17 @@ config TOUCHSCREEN_GT9XX If unsure, say N. If unsure, say N. config TOUCHSCREEN_MAXIM_STI tristate "Maxim based STI touchscreens" depends on SPI_MASTER help Say Y here if you have a touchscreen interface using the Maxim STI based touch controller. If unsure, say N To compile this driver as a module, choose M here: the module will be called maxim_sti. source "drivers/input/touchscreen/gt9xx/Kconfig" source "drivers/input/touchscreen/gt9xx/Kconfig" endif endif drivers/input/touchscreen/Makefile +1 −0 Original line number Original line Diff line number Diff line Loading @@ -42,6 +42,7 @@ obj-$(CONFIG_TOUCHSCREEN_INEXIO) += inexio.o obj-$(CONFIG_TOUCHSCREEN_INTEL_MID) += intel-mid-touch.o obj-$(CONFIG_TOUCHSCREEN_INTEL_MID) += intel-mid-touch.o obj-$(CONFIG_TOUCHSCREEN_LPC32XX) += lpc32xx_ts.o obj-$(CONFIG_TOUCHSCREEN_LPC32XX) += lpc32xx_ts.o obj-$(CONFIG_TOUCHSCREEN_MAX11801) += max11801_ts.o obj-$(CONFIG_TOUCHSCREEN_MAX11801) += max11801_ts.o obj-$(CONFIG_TOUCHSCREEN_MAXIM_STI) += maxim_sti.o obj-$(CONFIG_TOUCHSCREEN_MC13783) += mc13783_ts.o obj-$(CONFIG_TOUCHSCREEN_MC13783) += mc13783_ts.o obj-$(CONFIG_TOUCHSCREEN_MCS5000) += mcs5000_ts.o obj-$(CONFIG_TOUCHSCREEN_MCS5000) += mcs5000_ts.o obj-$(CONFIG_TOUCHSCREEN_MIGOR) += migor_ts.o obj-$(CONFIG_TOUCHSCREEN_MIGOR) += migor_ts.o Loading drivers/input/touchscreen/maxim_sti.c +137 −358 File changed.Preview size limit exceeded, changes collapsed. Show changes include/linux/input/maxim_sti.h +6 −4 Original line number Original line Diff line number Diff line Loading @@ -4,6 +4,7 @@ * * * Copyright (c)2013 Maxim Integrated Products, Inc. * Copyright (c)2013 Maxim Integrated Products, Inc. * Copyright (C) 2013, NVIDIA Corporation. All Rights Reserved. * Copyright (C) 2013, NVIDIA Corporation. All Rights Reserved. * Copyright (c) 2015, The Linux Foundation. All rights reserved. * * * This software is licensed under the terms of the GNU General Public * This software is licensed under the terms of the GNU General Public * License version 2, as published by the Free Software Foundation, and * License version 2, as published by the Free Software Foundation, and Loading Loading @@ -44,7 +45,6 @@ * Netlink: common kernel/user space macros * * Netlink: common kernel/user space macros * \****************************************************************************/ \****************************************************************************/ //#define NL_BUF_SIZE 8192 #define NL_BUF_SIZE 30720 #define NL_BUF_SIZE 30720 #define NL_ATTR_FIRST(nptr) \ #define NL_ATTR_FIRST(nptr) \ Loading Loading @@ -118,11 +118,13 @@ nl_add_attr(void *buf, __u16 type, void *ptr, __u16 len) enum { enum { MC_DRIVER, MC_DRIVER, MC_FUSION, MC_FUSION, MC_REQUIRED_GROUPS, MC_EVENT_BROADCAST, MC_GROUPS, }; }; #define MC_DRIVER_NAME "driver" #define MC_DRIVER_NAME "driver" #define MC_FUSION_NAME "fusion" #define MC_FUSION_NAME "fusion" #define MC_EVENT_BROADCAST_NAME "event_broadcast" #define NL_FAMILY_VERSION 1 #define NL_FAMILY_VERSION 1 Loading Loading @@ -344,8 +346,8 @@ struct maxim_sti_pdata { u32 default_reset_state; u32 default_reset_state; u32 tx_buf_size; u32 tx_buf_size; u32 rx_buf_size; u32 rx_buf_size; u32 gpio_reset; int gpio_reset; u32 gpio_irq; int gpio_irq; int (*init)(struct maxim_sti_pdata *pdata, bool init); int (*init)(struct maxim_sti_pdata *pdata, bool init); void (*reset)(struct maxim_sti_pdata *pdata, int value); void (*reset)(struct maxim_sti_pdata *pdata, int value); int (*irq)(struct maxim_sti_pdata *pdata); int (*irq)(struct maxim_sti_pdata *pdata); Loading Loading
Documentation/devicetree/bindings/input/touchscreen/maxim-sti.txt 0 → 100644 +47 −0 Original line number Original line Diff line number Diff line Maxim STI touch controller: Required properties: - spi-max-frequency: Maximum SPI frequency supported by the controller. - avdd-supply: analog power supply. - dvdd-supply: digial power supply. - maxim_sti,irq-gpio: irq gpio. - maxim_sti,reset-gpio: reset gpio. - maxim_sti,touch_fusion: path to touch_fusion daemon. - maxim_sti,config_file: path to config file. - maxim_sti,fw_name: name of firmware file. Optional properties: - pinctrl-names : this should be defined if a target uses pinctrl framework. See "pinctrl" in documentation/devicetree/bindings/pinctrl/msm-pinctrl.txt. It should specify the names of the configs that pinctrl can install in driver. Following are the pinctrl configs that can be installed: "pmx_ts_active" : active configuration of pins. This should specify active config defined in pin groups of interrupt and reset gpios. "pmx_ts_suspend" : disabled configuration of pins. This should specify sleep config defined in pin groups of interrupt and reset gpios. Example: &spi_13 { /* BLSP1 QUP3 */ status = "ok"; maxim_sti@0 { compatible = "maxim,maxim_sti"; reg = <0>; interrupt-parent = <&msm_gpio>; interrupts = <65 0>; spi-max-frequency = <16000000>; avdd-supply = <&pm8950_l17>; dvdd-supply = <&pm8950_l6>; spi-supply = <&pm8950_l5>; maxim_sti,irq-gpio = <&msm_gpio 65 0x00>; maxim_sti,reset-gpio = <&msm_gpio 64 0x00>; maxim_sti,touch_fusion = "/vendor/bin/touch_fusion"; maxim_sti,config_file = "/vendor/firmware/touch_fusion_panel_id_0x%04x.cfg"; maxim_sti,fw_name = "maxim_fp35.bin"; pinctrl-names = "pmx_ts_active","pmx_ts_suspend","pmx_ts_release"; pinctrl-0 = <&ts_int_active &ts_reset_active>; pinctrl-1 = <&ts_int_suspend &ts_reset_suspend>; pinctrl-2 = <&ts_release>; }; };
drivers/input/touchscreen/Kconfig +12 −0 Original line number Original line Diff line number Diff line Loading @@ -1103,5 +1103,17 @@ config TOUCHSCREEN_GT9XX If unsure, say N. If unsure, say N. config TOUCHSCREEN_MAXIM_STI tristate "Maxim based STI touchscreens" depends on SPI_MASTER help Say Y here if you have a touchscreen interface using the Maxim STI based touch controller. If unsure, say N To compile this driver as a module, choose M here: the module will be called maxim_sti. source "drivers/input/touchscreen/gt9xx/Kconfig" source "drivers/input/touchscreen/gt9xx/Kconfig" endif endif
drivers/input/touchscreen/Makefile +1 −0 Original line number Original line Diff line number Diff line Loading @@ -42,6 +42,7 @@ obj-$(CONFIG_TOUCHSCREEN_INEXIO) += inexio.o obj-$(CONFIG_TOUCHSCREEN_INTEL_MID) += intel-mid-touch.o obj-$(CONFIG_TOUCHSCREEN_INTEL_MID) += intel-mid-touch.o obj-$(CONFIG_TOUCHSCREEN_LPC32XX) += lpc32xx_ts.o obj-$(CONFIG_TOUCHSCREEN_LPC32XX) += lpc32xx_ts.o obj-$(CONFIG_TOUCHSCREEN_MAX11801) += max11801_ts.o obj-$(CONFIG_TOUCHSCREEN_MAX11801) += max11801_ts.o obj-$(CONFIG_TOUCHSCREEN_MAXIM_STI) += maxim_sti.o obj-$(CONFIG_TOUCHSCREEN_MC13783) += mc13783_ts.o obj-$(CONFIG_TOUCHSCREEN_MC13783) += mc13783_ts.o obj-$(CONFIG_TOUCHSCREEN_MCS5000) += mcs5000_ts.o obj-$(CONFIG_TOUCHSCREEN_MCS5000) += mcs5000_ts.o obj-$(CONFIG_TOUCHSCREEN_MIGOR) += migor_ts.o obj-$(CONFIG_TOUCHSCREEN_MIGOR) += migor_ts.o Loading
drivers/input/touchscreen/maxim_sti.c +137 −358 File changed.Preview size limit exceeded, changes collapsed. Show changes
include/linux/input/maxim_sti.h +6 −4 Original line number Original line Diff line number Diff line Loading @@ -4,6 +4,7 @@ * * * Copyright (c)2013 Maxim Integrated Products, Inc. * Copyright (c)2013 Maxim Integrated Products, Inc. * Copyright (C) 2013, NVIDIA Corporation. All Rights Reserved. * Copyright (C) 2013, NVIDIA Corporation. All Rights Reserved. * Copyright (c) 2015, The Linux Foundation. All rights reserved. * * * This software is licensed under the terms of the GNU General Public * This software is licensed under the terms of the GNU General Public * License version 2, as published by the Free Software Foundation, and * License version 2, as published by the Free Software Foundation, and Loading Loading @@ -44,7 +45,6 @@ * Netlink: common kernel/user space macros * * Netlink: common kernel/user space macros * \****************************************************************************/ \****************************************************************************/ //#define NL_BUF_SIZE 8192 #define NL_BUF_SIZE 30720 #define NL_BUF_SIZE 30720 #define NL_ATTR_FIRST(nptr) \ #define NL_ATTR_FIRST(nptr) \ Loading Loading @@ -118,11 +118,13 @@ nl_add_attr(void *buf, __u16 type, void *ptr, __u16 len) enum { enum { MC_DRIVER, MC_DRIVER, MC_FUSION, MC_FUSION, MC_REQUIRED_GROUPS, MC_EVENT_BROADCAST, MC_GROUPS, }; }; #define MC_DRIVER_NAME "driver" #define MC_DRIVER_NAME "driver" #define MC_FUSION_NAME "fusion" #define MC_FUSION_NAME "fusion" #define MC_EVENT_BROADCAST_NAME "event_broadcast" #define NL_FAMILY_VERSION 1 #define NL_FAMILY_VERSION 1 Loading Loading @@ -344,8 +346,8 @@ struct maxim_sti_pdata { u32 default_reset_state; u32 default_reset_state; u32 tx_buf_size; u32 tx_buf_size; u32 rx_buf_size; u32 rx_buf_size; u32 gpio_reset; int gpio_reset; u32 gpio_irq; int gpio_irq; int (*init)(struct maxim_sti_pdata *pdata, bool init); int (*init)(struct maxim_sti_pdata *pdata, bool init); void (*reset)(struct maxim_sti_pdata *pdata, int value); void (*reset)(struct maxim_sti_pdata *pdata, int value); int (*irq)(struct maxim_sti_pdata *pdata); int (*irq)(struct maxim_sti_pdata *pdata); Loading