Input: elants_i2c - drop zero-checking of ABS_MT_TOUCH_MAJOR resolution
Subsystems (2)
PATCH 1/1 Input: elants_i2c - drop zero-checking of ABS_MT_TOUCH_MAJOR resolution
Drop unnecessary zero-checking of ABS_MT_TOUCH_MAJOR resolution since there is no difference between setting resolution to 0 vs not setting it at all. This change makes code cleaner a tad.
Suggested-by Dmitry Torokhov <[email protected]>
Signed-off-by Dmitry Osipenko <[email protected]>
--- drivers/input/touchscreen/elants_i2c.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/input/touchscreen/elants_i2c.c +1 -2
@@ -1449,8 +1449,7 @@ static int elants_i2c_probe(struct i2c_client *client,input_abs_set_res (ts->input,ABS_MT_POSITION_X , ts->x_res);input_abs_set_res (ts->input,ABS_MT_POSITION_Y , ts->y_res); -if (ts->major_res >0 ) -input_abs_set_res (ts->input,ABS_MT_TOUCH_MAJOR , ts->major_res); +input_abs_set_res (ts->input,ABS_MT_TOUCH_MAJOR , ts->major_res); error =input_mt_init_slots (ts->input,MAX_CONTACT_NUM ,INPUT_MT_DIRECT |INPUT_MT_DROP_UNUSED );
Signature · 1 line
2.30.2
Quoted 6 lines · Dmitry Osipenko
Drop unnecessary zero-checking of
ABS_MT_TOUCH_MAJORresolution since there is no difference between setting resolution to 0 vs not setting it at all. This change makes code cleaner a tad.Suggested-by Dmitry Torokhov <[email protected]>Signed-off-by Dmitry Osipenko <[email protected]>
Applied, thank you.
Signature · 1 line
Dmitry