Skip to content

Commit 60b7ab6

Browse files
sreij-intel
authored andcommitted
platform: arm64: thinkpad-t14s-ec: new driver
Introduce EC driver for the ThinkPad T14s Gen6 Snapdragon, which is in theory compatible with ThinkPad ACPI. On Linux the system is booted with device tree, which is not supported by the ThinkPad ACPI driver (drivers/platform/x86/lenovo/thinkpad_acpi.c). Also most of the hardware compatibility is handled via ACPI tables, which are obviously not used when booting via device tree. Thus adding DT compatibility to the existing driver is not worth it as there is almost no code sharing. The driver currently exposes features, which are not available via other means: * Extra Keys * System LEDs * Keyboard Backlight Control The driver has been developed by reading the ACPI DSDT. There are some more features around thermal control, which are not yet supported by the driver. The speaker mute and mic mute LEDs need some additional changes in the ALSA UCM to be set automatically. Tested-by: Neil Armstrong <neil.armstrong@linaro.org> # on Thinkpad T14S OLED Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> Signed-off-by: Sebastian Reichel <sre@kernel.org> Link: https://patch.msgid.link/20250918-thinkpad-t14s-ec-v5-2-ac0bc6382c5c@collabora.com [ij: folded in patch from Chen Ni <nichen@iscas.ac.cn>] Link: https://patch.msgid.link/20250926091302.817919-1-nichen@iscas.ac.cn [ij: folded in patch from Lukas Bulwahn <lbulwahn@redhat.com>] Link: https://patch.msgid.link/20250926071859.138396-1-lukas.bulwahn@redhat.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
1 parent bee278e commit 60b7ab6

4 files changed

Lines changed: 643 additions & 0 deletions

File tree

MAINTAINERS

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25071,6 +25071,12 @@ W: http://thinkwiki.org/wiki/Ibm-acpi
2507125071
T: git git://repo.or.cz/linux-2.6/linux-acpi-2.6/ibm-acpi-2.6.git
2507225072
F: drivers/platform/x86/lenovo/thinkpad_acpi.c
2507325073

25074+
THINKPAD T14S EMBEDDED CONTROLLER DRIVER
25075+
M: Sebastian Reichel <sre@kernel.org>
25076+
S: Maintained
25077+
F: Documentation/devicetree/bindings/embedded-controller/lenovo,thinkpad-t14s-ec.yaml
25078+
F: drivers/platform/arm64/lenovo-thinkpad-t14s.c
25079+
2507425080
THINKPAD LMI DRIVER
2507525081
M: Mark Pearson <mpearson-lenovo@squebb.ca>
2507625082
L: platform-driver-x86@vger.kernel.org

drivers/platform/arm64/Kconfig

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,4 +70,24 @@ config EC_LENOVO_YOGA_C630
7070

7171
Say M or Y here to include this support.
7272

73+
config EC_LENOVO_THINKPAD_T14S
74+
tristate "Lenovo Thinkpad T14s Embedded Controller driver"
75+
depends on ARCH_QCOM || COMPILE_TEST
76+
depends on I2C
77+
depends on INPUT
78+
select INPUT_SPARSEKMAP
79+
select LEDS_CLASS
80+
select NEW_LEDS
81+
select SND_CTL_LED if SND
82+
help
83+
Driver for the Embedded Controller in the Qualcomm Snapdragon-based
84+
Lenovo Thinkpad T14s, which provides access to keyboard backlight
85+
and status LEDs.
86+
87+
This driver provides support for the mentioned laptop where this
88+
information is not properly exposed via the standard Qualcomm
89+
devices.
90+
91+
Say M or Y here to include this support.
92+
7393
endif # ARM64_PLATFORM_DEVICES

drivers/platform/arm64/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@
88
obj-$(CONFIG_EC_ACER_ASPIRE1) += acer-aspire1-ec.o
99
obj-$(CONFIG_EC_HUAWEI_GAOKUN) += huawei-gaokun-ec.o
1010
obj-$(CONFIG_EC_LENOVO_YOGA_C630) += lenovo-yoga-c630.o
11+
obj-$(CONFIG_EC_LENOVO_THINKPAD_T14S) += lenovo-thinkpad-t14s.o

0 commit comments

Comments
 (0)