input: touchscreen: gt9xx: add firmware for rk3399 9.7' sample mid
authorAiyoujun <ayj@rock-chips.com>
Mon, 13 Jun 2016 14:53:24 +0000 (22:53 +0800)
committerAiyoujun <ayj@rock-chips.com>
Mon, 13 Jun 2016 14:53:24 +0000 (22:53 +0800)
Change-Id: Ie7c5d9ab7da284c96fe3f56fd2108445012bf25a
Signed-off-by: Aiyoujun <ayj@rock-chips.com>
drivers/input/touchscreen/gt9xx/GT9110P_Config_20160217_1526_2048_97.cfg [new file with mode: 0644]
drivers/input/touchscreen/gt9xx/gt9xx.c [changed mode: 0755->0644]
drivers/input/touchscreen/gt9xx/gt9xx.h [changed mode: 0755->0644]

diff --git a/drivers/input/touchscreen/gt9xx/GT9110P_Config_20160217_1526_2048_97.cfg b/drivers/input/touchscreen/gt9xx/GT9110P_Config_20160217_1526_2048_97.cfg
new file mode 100644 (file)
index 0000000..952ea84
--- /dev/null
@@ -0,0 +1 @@
+0x00,0x00,0x06,0x00,0x08,0x0A,0x35,0x00,0x01,0xC8,0x28,0x08,0x5A,0x3C,0x03,0x05,0x00,0x00,0xFF,0x7F,0x00,0x00,0x04,0x18,0x1A,0x1E,0x14,0x8F,0x2F,0xAA,0x2A,0x2C,0x1E,0x14,0x00,0x00,0x00,0x21,0x33,0x2D,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x29,0x19,0x32,0x94,0xC5,0x02,0x08,0x00,0x00,0x04,0x99,0x1A,0x00,0x90,0x1E,0x00,0x87,0x23,0x00,0x81,0x28,0x00,0x7D,0x2E,0x00,0x7D,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x66,0x0F,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x19,0x46,0x32,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x13,0x12,0x11,0x10,0x0F,0x0E,0x0D,0x0C,0x0B,0x0A,0x09,0x08,0x07,0x06,0x05,0x04,0x03,0x02,0x01,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x26,0x25,0x24,0x23,0x22,0x21,0x20,0x1F,0x1E,0x1D,0x19,0x18,0x17,0x16,0x15,0x12,0x11,0x10,0x0F,0x0E,0x09,0x08,0x07,0x00,0x01,0x02,0x03,0x04,0x05,0x06,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x10,0x01
\ No newline at end of file
old mode 100755 (executable)
new mode 100644 (file)
index 47b43f6..b4a538f
@@ -415,7 +415,7 @@ static void gtp_touch_down(struct goodix_ts_data* ts,s32 id,s32 x,s32 y,s32 w)
         GTP_SWAP(x, y);
     }
 
-       if (!bgt911) {
+       if (!bgt911 && !bgt970) {
            if(mGtp_X_Reverse){
                x = ts->abs_x_max - x;
            }
@@ -1430,6 +1430,11 @@ static s32 gtp_init_panel(struct goodix_ts_data *ts)
                cfg_info_len[0] =  CFG_GROUP_LEN(gtp_dat_gt11);
     }
 
+       if (bgt970) {
+               send_cfg_buf[0] = gtp_dat_9_7;
+               cfg_info_len[0] = CFG_GROUP_LEN(gtp_dat_9_7);
+       }
+
     GTP_DEBUG_FUNC();
     GTP_DEBUG("Config Groups\' Lengths: %d, %d, %d, %d, %d, %d", 
         cfg_info_len[0], cfg_info_len[1], cfg_info_len[2], cfg_info_len[3],
@@ -2605,7 +2610,14 @@ static int goodix_ts_probe(struct i2c_client *client, const struct i2c_device_id
        mGtpChange_X2Y = TRUE;
         mGtp_X_Reverse = FALSE;
         mGtp_Y_Reverse = TRUE;
-    }
+       } else if (val == 970) {
+               m89or101 = FALSE;
+               bgt911 = FALSE;
+               bgt970 = TRUE;
+               mGtpChange_X2Y = FALSE;
+               mGtp_X_Reverse = FALSE;
+               mGtp_Y_Reverse = TRUE;
+       }
 
        ts->tp_regulator = devm_regulator_get(&client->dev, "tp");
        if (IS_ERR(ts->tp_regulator)) {
old mode 100755 (executable)
new mode 100644 (file)
index dc5c594..d146354
@@ -398,6 +398,7 @@ u8 gtp_dat_gt11[] = {
 
 bool m89or101 = TRUE;
 bool bgt911 = FALSE;
+bool bgt970 = FALSE;
 bool mGtpChange_X2Y = TRUE;  //GTP_CHANGE_X2Y        1
 bool mGtp_X_Reverse = FALSE;  //GTP_X_REVERSE_ENABLE
 bool mGtp_Y_Reverse = TRUE;  //GTP_Y_REVERSE_ENABLE
@@ -420,6 +421,10 @@ u8 gtp_dat_8_9[] =
 #include "WGJ10162B_GT9271_1060_Config_20140821_1341110X42.cfg"
 };
 
+u8 gtp_dat_9_7[] = {
+       /* <1536, 2048> 9.7 */
+       #include "GT9110P_Config_20160217_1526_2048_97.cfg"
+};
 
 u8 gtp_dat_10_1[] = 
 {