Loading drivers/input/touchscreen/hxchipset/himax_common.c +1 −1 Original line number Diff line number Diff line Loading @@ -2240,7 +2240,7 @@ void himax_chip_common_deinit(void) kfree(hx_touch_data); kfree(ic_data); kfree(ts->pdata); kfree(ts->report_i2c_data); kfree(ts->i2c_data); kfree(ts); probe_fail_flag = 0; } Loading drivers/input/touchscreen/hxchipset/himax_common.h +1 −1 Original line number Diff line number Diff line Loading @@ -365,7 +365,7 @@ struct himax_ts_data { struct work_struct ito_test_work; #endif uint8_t *report_i2c_data; uint8_t *i2c_data; /* for I2C DMA transfer */ }; struct himax_debug { Loading drivers/input/touchscreen/hxchipset/himax_platform.c +15 −12 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ #include "himax_platform.h" #include "himax_common.h" #include "himax_ic_core.h" int i2c_error_count; int irq_enable_count; Loading Loading @@ -172,7 +173,7 @@ int himax_bus_read(uint8_t command, uint8_t *data, uint32_t length, uint8_t toRe int retry; bool reallocate = false; struct himax_ts_data *ts = private_ts; uint8_t *buf = ts->report_i2c_data; uint8_t *buf = ts->i2c_data; struct i2c_client *client = ts->client; struct i2c_msg msg[] = { { Loading @@ -189,7 +190,7 @@ int himax_bus_read(uint8_t command, uint8_t *data, uint32_t length, uint8_t toRe } }; if (length > HX_REPORT_SZ) { if (length > FLASH_RW_MAX_LEN) { W("%s: data length too large %d!\n", __func__, length); buf = kmalloc(length + HX_CMD_BYTE, GFP_KERNEL); if (!buf) { Loading Loading @@ -233,7 +234,7 @@ int himax_bus_write(uint8_t command, uint8_t *data, uint32_t length, uint8_t toR int retry; bool reallocate = false; struct himax_ts_data *ts = private_ts; uint8_t *buf = ts->report_i2c_data; uint8_t *buf = ts->i2c_data; struct i2c_client *client = ts->client; struct i2c_msg msg[] = { { Loading @@ -244,7 +245,7 @@ int himax_bus_write(uint8_t command, uint8_t *data, uint32_t length, uint8_t toR } }; if (length > HX_REPORT_SZ) { if (length > FLASH_RW_MAX_LEN) { W("%s: data length too large %d!\n", __func__, length); buf = kmalloc(length + HX_CMD_BYTE, GFP_KERNEL); if (!buf) { Loading @@ -253,6 +254,7 @@ int himax_bus_write(uint8_t command, uint8_t *data, uint32_t length, uint8_t toR return -EIO; } reallocate = true; msg[0].buf = buf; } mutex_lock(&ts->rw_lock); Loading Loading @@ -291,7 +293,7 @@ int himax_bus_master_write(uint8_t *data, uint32_t length, uint8_t toRetry) int retry; bool reallocate = false; struct himax_ts_data *ts = private_ts; uint8_t *buf = ts->report_i2c_data; uint8_t *buf = ts->i2c_data; struct i2c_client *client = private_ts->client; struct i2c_msg msg[] = { { Loading @@ -302,7 +304,7 @@ int himax_bus_master_write(uint8_t *data, uint32_t length, uint8_t toRetry) } }; if (length > HX_REPORT_SZ) { if (length > FLASH_RW_MAX_LEN) { W("%s: data length too large %d!\n", __func__, length); buf = kmalloc(length, GFP_KERNEL); if (!buf) { Loading @@ -310,6 +312,7 @@ int himax_bus_master_write(uint8_t *data, uint32_t length, uint8_t toRetry) return -EIO; } reallocate = true; msg[0].buf = buf; } mutex_lock(&ts->rw_lock); Loading Loading @@ -801,11 +804,11 @@ int himax_chip_common_probe(struct i2c_client *client, const struct i2c_device_i mutex_init(&ts->rw_lock); private_ts = ts; ts->report_i2c_data = kmalloc(HX_REPORT_SZ + HX_CMD_BYTE, GFP_KERNEL); if (ts->report_i2c_data == NULL) { E("%s: allocate report_i2c_data failed\n", __func__); ts->i2c_data = kmalloc(FLASH_RW_MAX_LEN + HX_CMD_BYTE, GFP_KERNEL); if (ts->i2c_data == NULL) { E("%s: allocate i2c_data failed\n", __func__); ret = -ENOMEM; goto err_report_i2c_data; goto err_alloc_i2c_data; } /* Loading @@ -822,8 +825,8 @@ int himax_chip_common_probe(struct i2c_client *client, const struct i2c_device_i return ret; err_fb_notify_reg_failed: kfree(ts->report_i2c_data); err_report_i2c_data: kfree(ts->i2c_data); err_alloc_i2c_data: kfree(ts); err_alloc_data_failed: err_check_functionality_failed: Loading Loading
drivers/input/touchscreen/hxchipset/himax_common.c +1 −1 Original line number Diff line number Diff line Loading @@ -2240,7 +2240,7 @@ void himax_chip_common_deinit(void) kfree(hx_touch_data); kfree(ic_data); kfree(ts->pdata); kfree(ts->report_i2c_data); kfree(ts->i2c_data); kfree(ts); probe_fail_flag = 0; } Loading
drivers/input/touchscreen/hxchipset/himax_common.h +1 −1 Original line number Diff line number Diff line Loading @@ -365,7 +365,7 @@ struct himax_ts_data { struct work_struct ito_test_work; #endif uint8_t *report_i2c_data; uint8_t *i2c_data; /* for I2C DMA transfer */ }; struct himax_debug { Loading
drivers/input/touchscreen/hxchipset/himax_platform.c +15 −12 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ #include "himax_platform.h" #include "himax_common.h" #include "himax_ic_core.h" int i2c_error_count; int irq_enable_count; Loading Loading @@ -172,7 +173,7 @@ int himax_bus_read(uint8_t command, uint8_t *data, uint32_t length, uint8_t toRe int retry; bool reallocate = false; struct himax_ts_data *ts = private_ts; uint8_t *buf = ts->report_i2c_data; uint8_t *buf = ts->i2c_data; struct i2c_client *client = ts->client; struct i2c_msg msg[] = { { Loading @@ -189,7 +190,7 @@ int himax_bus_read(uint8_t command, uint8_t *data, uint32_t length, uint8_t toRe } }; if (length > HX_REPORT_SZ) { if (length > FLASH_RW_MAX_LEN) { W("%s: data length too large %d!\n", __func__, length); buf = kmalloc(length + HX_CMD_BYTE, GFP_KERNEL); if (!buf) { Loading Loading @@ -233,7 +234,7 @@ int himax_bus_write(uint8_t command, uint8_t *data, uint32_t length, uint8_t toR int retry; bool reallocate = false; struct himax_ts_data *ts = private_ts; uint8_t *buf = ts->report_i2c_data; uint8_t *buf = ts->i2c_data; struct i2c_client *client = ts->client; struct i2c_msg msg[] = { { Loading @@ -244,7 +245,7 @@ int himax_bus_write(uint8_t command, uint8_t *data, uint32_t length, uint8_t toR } }; if (length > HX_REPORT_SZ) { if (length > FLASH_RW_MAX_LEN) { W("%s: data length too large %d!\n", __func__, length); buf = kmalloc(length + HX_CMD_BYTE, GFP_KERNEL); if (!buf) { Loading @@ -253,6 +254,7 @@ int himax_bus_write(uint8_t command, uint8_t *data, uint32_t length, uint8_t toR return -EIO; } reallocate = true; msg[0].buf = buf; } mutex_lock(&ts->rw_lock); Loading Loading @@ -291,7 +293,7 @@ int himax_bus_master_write(uint8_t *data, uint32_t length, uint8_t toRetry) int retry; bool reallocate = false; struct himax_ts_data *ts = private_ts; uint8_t *buf = ts->report_i2c_data; uint8_t *buf = ts->i2c_data; struct i2c_client *client = private_ts->client; struct i2c_msg msg[] = { { Loading @@ -302,7 +304,7 @@ int himax_bus_master_write(uint8_t *data, uint32_t length, uint8_t toRetry) } }; if (length > HX_REPORT_SZ) { if (length > FLASH_RW_MAX_LEN) { W("%s: data length too large %d!\n", __func__, length); buf = kmalloc(length, GFP_KERNEL); if (!buf) { Loading @@ -310,6 +312,7 @@ int himax_bus_master_write(uint8_t *data, uint32_t length, uint8_t toRetry) return -EIO; } reallocate = true; msg[0].buf = buf; } mutex_lock(&ts->rw_lock); Loading Loading @@ -801,11 +804,11 @@ int himax_chip_common_probe(struct i2c_client *client, const struct i2c_device_i mutex_init(&ts->rw_lock); private_ts = ts; ts->report_i2c_data = kmalloc(HX_REPORT_SZ + HX_CMD_BYTE, GFP_KERNEL); if (ts->report_i2c_data == NULL) { E("%s: allocate report_i2c_data failed\n", __func__); ts->i2c_data = kmalloc(FLASH_RW_MAX_LEN + HX_CMD_BYTE, GFP_KERNEL); if (ts->i2c_data == NULL) { E("%s: allocate i2c_data failed\n", __func__); ret = -ENOMEM; goto err_report_i2c_data; goto err_alloc_i2c_data; } /* Loading @@ -822,8 +825,8 @@ int himax_chip_common_probe(struct i2c_client *client, const struct i2c_device_i return ret; err_fb_notify_reg_failed: kfree(ts->report_i2c_data); err_report_i2c_data: kfree(ts->i2c_data); err_alloc_i2c_data: kfree(ts); err_alloc_data_failed: err_check_functionality_failed: Loading