Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Daniel J Blueman <daniel@quora.org>
Date: Tue, 29 Sep 2026 12:14:43 +0800
Subject: [PATCH] i2c: qcom-geni: restore tSCL with 32MHz I2C fast-mode

Commit cb97bf3d4f91 ("i2c: qcom-geni: Fix hardcoded clock index in
SE_GENI_CLK_SEL") allowed GENI to use 32MHz clock. This changed I2C
timing, making the Yoga Slim 7x keyboard (ITE 048D:8987) unusable
on all boots, and touchpad unusable on some boots, resulting in:

i2c_hid_of 1-003a: unexpected HID descriptor bcdVersion (0x0000)
i2c_hid_of 1-002c: failed to fetch HID descriptor: -110

With this change, t_high_cnt 3 and clk_div 4 gave a tSCL of 375ns
versus the previous default of 521ns, however the I2C spec has a
minimum tSCL of 600ns.

Restore tSCL to the spec with t_high_cnt 5 giving a 625ns tSCL,
verified on Lenovo Yoga Slim 7x X1E-80100.

Fixes: 506bb2ab0075 ("i2c: qcom-geni: Support systems with 32MHz serial engine clock")
Cc: <stable@vger.kernel.org>
Signed-off-by: Daniel J Blueman <daniel@quora.org>
---
drivers/i2c/busses/i2c-qcom-geni.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/i2c/busses/i2c-qcom-geni.c b/drivers/i2c/busses/i2c-qcom-geni.c
index 6a39e21d5ed4..1336a09ca183 100644
--- a/drivers/i2c/busses/i2c-qcom-geni.c
+++ b/drivers/i2c/busses/i2c-qcom-geni.c
@@ -193,7 +193,7 @@ static const struct geni_i2c_clk_fld geni_i2c_clk_map_19p2mhz[] = {
/* source_clock = 32 MHz */
static const struct geni_i2c_clk_fld geni_i2c_clk_map_32mhz[] = {
{ I2C_MAX_STANDARD_MODE_FREQ, 12, 9, 10, 26 },
- { I2C_MAX_FAST_MODE_FREQ, 4, 3, 9, 19 },
+ { I2C_MAX_FAST_MODE_FREQ, 4, 5, 9, 19 },
{ I2C_MAX_FAST_MODE_PLUS_FREQ, 2, 3, 5, 15 },
{}
};
--
2.53.0
7 changes: 5 additions & 2 deletions pkgbuilds/linux-omarchy-aarch64/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,7 @@ source=(
1103-HID-asus-disable-OOBE-mode-on-the-ProArt-P14-keyboard-too.patch
1104-HID-asus-turn-the-keyboard-backlight-off-for-sleep-without-asus-wmi.patch
2000-media-iris-reset-AHB-bridge-before-enabling-HW-mode.patch
2001-i2c-qcom-geni-restore-tSCL-with-32MHz-I2C-fast-mode.patch
)
source_aarch64=(config.aarch64)
validpgpkeys=(
Expand Down Expand Up @@ -605,7 +606,8 @@ sha256sums=('12e8d5a973d1ad7c5a5c69882e4022b131ed715db7003fdcd760ddf8c3e51941'
'9b5940534409ec08d285fbb749c7f6ba1649825f346e7ab2a1f975b5dfbcf310'
'c7b388262ae9f8f9ec2e4f3366eb2d0cbd4d1e93f0bb563b7d3df3a17fd16e74'
'2efbd3f5d196c31c85a3733707a89cd54f8579756e30f3a16b8ac45ed76b32a6'
'61260d5828b8d5009df572d5efe50ae359879fb0fbb1bc42d9145dc1947fc8dd')
'61260d5828b8d5009df572d5efe50ae359879fb0fbb1bc42d9145dc1947fc8dd'
'8280858662ab697a0e3b642b5bab80daaa869f8f048614e5c955e1a0203ff342')
sha256sums_aarch64=('0945fa582a85896d16a0b826a05411247621885f0fb10d98369bd09b7f1599dd')
b2sums=('5326dde778eb945f282740ef0d8765b46fbd198f1209cdfd7b91e5dac1312fc01f8bf0b2bc67b16a76de736edd8ea21b38b6c91e696ec0c4b39746cd21a15214'
'SKIP'
Expand Down Expand Up @@ -953,7 +955,8 @@ b2sums=('5326dde778eb945f282740ef0d8765b46fbd198f1209cdfd7b91e5dac1312fc01f8bf0b
'4d7f30645b60a53f38426ae3b81d63aeaa5131c37de609a29ed6f860b9c8c4af135344adc2ebf34d2578c5b7e24fc2f5953313626133a84dd11899ec8ddf86d4'
'fe4c9b5c3daa914887734219bf63c651e28981cbc6ea9fdb11316b40e7c6e91d2784fdcc8307e5592eeed85809fb7e0ed284bd4b1e2e0714202f014705e4247d'
'5c5a6d3a59de1be12520ec544e9f259ceef4c0981f371b363a54b4b4764ffcec198d499059e94b4ebb1bdd0293438ea6b3ea6eff6812698d9c754e98af2a946b'
'dd6c431db54ed291186cbe2ede032d8839caeaef83141d4f2fc4304c8580b426937da40aa29b66d3cbb52fedbc734c0dc6c99e5b5c266badb0d78b194f73c093')
'dd6c431db54ed291186cbe2ede032d8839caeaef83141d4f2fc4304c8580b426937da40aa29b66d3cbb52fedbc734c0dc6c99e5b5c266badb0d78b194f73c093'
'561c8e3ce34f82233d80cf59456877d547d2e49e76959a17d13d00ea9c001ced4698316579c47f27a39a87056812a042519f2fd91358a34bff1bf6e295fc040c')
b2sums_aarch64=('8c93d3a66925469954c7f13f06b184cfbd16881bba91f8cfd92c2d64efb8a961e9bfa4a3bc4ed5598c49b25f074f8579048726a960bcc185ab2577ad85e4d509')

# https://www.kernel.org/pub/linux/kernel/v7.x/sha256sums.asc
Expand Down
2 changes: 2 additions & 0 deletions pkgbuilds/linux-omarchy-aarch64/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ The laptops get no device tree from their firmware, so the package builds the Wi

`2000` is "media: iris: reset AHB bridge before enabling HW mode" (cc330f558996, in the media tree for 7.4). This config builds the Iris video decoder, and without the fix its firmware can assert when a video starts after the decoder has been idle. It was reported and tested on the Yoga Slim 7x.

`2001` is "i2c: qcom-geni: restore tSCL with 32MHz I2C fast-mode", [posted on 29 September 2026](https://lore.kernel.org/all/20260929041444.9837-1-daniel@quora.org/) and not merged yet. It is here for the move past 7.2.8. From 7.2.9 the driver runs the Snapdragon laptops' I2C buses from their 32 MHz clock (139efdb3ee6e, "Fix hardcoded clock index in SE_GENI_CLK_SEL"), and that clock's fast-mode timing gives a clock pulse of 375 ns where the I2C standard asks for at least 600 ns. The Yoga Slim 7x's keyboard and touchpad then stop answering, also at the disk password prompt. On 7.2.8 these laptops do not use the 32 MHz table, so the patch changes nothing yet and the package was not rebuilt for it. Tested on the Yoga Slim 7x with only the I2C driver swapped on 7.2.8-4: the 7.2.9 driver has no keyboard or touchpad, and the 7.2.9 driver with this patch has both (2026-10-12). For 7.3 upstream took a different fix, "i2c: qcom-geni: Restore the source-clock selection policy" ([8cb5c17be3a2 in the I2C fixes branch](https://lore.kernel.org/r/20260928-b4-i2c-qcom-geni-preserve-source-clock-v1-1-9aded7552a76@oss.qualcomm.com)), which keeps these buses on their 19.2 MHz clock. It applies from 7.2.9 on, so it goes in with the move past 7.2.8, and once the kernel has it this patch can go.

`ARM_SCMI_CPUFREQ` and `ARM_SCMI_PERF_DOMAIN` are built in since `7.2.8-5`. The X1 and X2 CPUs scale through SCMI's performance protocol, and neither module carries an alias, so as modules nothing loaded them: the laptops booted with no cpufreq policies and ran at whatever clock the firmware left. Arch Linux ARM's kernel builds both in. The N1x scales through ACPI CPPC and is unaffected.

Two differences from Arch Linux ARM's kernel matter on these laptops. Omarchy's Snapdragon setup handles both, so the config stays as the N1x needs it.
Expand Down
Loading