Skip to content

Input: synaptics - enable SMBus for ThinkPad P14s Gen 2i (LEN2072)

Dmitry Mikushin linux-input lkml 2 versions In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 1 replyIn review
  2. v12 patches 0 repliesSuperseded

Changes in v2 from the cover letter

- New patch 1. Sashiko pointed out that with patch 2 alone, on devices where Data1 is not at offset 0, rmi_f12_process_objects() could parse bytes past the end of what was read. The underlying off-by- data1_offset bound predates this series, so it is fixed separately with a Fixes: tag.
- No changes to patches 2 and 3.

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3Input: synaptics-rmi4 - f12: pass Data1-relative size to process_objectsdrivers/input/rmi4/rmi_f12.c+2 -20 replies
2/3Input: synaptics-rmi4 - f12: read only the object data on attentiondrivers/input/rmi4/rmi_f12.c+15 -10 replies
3/3Input: synaptics - add LEN2072 to smbus_pnp_ids for ThinkPad P14s Gen 2idrivers/input/mouse/synaptics.c+1 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/3] Input: synaptics - enable SMBus for ThinkPad P14s Gen 2i (LEN2072)

The ThinkPad P14s Gen 2i touchpad (Synaptics TM3471-030, LEN2072) is not on the SMBus passlist and runs in PS/2 mode. Forcing RMI4 alone does not help: the F12 attention handler reads the whole 79-byte data packet over SMBus on every frame, which caps the report rate at about 43 Hz and loses fast swipes.

Patch 1 fixes the size passed to rmi_f12_process_objects(), which counted from the start of the data packet instead of from Data1. Patch 2 makes F12 read only the registers up to and including Data1, raising the report rate to about 65 Hz on this machine. Patch 3 then adds LEN2072 to smbus_pnp_ids and should not be applied without patch 2.

Tested on a ThinkPad P14s Gen 2i (20VX) on 7.2.9, including s2idle suspend/resume and the TrackPoint on the RMI4 pass-through port. On this device Data1 is the first data register, so patch 1 does not change its behavior.

Changes in v2:
- New patch 1. Sashiko pointed out that with patch 2 alone, on devices where Data1 is not at offset 0, rmi_f12_process_objects() could parse bytes past the end of what was read. The underlying off-by- data1_offset bound predates this series, so it is fixed separately with a Fixes: tag.
- No changes to patches 2 and 3.

v1: https://lore.kernel.org/all/[email protected]/

Dmitry Mikushin (3):
Input: synaptics-rmi4 - f12: pass Data1-relative size to
process_objects
Input: synaptics-rmi4 - f12: read only the object data on attention
Input: synaptics - add LEN2072 to smbus_pnp_ids for ThinkPad P14s Gen

    2i
 drivers/input/mouse/synaptics.c |  1 +
 drivers/input/rmi4/rmi_f12.c    | 20 +++++++++++++++++---
 2 files changed, 18 insertions(+), 3 deletions(-)
Signature · 1 line
2.56.0