<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/drivers/input/input.c, branch v6.1.107</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v6.1.107</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v6.1.107'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2024-06-21T12:35:45Z</updated>
<entry>
<title>Input: try trimming too long modalias strings</title>
<updated>2024-06-21T12:35:45Z</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2024-04-29T21:50:41Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=6dfa1d80ea03fc586ac350e5e399102dfa708654'/>
<id>urn:sha1:6dfa1d80ea03fc586ac350e5e399102dfa708654</id>
<content type='text'>
commit 0774d19038c496f0c3602fb505c43e1b2d8eed85 upstream.

If an input device declares too many capability bits then modalias
string for such device may become too long and not fit into uevent
buffer, resulting in failure of sending said uevent. This, in turn,
may prevent userspace from recognizing existence of such devices.

This is typically not a concern for real hardware devices as they have
limited number of keys, but happen with synthetic devices such as
ones created by xen-kbdfront driver, which creates devices as being
capable of delivering all possible keys, since it doesn't know what
keys the backend may produce.

To deal with such devices input core will attempt to trim key data,
in the hope that the rest of modalias string will fit in the given
buffer. When trimming key data it will indicate that it is not
complete by placing "+," sign, resulting in conversions like this:

old: k71,72,73,74,78,7A,7B,7C,7D,8E,9E,A4,AD,E0,E1,E4,F8,174,
new: k71,72,73,74,78,7A,7B,7C,+,

This should allow existing udev rules continue to work with existing
devices, and will also allow writing more complex rules that would
recognize trimmed modalias and check input device characteristics by
other means (for example by parsing KEY= data in uevent or parsing
input device sysfs attributes).

Note that the driver core may try adding more uevent environment
variables once input core is done adding its own, so when forming
modalias we can not use the entire available buffer, so we reduce
it by somewhat an arbitrary amount (96 bytes).

Reported-by: Jason Andryuk &lt;jandryuk@gmail.com&gt;
Reviewed-by: Peter Hutterer &lt;peter.hutterer@who-t.net&gt;
Tested-by: Jason Andryuk &lt;jandryuk@gmail.com&gt;
Link: https://lore.kernel.org/r/ZjAWMQCJdrxZkvkB@google.com
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Jason Andryuk &lt;jason.andryuk@amd.com&gt;
</content>
</entry>
<entry>
<title>Input: fix open count when closing inhibited device</title>
<updated>2023-06-14T09:15:23Z</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2023-05-05T18:16:07Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=c8a46f39dd2719c1044a2569a905f018f7a86b93'/>
<id>urn:sha1:c8a46f39dd2719c1044a2569a905f018f7a86b93</id>
<content type='text'>
commit 978134c4b192ed04ecf699be3e1b4d23b5d20457 upstream.

Because the kernel increments device's open count in input_open_device()
even if device is inhibited, the counter should always be decremented in
input_close_device() to keep it balanced.

Fixes: a181616487db ("Input: Add "inhibited" property")
Reviewed-by: Peter Hutterer &lt;peter.hutterer@who-t.net&gt;
Link: https://lore.kernel.org/r/ZFFz0xAdPNSL3PT7@google.com
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>Input: deactivate MT slots when inhibiting or suspending devices</title>
<updated>2022-07-20T18:35:13Z</updated>
<author>
<name>Angela Czubak</name>
<email>acz@semihalf.com</email>
</author>
<published>2022-07-20T18:15:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ebfa0043c96c7c7f645d0f96159bca988c873b6d'/>
<id>urn:sha1:ebfa0043c96c7c7f645d0f96159bca988c873b6d</id>
<content type='text'>
When inhibiting or suspending a device we are sending release events for
all currently held keys and buttons, however we retain active MT slot
state, which causes issues with gesture recognition when we resume or
uninhibit.

Let's fix it by introducing, in addition to input_dev_release_keys(),
nput_mt_release_slots() that will deactivate all currently active slots.

Signed-off-by: Angela Czubak &lt;acz@semihalf.com&gt;
Link: https://lore.kernel.org/r/20220718151715.1052842-3-acz@semihalf.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Input: properly queue synthetic events</title>
<updated>2022-07-20T18:35:11Z</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2022-07-20T18:10:47Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=59b7a5af8e8c22b20fc68eca48d7cfdc92501c1e'/>
<id>urn:sha1:59b7a5af8e8c22b20fc68eca48d7cfdc92501c1e</id>
<content type='text'>
We should not be passing synthetic events (such as autorepeat events)
out of order with the events coming from the hardware device, but rather
add them to pending events and flush them all at once.

This also fixes an issue with timestamps for key release events carrying
stale data from the previous autorepeat event.

Reviewed-by: Angela Czubak &lt;acz@semihalf.com&gt;
Link: https://lore.kernel.org/r/YszNfq4b6MkeoCJC@google.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'v5.18' into next</title>
<updated>2022-05-27T23:40:01Z</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2022-05-27T23:40:01Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=690e179059e7e89040d1cd564e39761567a8d5dc'/>
<id>urn:sha1:690e179059e7e89040d1cd564e39761567a8d5dc</id>
<content type='text'>
Sync up with mainline to get updates to OMAP4 keypad driver and other
upstream goodies.
</content>
</entry>
<entry>
<title>Input: remove unneeded variable in input_inhibit_device()</title>
<updated>2022-04-25T01:24:59Z</updated>
<author>
<name>Changcheng Deng</name>
<email>deng.changcheng@zte.com.cn</email>
</author>
<published>2022-04-20T20:55:07Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=0a112e7c681ca311b241c50a75d9206f301ca21c'/>
<id>urn:sha1:0a112e7c681ca311b241c50a75d9206f301ca21c</id>
<content type='text'>
Remove unneeded variable used to store return value.

Reported-by: Zeal Robot &lt;zealci@zte.com.cn&gt;
Signed-off-by: Changcheng Deng &lt;deng.changcheng@zte.com.cn&gt;
Link: https://lore.kernel.org/r/20220419064255.2563333-1-deng.changcheng@zte.com.cn
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Revert "Input: clear BTN_RIGHT/MIDDLE on buttonpads"</title>
<updated>2022-04-01T04:17:52Z</updated>
<author>
<name>José Expósito</name>
<email>jose.exposito89@gmail.com</email>
</author>
<published>2022-04-01T04:15:36Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=8b188fba75195745026e11d408e4a7e94e01d701'/>
<id>urn:sha1:8b188fba75195745026e11d408e4a7e94e01d701</id>
<content type='text'>
This reverts commit 37ef4c19b4c659926ce65a7ac709ceaefb211c40.

The touchpad present in the Dell Precision 7550 and 7750 laptops
reports a HID_DG_BUTTONTYPE of type MT_BUTTONTYPE_CLICKPAD. However,
the device is not a clickpad, it is a touchpad with physical buttons.

In order to fix this issue, a quirk for the device was introduced in
libinput [1] [2] to disable the INPUT_PROP_BUTTONPAD property:

	[Precision 7x50 Touchpad]
	MatchBus=i2c
	MatchUdevType=touchpad
	MatchDMIModalias=dmi:*svnDellInc.:pnPrecision7?50*
	AttrInputPropDisable=INPUT_PROP_BUTTONPAD

However, because of the change introduced in 37ef4c19b4 ("Input: clear
BTN_RIGHT/MIDDLE on buttonpads") the BTN_RIGHT key bit is not mapped
anymore breaking the device right click button and making impossible to
workaround it in user space.

In order to avoid breakage on other present or future devices, revert
the patch causing the issue.

Signed-off-by: José Expósito &lt;jose.exposito89@gmail.com&gt;
Reviewed-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Acked-by: Peter Hutterer &lt;peter.hutterer@who-t.net&gt;
Acked-by: Benjamin Tissoires &lt;benjamin.tissoires@redhat.com&gt;
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20220321184404.20025-1-jose.exposito89@gmail.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Input: add bounds checking to input_set_capability()</title>
<updated>2022-03-21T04:59:42Z</updated>
<author>
<name>Jeff LaBundy</name>
<email>jeff@labundy.com</email>
</author>
<published>2022-03-21T04:55:27Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=409353cbe9fe48f6bc196114c442b1cff05a39bc'/>
<id>urn:sha1:409353cbe9fe48f6bc196114c442b1cff05a39bc</id>
<content type='text'>
Update input_set_capability() to prevent kernel panic in case the
event code exceeds the bitmap for the given event type.

Suggested-by: Tomasz Moń &lt;tomasz.mon@camlingroup.com&gt;
Signed-off-by: Jeff LaBundy &lt;jeff@labundy.com&gt;
Reviewed-by: Tomasz Moń &lt;tomasz.mon@camlingroup.com&gt;
Link: https://lore.kernel.org/r/20220320032537.545250-1-jeff@labundy.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'v5.17-rc8' into next</title>
<updated>2022-03-15T02:14:29Z</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2022-03-15T02:14:29Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ce8356335027d3929fbfae4127451adaf36e1cd4'/>
<id>urn:sha1:ce8356335027d3929fbfae4127451adaf36e1cd4</id>
<content type='text'>
Sync up with mainline to again get the latest changes in HID subsystem.
</content>
</entry>
<entry>
<title>Input: add input_copy_abs() function</title>
<updated>2022-03-01T07:26:27Z</updated>
<author>
<name>Hans de Goede</name>
<email>hdegoede@redhat.com</email>
</author>
<published>2022-03-01T06:58:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=cb66b9ba5cdacab5592bce31a4083fc4ac172ea5'/>
<id>urn:sha1:cb66b9ba5cdacab5592bce31a4083fc4ac172ea5</id>
<content type='text'>
Add a new helper function to copy absinfo from one input_dev to
another input_dev.

This is useful to e.g. setup a pen/stylus input-device for combined
touchscreen/pen hardware where the pen uses the same coordinates as
the touchscreen.

Suggested-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Link: https://lore.kernel.org/r/20220131143539.109142-2-hdegoede@redhat.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
</feed>
