From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 87A134343E7 for ; Tue, 21 Jul 2026 07:54:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.181 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784620445; cv=none; b=Zkbu3OyO+xdDkcoPkpLxe6SBxUKaEPeZzLNgKdKGBYzBmoMMgv9xe3yG4mhkR3BlM3f1vB5AQKoK1bYKRhzvbgjamLUXOkPrXYCE1LgdzKcqhRX9vjWUS7jIo3u/a5A61J8o3yPhtsQQjlKghsQUmKbmMXgqvjv/7ntqhpFHrEM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784620445; c=relaxed/simple; bh=XbhUMMlW4dlSM7JU/MuPyutK2kIopX7DVU5/wV0oYo8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=TNiXr5kUXaAep8ybkJqeFY08bxu65DJb+dRwnABU0FM+b0Jwbk326D5lp1Q4Bd+6X6RxfZa9FvtRCASrXgxRZukQTkdzbU7fYPk8fSJM32mlDow40zH4Izn35tBkbYsy71A1vSfTR2m7A5RZP8ki1ZF2kwpI7s4DFAjDXdz7I4I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b=nygficqi; arc=none smtp.client-ip=209.85.214.181 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="nygficqi" Received: by mail-pl1-f181.google.com with SMTP id d9443c01a7336-2cace91f112so112953565ad.0 for ; Tue, 21 Jul 2026 00:54:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1784620442; x=1785225242; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to:content-type; bh=1UfUXCr53MVmAxCgEvl6p7BqmYW2167OMSThHKBq4o8=; b=nygficqioLunHGQ0MPawRDUG7S1Yw3+c5rYEJCy3HEhYpxtIJgcCOUjB95xSlB46w2 tGNrqtw1VlAUvC9fwTP5IkYpkeVy/Ld897OqMP0NLiLUW8LGUb7lYVLmz97Zo53smq2W tUjyrMsJF69mpxZlqGgwNNUK9V+I1k1E2pP+s= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1784620442; x=1785225242; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=1UfUXCr53MVmAxCgEvl6p7BqmYW2167OMSThHKBq4o8=; b=QfCsBf10gJgm5NesXx81E0m3HTSK/X6YT/0xM6L2ItDPXM9n5e1mFstDcw/1b2MHQ9 mIJbU2xMntcnLxbiXANKuBMj/HlCkJXHamcTO2UkVbaRoVRi0xwHhp7nDMJL3TofOh65 3PLpcH8fy3yVNHegT+MPD62URgHz6bus48YgWgwdtUg9qZ1IhoCHqt65GsVKkkTANlPj LDvZkr/dXh+Ur5/SEQWKR/u1ZwNVmD/BG73Mok3GCfGRi5l0/bc4RAjPE4WrMdnPy6x8 M7qMRDIqcxeQSH+wZXsiSipqjhTx4acLZzH5AHkamgQ/sbQiahzc9FA/XPwcsja7d0sV dCQg== X-Forwarded-Encrypted: i=1; AHgh+RpHu8e+fiJ3QGyBfalJEj9l0PuubEdx0FdoBIq9HGyG9hvum6xfSRCiNEduk17/1FQ1LdX6cxAIKZQ4kTw=@vger.kernel.org X-Gm-Message-State: AOJu0Yy/OxUPBCqApCqTZFbXOcQh6gCEehzu2172l8vU34I3ZBhQCrfy A73Kvg3sMBso93XudUO2C3BGDnotkS24vgIPiGQgLkHRZ+ogUUFUw7H98htJYwZmjA== X-Gm-Gg: AR+sD1254RVWizPv6x5zfoetnbBtfxgbiEkjS7J3FmNsgHyfY2IWYJdB3BO2PbrxXb6 wUdStAUBxgB0lOOyesjewNLlIAG2PMtOdbf2nYHfTzV3/GBdLzKz2VyvlvZn60nhuAG6/qZWTd2 ldTV4lVk0zIWlNUM5rrJYwod7HVt/mWVLnmw6+1pgMFvTKbnXX6bWCFO4Edg4wh/wWXWMokcFng 5p73DG/MgFW3bOquTwf6EqnOtZZWaqzvXeGod4HNmSTo44oqsW4NqHkTh6xcxnh3j3eZ1v1xzH8 RFXDdWSWPBm3dB7G0g+sBB2Dyz32zAlmgDKCvcsKWBUq2bms9LawGDuGKKR4GTvGCv7egSS6D5D lIMzaocMGPV09MaaeeZhLjEDQj/1USJ5PrbISl63S5yYcCKLmt5VM6L7P2cBFtdVvocKYjYNcd2 ZxpXxecHDvxxJHTraV/0cbgV5g3h8eGGe0uf4xK5bkEhxJ/7QLgsk598eeq5g= X-Received: by 2002:a17:903:3c44:b0:2ca:ed41:d331 with SMTP id d9443c01a7336-2cf34a3f5c3mr188180995ad.45.1784620442019; Tue, 21 Jul 2026 00:54:02 -0700 (PDT) Received: from wenstp920.tpe.corp.google.com ([2a00:79e0:201d:8:3916:f048:32c3:931f]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2cf3448f705sm70724175ad.15.2026.07.21.00.53.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Jul 2026 00:54:01 -0700 (PDT) From: Chen-Yu Tsai To: Matthias Brugger , AngeloGioacchino Del Regno , Benson Leung , Tzung-Bi Shih , Dmitry Torokhov , Jiri Kosina , Andi Shyti Cc: Andy Shevchenko , Chen-Yu Tsai , linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, chrome-platform@lists.linux.dev, linux-input@vger.kernel.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 0/9] arm64: mediatek: Chromebook trackpad supply fixes Date: Tue, 21 Jul 2026 15:52:14 +0800 Message-ID: <20260721075226.2347933-1-wenst@chromium.org> X-Mailer: git-send-email 2.55.0.229.g6434b31f56-goog Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Hi everyone, This is v3 of my Chromebook trackpad supply fixes and optimization series. Changes since v2: - Added new regulator "enable and wait" functions that wait until at least the given amount of time has passed since the regulator was last enabled. - Converted patches to use the new functions - New header inclusion cleanup patch for elan_i2c driver This series fixes the trackpad descriptions on some MediaTek-based Chromebooks: either the trackpad's supply was set as always-on to workaround missing delays in the driver, or the delay and supply are missing from the trackpad's device node. v1 was just the first patch [1]. It has since grown to cover multiple drivers and devices. Patch 1 adds new "enable and wait" functions for single and bulk regulator enable. Patch 2 cleans up header inclusion for elan_i2c driver. Patch 3 adds the correct enable delay after enabling the supply regulator for the Elan trackpad to initialize. This uses the new "enable and wait" regulator enable function. Patch 4 applies the same logic of skipping the power on delay to the i2c-hid-of driver. Patch 5 applies the same logic of skipping the power on delay to the i2c OF component prober library. Patch 6 adds a delay between when the device node found is enabled and when regulator_disable() is called. This gives an asynchronously probing driver some time to increment the enable count of their regulator reference, thus keeping the device operational and allowing the driver to skip the initialization delay. Patch 7 adds the correct delay for probing trackpads for Hana devices to the ChromeOS OF component prober. Patch 8 removes the "always-on" setting from the trackpad supply for Elm / Hana and adds the correct delay to the second source trackpad. This corrects the hardware description. Patch 9 adds the supply and power on delay properties to the Synaptics trackpad on the Spherion device. Combined with previous driver changes this should cause no actual functional changes or delays. Please take a look. Patches 3, 4, and 5 have build time dependencies on patch 1. I suggest placing patch 1 on a separate immutable branch or tag for the other maintainers to pull in. The three patches all have different maintainers. The DT changes must go in after all the driver changes land, especially patch 3 that adds delays to the Elan trackpad driver. Otherwise the user could potentially end up with a non-functional trackpad on the device. Thanks ChenYu [1] https://lore.kernel.org/all/20241001093815.2481899-1-wenst@chromium.org/ Chen-Yu Tsai (9): regulator: core: Add "enable and wait" functions Input: elan_i2c - sort include statements Input: elan_i2c - Wait for initialization after enabling regulator supply HID: i2c-hid-of: skip post-power-on delay if powered on sufficiently long i2c: of-prober: skip post-power-on delay if powered on sufficiently long i2c: of-prober: Defer regulator_disable() on successful probe in simple helper platform/chrome: of_hw_prober: Add delay for hana trackpads arm64: dts: mediatek: mt8173-elm-hana: Unmark trackpad supply as always-on arm64: dts: mediatek: mt8192-asurada-spherion: Add Synaptics trackpad's supply .../boot/dts/mediatek/mt8173-elm-hana.dtsi | 8 +-- arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi | 1 - .../mediatek/mt8192-asurada-spherion-r0.dts | 2 + drivers/hid/i2c-hid/i2c-hid-of.c | 9 ++-- drivers/i2c/i2c-core-of-prober.c | 25 ++++++--- drivers/input/mouse/elan_i2c_core.c | 23 ++++---- .../platform/chrome/chromeos_of_hw_prober.c | 4 +- drivers/regulator/core.c | 53 ++++++++++++++----- include/linux/regulator/consumer.h | 21 +++++--- include/linux/regulator/driver.h | 2 + 10 files changed, 96 insertions(+), 52 deletions(-) -- 2.55.0.229.g6434b31f56-goog