	Drive Goodix TPIC without INT GPIO Output
========================================================

1.Background
------------

Goodix touch IC has a special mechanism that INT GPIO is used for I2C address
selection and GPIO synchronization during the hardware reset process.
The reason for designing this mechanism is to prevent i2c address conflict.
The main flow of this mechanism is as follows:

	reset pin output 0 -> INT pin output 1 if i2c address is 0x14, or output 0 if
	i2c address is 0x5D -> reset pin output 1 -> delay and wait until  hardware
	address selection circuit initialization completes. -> INT pin output 0 to inform the
	firmware that it can safely output INT pulse.

But in kernal3.13 or later versions, the GPIO subsystem has restricted the output
of GPIO which had been tied to IRQ line. Therefore, we add pinctrl method to set pins' states. 

2.How-to
---------

If your kernel has the restriction on the output of GPIO tied to IRQ line, 
   follow the steps below:

   - Add pinctrl-names, pinctrl-x to TP dts as described at GT1x-dts-bindings.txt
   - Add pingroup for Goodix touch as suggested below.
   See below for example:
   
   ```
   i2c@f9927000 { /*Goodix BLSP1 QUP5 */
	   goodix_ts@14 {
		   compatible = "goodix,gt1x";
		   reg = <0x14>;
		   goodix,reset-gpio = <&msmgpio 16 0x00>;
		   goodix,irq-gpio = <&msmgpio 17 0x00>;
		   pinctrl-names = "pmx_ts_wakeup","pmx_ts_normal","pmx_ts_poweroff","pmx_ts_sleep";
			 pinctrl-0 = <&ts_int_pullup &ts_reset_pullup>;
			 pinctrl-1 = <&ts_int_nopull &ts_reset_pullup>;
	     pinctrl-2 = <&ts_int_pulldown &ts_reset_pulldown>;
	     pinctrl-3 = <&ts_int_pulldown &ts_reset_pullup>;

	   };

	   //e.g. in msm8937-pinctrl.dtsi
	   /* add pingrp for touchscreen */
			pmx_ts_int_pullup {
				ts_int_pullup: ts_int_pullup {
					mux {
						pins = "gpio65";
						function = "gpio";
					};
	
					config {
						pins = "gpio65";
						drive-strength = <8>;
						bias-pull-up;
					};
				};
			};
	
			pmx_ts_int_nopull {
				ts_int_nopull: ts_int_nopull {
					mux {
						pins = "gpio65";
						function = "gpio";
					};
	
					config {
						pins = "gpio65";
						drive-strength = <2>;
						bias-disable;
					};
				};
			};
			
			pmx_ts_int_pulldown {
				ts_int_pulldown: ts_int_pulldown {
					mux {
						pins = "gpio65";
						function = "gpio";
					};
	
					config {
						pins = "gpio65";
						drive-strength = <2>;
						bias-pull-down;
					};
				};
			};
	
			pmx_ts_reset_pullup {
				ts_reset_pullup: ts_reset_pullup {
					mux {
						pins = "gpio64";
						function = "gpio";
					};
	
					config {
						pins = "gpio64";
						drive-strength = <8>;
						bias-pull-up;
					};
				};
			};
	
			pmx_ts_reset_pulldown {
				ts_reset_pulldown: ts_reset_pulldown {
					mux {
						pins = "gpio64";
						function = "gpio";
					};
	
					config {
						pins = "gpio64";
						drive-strength = <2>;
						bias-pull-down;
					};
				};
			};
			
	 ```







