Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

Pull input fixes from Dmitry Torokhov:
"A fix (revert) for a recent regression in Synaptics driver and a fix
for Elan i2c touchpad driver"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
Revert "Input: synaptics - allocate 3 slots to keep stability in image sensors"
Input: elan_i2c - change the hover event from MT to ST

+6 -8
+5 -7
drivers/input/mouse/elan_i2c_core.c
··· 771 771 */ 772 772 static void elan_report_contact(struct elan_tp_data *data, 773 773 int contact_num, bool contact_valid, 774 - bool hover_event, u8 *finger_data) 774 + u8 *finger_data) 775 775 { 776 776 struct input_dev *input = data->input; 777 777 unsigned int pos_x, pos_y; ··· 815 815 input_mt_report_slot_state(input, MT_TOOL_FINGER, true); 816 816 input_report_abs(input, ABS_MT_POSITION_X, pos_x); 817 817 input_report_abs(input, ABS_MT_POSITION_Y, data->max_y - pos_y); 818 - input_report_abs(input, ABS_MT_DISTANCE, hover_event); 819 - input_report_abs(input, ABS_MT_PRESSURE, 820 - hover_event ? 0 : scaled_pressure); 818 + input_report_abs(input, ABS_MT_PRESSURE, scaled_pressure); 821 819 input_report_abs(input, ABS_TOOL_WIDTH, mk_x); 822 820 input_report_abs(input, ABS_MT_TOUCH_MAJOR, major); 823 821 input_report_abs(input, ABS_MT_TOUCH_MINOR, minor); ··· 837 839 hover_event = hover_info & 0x40; 838 840 for (i = 0; i < ETP_MAX_FINGERS; i++) { 839 841 contact_valid = tp_info & (1U << (3 + i)); 840 - elan_report_contact(data, i, contact_valid, hover_event, 841 - finger_data); 842 + elan_report_contact(data, i, contact_valid, finger_data); 842 843 843 844 if (contact_valid) 844 845 finger_data += ETP_FINGER_DATA_LEN; 845 846 } 846 847 847 848 input_report_key(input, BTN_LEFT, tp_info & 0x01); 849 + input_report_abs(input, ABS_DISTANCE, hover_event != 0); 848 850 input_mt_report_pointer_emulation(input, true); 849 851 input_sync(input); 850 852 } ··· 920 922 input_abs_set_res(input, ABS_Y, data->y_res); 921 923 input_set_abs_params(input, ABS_PRESSURE, 0, ETP_MAX_PRESSURE, 0, 0); 922 924 input_set_abs_params(input, ABS_TOOL_WIDTH, 0, ETP_FINGER_WIDTH, 0, 0); 925 + input_set_abs_params(input, ABS_DISTANCE, 0, 1, 0, 0); 923 926 924 927 /* And MT parameters */ 925 928 input_set_abs_params(input, ABS_MT_POSITION_X, 0, data->max_x, 0, 0); ··· 933 934 ETP_FINGER_WIDTH * max_width, 0, 0); 934 935 input_set_abs_params(input, ABS_MT_TOUCH_MINOR, 0, 935 936 ETP_FINGER_WIDTH * min_width, 0, 0); 936 - input_set_abs_params(input, ABS_MT_DISTANCE, 0, 1, 0, 0); 937 937 938 938 data->input = input; 939 939
+1 -1
drivers/input/mouse/synaptics.c
··· 1199 1199 ABS_MT_POSITION_Y); 1200 1200 /* Image sensors can report per-contact pressure */ 1201 1201 input_set_abs_params(dev, ABS_MT_PRESSURE, 0, 255, 0, 0); 1202 - input_mt_init_slots(dev, 3, INPUT_MT_POINTER | INPUT_MT_TRACK); 1202 + input_mt_init_slots(dev, 2, INPUT_MT_POINTER | INPUT_MT_TRACK); 1203 1203 1204 1204 /* Image sensors can signal 4 and 5 finger clicks */ 1205 1205 __set_bit(BTN_TOOL_QUADTAP, dev->keybit);