mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-25 08:02:56 +00:00
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Pull input updates from Dmitry Torokhov: - the main change is a fix for my brain-dead patch to PS/2 button reporting for some protocols that made it in 4.17 - there is a new driver for Spreadtum vibrator that I intended to send during merge window but ended up not sending the 2nd pull request. Given that this is a brand new driver we should not see regressions here - a fixup to Elantech PS/2 driver to avoid decoding errors on Thinkpad P52 - addition of few more ACPI IDs for Silead and Elan drivers - RMI4 is switched to using IRQ domain code instead of rolling its own implementation * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: psmouse - fix button reporting for basic protocols Input: xpad - fix GPD Win 2 controller name Input: elan_i2c_smbus - fix more potential stack buffer overflows Input: elan_i2c - add ELAN0618 (Lenovo v330 15IKB) ACPI ID Input: elantech - fix V4 report decoding for module with middle key Input: elantech - enable middle button of touchpads on ThinkPad P52 Input: do not assign new tracking ID when changing tool type Input: make input_report_slot_state() return boolean Input: synaptics-rmi4 - fix axis-swap behavior Input: synaptics-rmi4 - fix the error return code in rmi_probe_interrupts() Input: synaptics-rmi4 - convert irq distribution to irq_domain Input: silead - add MSSL0002 ACPI HID Input: goldfish_events - fix checkpatch warnings Input: add Spreadtrum vibrator driver
This commit is contained in:
commit
c92067ae06
27 changed files with 366 additions and 124 deletions
|
@ -131,8 +131,10 @@ EXPORT_SYMBOL(input_mt_destroy_slots);
|
|||
* inactive, or if the tool type is changed, a new tracking id is
|
||||
* assigned to the slot. The tool type is only reported if the
|
||||
* corresponding absbit field is set.
|
||||
*
|
||||
* Returns true if contact is active.
|
||||
*/
|
||||
void input_mt_report_slot_state(struct input_dev *dev,
|
||||
bool input_mt_report_slot_state(struct input_dev *dev,
|
||||
unsigned int tool_type, bool active)
|
||||
{
|
||||
struct input_mt *mt = dev->mt;
|
||||
|
@ -140,22 +142,24 @@ void input_mt_report_slot_state(struct input_dev *dev,
|
|||
int id;
|
||||
|
||||
if (!mt)
|
||||
return;
|
||||
return false;
|
||||
|
||||
slot = &mt->slots[mt->slot];
|
||||
slot->frame = mt->frame;
|
||||
|
||||
if (!active) {
|
||||
input_event(dev, EV_ABS, ABS_MT_TRACKING_ID, -1);
|
||||
return;
|
||||
return false;
|
||||
}
|
||||
|
||||
id = input_mt_get_value(slot, ABS_MT_TRACKING_ID);
|
||||
if (id < 0 || input_mt_get_value(slot, ABS_MT_TOOL_TYPE) != tool_type)
|
||||
if (id < 0)
|
||||
id = input_mt_new_trkid(mt);
|
||||
|
||||
input_event(dev, EV_ABS, ABS_MT_TRACKING_ID, id);
|
||||
input_event(dev, EV_ABS, ABS_MT_TOOL_TYPE, tool_type);
|
||||
|
||||
return true;
|
||||
}
|
||||
EXPORT_SYMBOL(input_mt_report_slot_state);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue