Loading drivers/input/touchscreen/st/fts.c +3 −4 Original line number Diff line number Diff line Loading @@ -3229,13 +3229,13 @@ static int cx_crc_check(void) { unsigned char regAdd1[3] = {FTS_CMD_HW_REG_R, ADDR_CRC_BYTE0, ADDR_CRC_BYTE1}; unsigned char val[2]; unsigned char val[2] = {0}; unsigned char crc_status; int res; u8 cmd[4] = { FTS_CMD_HW_REG_W, 0x00, 0x00, SYSTEM_RESET_VALUE }; int event_to_search[2] = {(int)EVENTID_ERROR_EVENT, (int)EVENT_TYPE_CHECKSUM_ERROR}; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; /* read 2 bytes because the first one is a dummy byte! */ res = fts_readCmd(regAdd1, sizeof(regAdd1), val, 2); Loading @@ -3252,7 +3252,6 @@ static int cx_crc_check(void) return crc_status; } logError(0, "%s %s: Verifying if Config CRC Error...\n", tag, __func__); u16ToU8_be(SYSTEM_RESET_ADDRESS, &cmd[1]); res = fts_writeCmd(cmd, 4); Loading Loading @@ -3283,7 +3282,7 @@ static void fts_fw_update_auto(struct work_struct *work) u8 cmd[4] = { FTS_CMD_HW_REG_W, 0x00, 0x00, SYSTEM_RESET_VALUE }; int event_to_search[2] = {(int)EVENTID_ERROR_EVENT, (int)EVENT_TYPE_CHECKSUM_ERROR}; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int flag_init = 0; int retval = 0; int retval1 = 0; Loading drivers/input/touchscreen/st/fts_lib/ftsFlash.c +2 −2 Original line number Diff line number Diff line Loading @@ -235,7 +235,7 @@ int flashProcedure(const char *path, int force, int keep_cx) int flash_status(void) { u8 cmd[2] = {FLASH_CMD_READSTATUS, 0x00}; u8 readData; u8 readData = 0; logError(0, "%s %s:Reading ...\n", tag, __func__); if (fts_readCmd(cmd, 2, &readData, FLASH_STATUS_BYTES) < 0) { Loading Loading @@ -589,7 +589,7 @@ int flash_burn(Firmware fw, int force_burn, int keep_cx) int wait_for_flash_ready(u8 type) { u8 cmd[2] = {FLASH_CMD_READ_REGISTER, type}; u8 readData; u8 readData = 0; int i, res = -1; logError(0, "%s Waiting for flash ready ...\n", tag); Loading drivers/input/touchscreen/st/fts_lib/ftsGesture.c +6 −6 Original line number Diff line number Diff line Loading @@ -110,7 +110,7 @@ int updateGestureMask(u8 *mask, int size, int en) int enableGesture(u8 *mask, int size) { u8 cmd[GESTURE_MASK_SIZE + 2]; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int i, res; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, 0x00, GESTURE_ENABLE }; Loading Loading @@ -175,7 +175,7 @@ int enableGesture(u8 *mask, int size) int disableGesture(u8 *mask, int size) { u8 cmd[2 + GESTURE_MASK_SIZE]; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; u8 temp; int i, res; int event_to_search[4] = { EVENTID_GESTURE, Loading Loading @@ -246,7 +246,7 @@ int startAddCustomGesture(u8 gestureID) { u8 cmd[3] = { FTS_CMD_GESTURE_CMD, GESTURE_START_ADD, gestureID }; int res; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GESTURE_START_ADD }; Loading Loading @@ -279,7 +279,7 @@ int finishAddCustomGesture(u8 gestureID) u8 cmd[3] = { FTS_CMD_GESTURE_CMD, GESTURE_FINISH_ADD, gestureID }; int res; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GESTURE_FINISH_ADD }; Loading Loading @@ -316,7 +316,7 @@ int loadCustomGesture(u8 *template, u8 gestureID) u8 cmd[TEMPLATE_CHUNK + 5]; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GESTURE_DATA_ADD }; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; logError(0, "%s Starting adding custom gesture procedure...\n", tag); Loading Loading @@ -512,7 +512,7 @@ int removeCustomGesture(u8 gestureID) u8 cmd[3] = { FTS_CMD_GESTURE_CMD, GETURE_REMOVE_CUSTOM, gestureID }; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GETURE_REMOVE_CUSTOM }; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; index = gestureID - GESTURE_CUSTOM_OFFSET; Loading drivers/input/touchscreen/st/fts_lib/ftsTest.c +6 −6 Original line number Diff line number Diff line Loading @@ -364,7 +364,7 @@ int production_test_ito(void) { int res = OK; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; //look for ito event int eventToSearch[2] = {EVENTID_ERROR_EVENT, EVENT_TYPE_ITO}; Loading Loading @@ -417,7 +417,7 @@ int production_test_initialization(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_FULL_INITIALIZATION}; Loading Loading @@ -475,7 +475,7 @@ int ms_compensation_tuning(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_MS_TUNING_CMPL}; Loading Loading @@ -515,7 +515,7 @@ int ss_compensation_tuning(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_SS_TUNING_CMPL}; Loading Loading @@ -556,7 +556,7 @@ int lp_timer_calibration(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_LPTIMER_TUNING_CMPL}; Loading Loading @@ -599,7 +599,7 @@ int save_cx_tuning(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_COMP_DATA_SAVED}; Loading Loading
drivers/input/touchscreen/st/fts.c +3 −4 Original line number Diff line number Diff line Loading @@ -3229,13 +3229,13 @@ static int cx_crc_check(void) { unsigned char regAdd1[3] = {FTS_CMD_HW_REG_R, ADDR_CRC_BYTE0, ADDR_CRC_BYTE1}; unsigned char val[2]; unsigned char val[2] = {0}; unsigned char crc_status; int res; u8 cmd[4] = { FTS_CMD_HW_REG_W, 0x00, 0x00, SYSTEM_RESET_VALUE }; int event_to_search[2] = {(int)EVENTID_ERROR_EVENT, (int)EVENT_TYPE_CHECKSUM_ERROR}; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; /* read 2 bytes because the first one is a dummy byte! */ res = fts_readCmd(regAdd1, sizeof(regAdd1), val, 2); Loading @@ -3252,7 +3252,6 @@ static int cx_crc_check(void) return crc_status; } logError(0, "%s %s: Verifying if Config CRC Error...\n", tag, __func__); u16ToU8_be(SYSTEM_RESET_ADDRESS, &cmd[1]); res = fts_writeCmd(cmd, 4); Loading Loading @@ -3283,7 +3282,7 @@ static void fts_fw_update_auto(struct work_struct *work) u8 cmd[4] = { FTS_CMD_HW_REG_W, 0x00, 0x00, SYSTEM_RESET_VALUE }; int event_to_search[2] = {(int)EVENTID_ERROR_EVENT, (int)EVENT_TYPE_CHECKSUM_ERROR}; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int flag_init = 0; int retval = 0; int retval1 = 0; Loading
drivers/input/touchscreen/st/fts_lib/ftsFlash.c +2 −2 Original line number Diff line number Diff line Loading @@ -235,7 +235,7 @@ int flashProcedure(const char *path, int force, int keep_cx) int flash_status(void) { u8 cmd[2] = {FLASH_CMD_READSTATUS, 0x00}; u8 readData; u8 readData = 0; logError(0, "%s %s:Reading ...\n", tag, __func__); if (fts_readCmd(cmd, 2, &readData, FLASH_STATUS_BYTES) < 0) { Loading Loading @@ -589,7 +589,7 @@ int flash_burn(Firmware fw, int force_burn, int keep_cx) int wait_for_flash_ready(u8 type) { u8 cmd[2] = {FLASH_CMD_READ_REGISTER, type}; u8 readData; u8 readData = 0; int i, res = -1; logError(0, "%s Waiting for flash ready ...\n", tag); Loading
drivers/input/touchscreen/st/fts_lib/ftsGesture.c +6 −6 Original line number Diff line number Diff line Loading @@ -110,7 +110,7 @@ int updateGestureMask(u8 *mask, int size, int en) int enableGesture(u8 *mask, int size) { u8 cmd[GESTURE_MASK_SIZE + 2]; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int i, res; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, 0x00, GESTURE_ENABLE }; Loading Loading @@ -175,7 +175,7 @@ int enableGesture(u8 *mask, int size) int disableGesture(u8 *mask, int size) { u8 cmd[2 + GESTURE_MASK_SIZE]; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; u8 temp; int i, res; int event_to_search[4] = { EVENTID_GESTURE, Loading Loading @@ -246,7 +246,7 @@ int startAddCustomGesture(u8 gestureID) { u8 cmd[3] = { FTS_CMD_GESTURE_CMD, GESTURE_START_ADD, gestureID }; int res; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GESTURE_START_ADD }; Loading Loading @@ -279,7 +279,7 @@ int finishAddCustomGesture(u8 gestureID) u8 cmd[3] = { FTS_CMD_GESTURE_CMD, GESTURE_FINISH_ADD, gestureID }; int res; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GESTURE_FINISH_ADD }; Loading Loading @@ -316,7 +316,7 @@ int loadCustomGesture(u8 *template, u8 gestureID) u8 cmd[TEMPLATE_CHUNK + 5]; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GESTURE_DATA_ADD }; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; logError(0, "%s Starting adding custom gesture procedure...\n", tag); Loading Loading @@ -512,7 +512,7 @@ int removeCustomGesture(u8 gestureID) u8 cmd[3] = { FTS_CMD_GESTURE_CMD, GETURE_REMOVE_CUSTOM, gestureID }; int event_to_search[4] = { EVENTID_GESTURE, EVENT_TYPE_ENB, gestureID, GETURE_REMOVE_CUSTOM }; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; index = gestureID - GESTURE_CUSTOM_OFFSET; Loading
drivers/input/touchscreen/st/fts_lib/ftsTest.c +6 −6 Original line number Diff line number Diff line Loading @@ -364,7 +364,7 @@ int production_test_ito(void) { int res = OK; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; //look for ito event int eventToSearch[2] = {EVENTID_ERROR_EVENT, EVENT_TYPE_ITO}; Loading Loading @@ -417,7 +417,7 @@ int production_test_initialization(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_FULL_INITIALIZATION}; Loading Loading @@ -475,7 +475,7 @@ int ms_compensation_tuning(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_MS_TUNING_CMPL}; Loading Loading @@ -515,7 +515,7 @@ int ss_compensation_tuning(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_SS_TUNING_CMPL}; Loading Loading @@ -556,7 +556,7 @@ int lp_timer_calibration(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_LPTIMER_TUNING_CMPL}; Loading Loading @@ -599,7 +599,7 @@ int save_cx_tuning(void) { int res; u8 cmd; u8 readData[FIFO_EVENT_SIZE]; u8 readData[FIFO_EVENT_SIZE] = {0}; int eventToSearch[2] = {EVENTID_STATUS_UPDATE, EVENT_TYPE_COMP_DATA_SAVED}; Loading