<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/input/rmi4, branch v6.18.39</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.39</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.39'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2026-07-18T14:53:34+00:00</updated>
<entry>
<title>Input: synaptics-rmi4 - bound the F30 keymap to the GPIO/LED count</title>
<updated>2026-07-18T14:53:34+00:00</updated>
<author>
<name>Bryam Vargas</name>
<email>hexlabsecurity@proton.me</email>
</author>
<published>2026-06-14T05:36:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e849c6f51e6877104c765da084e001ec37c8e119'/>
<id>urn:sha1:e849c6f51e6877104c765da084e001ec37c8e119</id>
<content type='text'>
commit d577e46785d45484b2ab7e7309c49b18764bf56c upstream.

rmi_f30_map_gpios() allocates gpioled_key_map with
min(gpioled_count, TRACKSTICK_RANGE_END) == at most 6 entries, but
rmi_f30_attention() iterates the full f30-&gt;gpioled_count (device query
register, range 0..31) and dereferences gpioled_key_map[i], and
input-&gt;keycodemax is set to the full gpioled_count while input-&gt;keycode
points at the 6-entry allocation.

A device that reports gpioled_count &gt; 6 with GPIO support enabled
therefore causes an out-of-bounds read on the attention interrupt and
out-of-bounds read/write through the EVIOCGKEYCODE/EVIOCSKEYCODE ioctls,
which bound the index only against keycodemax. This is the same defect
as the F3A handler, which was copied from F30.

Size the keymap for the full gpioled_count; the mapping loop still
assigns only the first min(gpioled_count, TRACKSTICK_RANGE_END) entries.

Fixes: 3e64fcbdbd10 ("Input: synaptics-rmi4 - limit the range of what GPIOs are buttons")
Cc: stable@vger.kernel.org
Signed-off-by: Bryam Vargas &lt;hexlabsecurity@proton.me&gt;
Link: https://patch.msgid.link/20260614-b4-disp-818d6bda-v1-2-cf39a3615085@proton.me
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: synaptics-rmi4 - bound the F3A keymap to the GPIO count</title>
<updated>2026-07-18T14:53:34+00:00</updated>
<author>
<name>Bryam Vargas</name>
<email>hexlabsecurity@proton.me</email>
</author>
<published>2026-06-14T05:36:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8db211aed83733073b0814adaeeab61d4521474e'/>
<id>urn:sha1:8db211aed83733073b0814adaeeab61d4521474e</id>
<content type='text'>
commit 57c10915f2c16c90e0d46ad00876bf39ece40fc2 upstream.

rmi_f3a_initialize() takes the GPIO count from the device query register
(f3a-&gt;gpio_count = buf &amp; RMI_F3A_GPIO_COUNT, range 0..127).
rmi_f3a_map_gpios() then allocates gpio_key_map with
min(gpio_count, TRACKSTICK_RANGE_END) == at most 6 entries, but
rmi_f3a_attention() iterates the full gpio_count and dereferences
gpio_key_map[i], and input-&gt;keycodemax is set to the full gpio_count
while input-&gt;keycode points at the 6-entry allocation.

A device that reports gpio_count &gt; 6 therefore causes an out-of-bounds
read of gpio_key_map[] on every attention interrupt, and out-of-bounds
accesses through the input core's default keymap ioctls: EVIOCGKEYCODE
reads past the buffer (leaking adjacent slab memory to user space) and
EVIOCSKEYCODE writes a caller-controlled value past it, for any process
able to open the evdev node, since input_default_getkeycode() and
input_default_setkeycode() only bound the index against keycodemax.

Size the keymap for the full gpio_count. The mapping loop is unchanged:
it still assigns only the first min(gpio_count, TRACKSTICK_RANGE_END)
entries; the remaining slots stay KEY_RESERVED (devm_kcalloc zero-fills)
and are skipped when reporting.

Fixes: 9e4c596bfd00 ("Input: synaptics-rmi4 - add support for F3A")
Cc: stable@vger.kernel.org
Signed-off-by: Bryam Vargas &lt;hexlabsecurity@proton.me&gt;
Link: https://patch.msgid.link/20260614-b4-disp-818d6bda-v1-1-cf39a3615085@proton.me
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: synaptics-rmi4 - unregister function handlers on physical driver registration failure</title>
<updated>2026-07-18T14:53:34+00:00</updated>
<author>
<name>Haoxiang Li</name>
<email>haoxiang_li2024@163.com</email>
</author>
<published>2026-06-10T23:41:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=11f275f01c46ba8aaf9ce224f00e241d2d655193'/>
<id>urn:sha1:11f275f01c46ba8aaf9ce224f00e241d2d655193</id>
<content type='text'>
commit 6251f7d3472c0409e30f8d6a24f10d33d12e3f9a upstream.

If rmi_register_physical_driver() fails, the current error path
unregisters only the RMI bus. The function handlers registered
earlier remain registered with the driver core.

Add a separate error path to unregister the function handlers
before unregistering the bus in this failure case.

Fixes: 2b6a321da9a2 ("Input: synaptics-rmi4 - add support for Synaptics RMI4 devices")
Signed-off-by: Haoxiang Li &lt;haoxiang_li2024@163.com&gt;
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20260610064633.2837084-1-haoxiang_li2024@163.com
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: synaptics-rmi4 - fix a locking bug in an error path</title>
<updated>2026-04-11T12:26:38+00:00</updated>
<author>
<name>Bart Van Assche</name>
<email>bvanassche@acm.org</email>
</author>
<published>2026-02-23T23:05:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=33e646804070c8939c1509b11a79a7a2671e4b04'/>
<id>urn:sha1:33e646804070c8939c1509b11a79a7a2671e4b04</id>
<content type='text'>
commit 7adaaee5edd35a423ae199c41b86bd1ed60ed483 upstream.

Lock f54-&gt;data_mutex when entering the function statement since jumping
to the 'error' label when checking report_size fails causes that mutex
to be unlocked.

This bug has been detected by the Clang thread-safety checker.

Fixes: 3a762dbd5347 ("[media] Input: synaptics-rmi4 - add support for F54 diagnostics")
Signed-off-by: Bart Van Assche &lt;bvanassche@acm.org&gt;
Link: https://patch.msgid.link/20260223215118.2154194-16-bvanassche@acm.org
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: synaptics-rmi4 - add includes for types used in rmi_2d_sensor.h</title>
<updated>2025-09-08T13:39:41+00:00</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2025-09-06T16:17:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8742bebb846009af7a22e489fe99aced5e195b51'/>
<id>urn:sha1:8742bebb846009af7a22e489fe99aced5e195b51</id>
<content type='text'>
Headers should include definitions for types that they use.

Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Input: include export.h in modules using EXPORT_SYMBOL*()</title>
<updated>2025-08-21T19:00:59+00:00</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2025-08-06T18:16:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=df595059d54383c42607b59f1f9ea74dade280fe'/>
<id>urn:sha1:df595059d54383c42607b59f1f9ea74dade280fe</id>
<content type='text'>
A number of modules in the input subsystem use EXPORT_SYMBOL() and
friends without explicitly including the corresponding header
&lt;linux/export.h&gt;. While the build currently succeeds due to this header
being pulled in transitively, this is not guaranteed to be the case in
the future.

Let's add the explicit include to make the dependencies clear and
prevent future build breakage.

Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'ib-mfd-gpio-input-pwm-v6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd into next</title>
<updated>2025-08-04T06:28:48+00:00</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2025-08-04T06:28:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=a7bee4e7f78089c101be2ad51f4b5ec64782053e'/>
<id>urn:sha1:a7bee4e7f78089c101be2ad51f4b5ec64782053e</id>
<content type='text'>
Merge an immutable branch between MFD, GPIO, Input and PWM to resolve
conflicts for the merge window pull request.
</content>
</entry>
<entry>
<title>Input: synaptics-rmi4 - add support for F1A</title>
<updated>2025-07-27T08:41:19+00:00</updated>
<author>
<name>André Apitzsch</name>
<email>git@apitzsch.eu</email>
</author>
<published>2025-07-27T07:32:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4619b6b97553693be7faf21af0533c24240d1d4f'/>
<id>urn:sha1:4619b6b97553693be7faf21af0533c24240d1d4f</id>
<content type='text'>
RMI4 F1A implements capacitive keys. Add support for touch keys found in
some Synaptics touch controller configurations.

Signed-off-by: André Apitzsch &lt;git@apitzsch.eu&gt;
Link: https://lore.kernel.org/r/20250707-rmi4_f1a-v1-2-838d83c72e7f@apitzsch.eu
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Input: synaptics-rmi4 - add support for Forcepads (F21)</title>
<updated>2025-07-27T08:24:21+00:00</updated>
<author>
<name>Marge Yang</name>
<email>Marge.Yang@tw.synaptics.com</email>
</author>
<published>2025-07-23T16:16:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=a9c95d17dc13b8a4c5faa02a6b84ba83af058206'/>
<id>urn:sha1:a9c95d17dc13b8a4c5faa02a6b84ba83af058206</id>
<content type='text'>
Forcepad devices do not have physical buttons underneath the surface and
use F21 to report "clicks" based on touch pressure.

Signed-off-by: Marge Yang &lt;Marge.Yang@tw.synaptics.com&gt;
Link: https://lore.kernel.org/r/20250716033648.1785509-1-marge.yang@tw.synaptics.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
<entry>
<title>Input: synaptics-rmi - fix crash with unsupported versions of F34</title>
<updated>2025-05-19T18:58:36+00:00</updated>
<author>
<name>Dmitry Torokhov</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2025-05-05T22:49:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ca39500f6af9cfe6823dc5aa8fbaed788d6e35b2'/>
<id>urn:sha1:ca39500f6af9cfe6823dc5aa8fbaed788d6e35b2</id>
<content type='text'>
Sysfs interface for updating firmware for RMI devices is available even
when F34 probe fails. The code checks for presence of F34 "container"
pointer and then tries to use the function data attached to the
sub-device. F34 assigns the function data early, before it knows if
probe will succeed, leaving behind a stale pointer.

Fix this by expanding checks to not only test for presence of F34
"container" but also check if there is driver data assigned to the
sub-device, and call dev_set_drvdata() only after we are certain that
probe is successful.

This is not a complete fix, since F34 will be freed during firmware
update, so there is still a race when fetching and accessing this
pointer. This race will be addressed in follow-up changes.

Reported-by: Hanno Böck &lt;hanno@hboeck.de&gt;
Fixes: 29fd0ec2bdbe ("Input: synaptics-rmi4 - add support for F34 device reflash")
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/aBlAl6sGulam-Qcx@google.com
Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
</content>
</entry>
</feed>
