Skip to content

Commit

Permalink
input: touchscreen: gt9xx: add cj080258 gt9271 config
Browse files Browse the repository at this point in the history
Signed-off-by: Ken Wang <ken@radxa.com>
  • Loading branch information
Ken-Vamrs committed Dec 4, 2023
1 parent b89aa99 commit 010291e
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
0x41,0xB0,0x04,0x80,0x07,0x05,0x35,0x30,0x01,0x08,0x19,0x05,0x50,0x32,0x03,0x05,0x00,0x00,0x00,0x00,0x33,0x33,0x00,0x1A,0x18,0x1E,0x14,0x90,0x30,0xAA,0x2A,0x28,0x12,0x0C,0x00,0x00,0x00,0x9B,0x03,0x2D,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x50,0x94,0xC5,0x02,0x08,0x00,0x00,0x04,0x86,0x21,0x00,0x71,0x28,0x00,0x5F,0x31,0x00,0x51,0x3B,0x00,0x45,0x48,0x00,0x45,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x19,0x18,0x17,0x16,0x15,0x14,0x11,0x10,0x0F,0x0E,0x0D,0x0C,0x09,0x08,0x07,0x06,0x05,0x04,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x2A,0x29,0x28,0x27,0x26,0x25,0x24,0x23,0x22,0x21,0x20,0x1F,0x1E,0x1C,0x1B,0x19,0x00,0x02,0x04,0x06,0x07,0x08,0x0A,0x0C,0x0D,0x0E,0x0F,0x10,0x11,0x12,0x13,0x14,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x01
12 changes: 12 additions & 0 deletions drivers/input/touchscreen/gt9xx/gt9xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ static u8 bgt911 = FALSE;
static u8 bgt9110 = FALSE;
static u8 bgt9111 = FALSE;
static u8 bgt9112 = FALSE;
static u8 bgt9271 = FALSE;
static u8 bgt970 = FALSE;
static u8 bgt910 = FALSE;
static u8 gtp_change_x2y = TRUE;
Expand Down Expand Up @@ -1467,6 +1468,11 @@ static s32 gtp_init_panel(struct goodix_ts_data *ts)
cfg_info_len[0] = CFG_GROUP_LEN(gtp_dat_gt9112);
}

if (bgt9271) {
send_cfg_buf[0] = gtp_dat_gt9271;
cfg_info_len[0] = CFG_GROUP_LEN(gtp_dat_gt9271);
}

if (bgt970) {
send_cfg_buf[0] = gtp_dat_9_7;
cfg_info_len[0] = CFG_GROUP_LEN(gtp_dat_9_7);
Expand Down Expand Up @@ -2690,6 +2696,12 @@ static int goodix_ts_probe(struct i2c_client *client, const struct i2c_device_id
gtp_change_x2y = FALSE;
gtp_x_reverse = FALSE;
gtp_y_reverse = FALSE;
} else if (val == 9271) {
m89or101 = FALSE;
bgt9271 = TRUE;
gtp_change_x2y = FALSE;
gtp_x_reverse = FALSE;
gtp_y_reverse = FALSE;
} else if (val == 970) {
m89or101 = FALSE;
bgt911 = FALSE;
Expand Down
5 changes: 5 additions & 0 deletions drivers/input/touchscreen/gt9xx/gt9xx_cfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ u8 gtp_dat_gt9112[] = {
#include "CJ080258_GT911_Config_20221117_085548.cfg"
};

u8 gtp_dat_gt9271[] = {
/* <1200, 1920> */
#include "CJ080258_GT9271_Config_20230608_112016.cfg"
};

u8 gtp_dat_8_9[] = {
/* TODO:Puts your update firmware data here! */
/* <1920, 1200> 8.9 */
Expand Down

0 comments on commit 010291e

Please sign in to comment.