Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp4612288rdb; Tue, 12 Dec 2023 04:49:42 -0800 (PST) X-Google-Smtp-Source: AGHT+IF+6PfvFeGk9PbxFWTwreyxMx+h6502q2VlwVRO8o3CZjhO6MlsoSFyPjR+wf7PVnBWmm6M X-Received: by 2002:a17:902:d4d0:b0:1cf:b413:8baa with SMTP id o16-20020a170902d4d000b001cfb4138baamr9893655plg.25.1702385381764; Tue, 12 Dec 2023 04:49:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702385381; cv=none; d=google.com; s=arc-20160816; b=yKiniQNAKiWs6mrFjjVW1ge3Q/CDfi8T0UjIl0AhqDoJsiJEytSKEZFVvcE2gFAm54 kts9bOL8YDe9bg2trszIOiGR67eV9OEe9PCRLeDJXoNtAXN30V5jcbKLe8jEZFIwXTB1 q3iezr6rZ7ZSJvqzTfS0XLEVWBe5oH5vztPBgGkDSbuck60lNIsvTzpA0cVPzBmxjQuf 4zgjd/YiSx16/kulsgXZdAhh08Yhqnq3LxSCB40RZtJudVVcMjZMdgsZC7CABTX3rRe5 Z6hZnI8JHjWwlFYAmqdQsPMt3RZc/+JzEAgchjCZpCAACcl5X91lVaifFiQJjlQwfOKt zbEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:content-transfer-encoding:mime-version :message-id:date:subject:from:dkim-signature; bh=b4W54utATdPW0v9Rg5ozUA/FQqmectrLNYP/hebVXZk=; fh=dhvS1eGMvUx1tavIFXBqrKW8ETuokCsS3YwwCc7v/Nw=; b=yLqdfmHpkabMV15DVklZl4Lj31HfTR2+phE2PnL+8n8a80MU0/2BWKoMPC1nPL7LVh EYxZP4ZDXE0lzSrF/qZDNAvopgacysX+P+wkMyAHgmXUnOvjoJqz+ubNe95H0w9GQbqV 1Mf/kq5p2SnZgZacdprI1SvUF+Ya04tZY/QXKlvgMvpH2tQbtWtmdiUAnz1JPUWFAwHC UqUnMpozMFh3p/UvBRwLqBzs7yXqNxAhWE9j2OkQlqOOmzCoEIyt+ED9aC4yK8Qei1lk jpN0HIRHrZ9An0noCEFBb0EityHmQcJIE7QEXUbBiQoY1w0O/KsHpmUf/Pv11C2VHaFh cCEw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@trvn.ru header.s=mail header.b=vGRocFg6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=trvn.ru Return-Path: Received: from morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id y18-20020a1709027c9200b001d04b44859esi7611542pll.269.2023.12.12.04.49.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Dec 2023 04:49:41 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@trvn.ru header.s=mail header.b=vGRocFg6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=trvn.ru Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 7D090802171B; Tue, 12 Dec 2023 04:49:36 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376291AbjLLMtU (ORCPT + 99 others); Tue, 12 Dec 2023 07:49:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39076 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376261AbjLLMtS (ORCPT ); Tue, 12 Dec 2023 07:49:18 -0500 Received: from box.trvn.ru (box.trvn.ru [194.87.146.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0DDE794; Tue, 12 Dec 2023 04:49:24 -0800 (PST) Received: from authenticated-user (box.trvn.ru [194.87.146.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by box.trvn.ru (Postfix) with ESMTPSA id D0AC94055E; Tue, 12 Dec 2023 17:49:19 +0500 (+05) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=trvn.ru; s=mail; t=1702385360; bh=xFPFmz9fsOLXhhrMLkO4fvtQbfof7wfzBF6Z1Vazxa4=; h=From:Subject:Date:To:Cc:From; b=vGRocFg63MUT6d05xfPiF5NwJF6E0XmREHY5ilqf2t0mFSdJpVPxJh8I8irBMWKIf dcDtNOQCAVhyKh+eTaW9aLAdIQFRiM/12Fdi28QRcFqoGLrzBlIR8wEEASxz8DWtRE 73eWgqqvEK7C6UNhXJ5wIb0G2M5E8OVxLgeVx62IOnEsGTtLPH7NQgaxCzo8d1c/5G Od8CIlHjeZW/eFvxf3mx+Z2eYUdZS/LDxdsHqJxzGJiAMmNrNDVflMf1EdaFVeq6XB KepJqulfMPv+Xa66s1HXsNfPn7oqAfRzroaoHYNiXVy6LYZGZEZwodmNPqXt1D+ssu 7qFz50guLW5ZA== From: Nikita Travkin Subject: [PATCH v2 0/3] power: supply: Acer Aspire 1 embedded controller Date: Tue, 12 Dec 2023 17:49:08 +0500 Message-Id: <20231212-aspire1-ec-v2-0-ca495ea0a7ac@trvn.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-B4-Tracking: v=1; b=H4sIAMRWeGUC/03MQQrCMBCF4auUWRvJTKFBV95DukjT0c4mLZM2K CV3NxYEl/+D9+2QWIUTXJsdlLMkmWMNOjUQJh+fbGSsDWSpRbKd8WkRZTQcTDe0IwUf0DuCeli UH/I6sHtfe5K0zvo+7Izf9ce4fyajsWbwF8ZA5Kx1t1VzPOsGfSnlA+8AoN+iAAAA To: Sebastian Reichel , Rob Herring , Krzysztof Kozlowski , Conor Dooley , cros-qcom-dts-watchers@chromium.org, Andy Gross , Bjorn Andersson , Konrad Dybcio Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Nikita Travkin X-Developer-Signature: v=1; a=openpgp-sha256; l=1984; i=nikita@trvn.ru; h=from:subject:message-id; bh=xFPFmz9fsOLXhhrMLkO4fvtQbfof7wfzBF6Z1Vazxa4=; b=owEBbQKS/ZANAwAIAUMc7O4oGb91AcsmYgBleFbLLp9TgfCu2NMSxQbxwWH59fQ7saOPgfap6 BKmiM87cYmJAjMEAAEIAB0WIQTAhK9UUj+qg34uxUdDHOzuKBm/dQUCZXhWywAKCRBDHOzuKBm/ dYssD/99sUsXEvLbcayqGJCcrcNfTp4gYzWCpuAd3tzlIJjc+rHa7WDuq1ZwFObpq+E/2pTFUds egv63KvAIm25HmkzPpC/EpzgThQquh7KFG/zqdWjrFKe8uacM+8MxEKgvvA4IXB3k39z6bu2o92 6GIxy8dqybthxldv6+5TdGCWnoMC6PtknRYcujiOsQtjR0XfHGzZPs3/LUjTUBZZreLEkEmeHMA fHa9lCO60KNryCAAzOp1P0eOdGvl4sihF9T1pqBTdX/o73YwWijLXYtX7Y7998BKeSpgu09AUtx S3gQIIkZp4wfDgKQwxBBdVQifLl2q9uiSVE+YH0K2HfQi2whLLxSDjmXfs6E3sYo7TvpBucU/hf xTLqllDW0ZYQxKuM+6j043G8KnZqO9LU4AF7NbqfaYIFjJYImlki3wxHZDraVmKC6jOEMFnejVD aYm6SHN6rXzq1aa/WxiF79DFRzmOpct9v4T42bgst82LEKwi+rBzddfVb2Lxn0dE5bmI13i1oMz m/oMElTSE0WiV7K0qW9uM6Ps0wdhsuN9aiJMEKp6QcWv8IpaY+A03012dNCLCPBnhRjeCwxjVg/ dL2wHceBS0ir2mdgqlzb/g4Dp3IEi6y9wAyUxlyEnuBvlCjMDTn42jEuhpY2V9lZI4S65rpAJds VJGFW1LkvP+0zkA== X-Developer-Key: i=nikita@trvn.ru; a=openpgp; fpr=C084AF54523FAA837E2EC547431CECEE2819BF75 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Tue, 12 Dec 2023 04:49:36 -0800 (PST) The laptop contains an embedded controller that provides a set of features: - Battery and charger monitoring - USB Type-C DP alt mode HPD monitoring - Lid status detection - Small amount of keyboard configuration* [*] The keyboard is handled by the same EC but it has a dedicated i2c bus and is already enabled. This port only provides fn key behavior configuration. Unfortunately, while all this functionality is implemented in ACPI, it's currently not possible to use ACPI to boot Linux on such Qualcomm devices. Thus this series implements and enables a new driver that provides support for the EC features. The EC would be one of the last pieces to get almost full support for the Acer Aspire 1 laptop in the upstream Linux kernel. This series is similar to the EC driver for Lenovo Yoga C630, proposed in [1] but seemingly never followed up... [1] https://lore.kernel.org/all/20230205152809.2233436-1-dmitry.baryshkov@linaro.org/ Signed-off-by: Nikita Travkin --- Changes in v2: - Drop incorrectly allowed reg in the ec connector binding (Krzysztof) - Minor style changes (Konrad) - Link to v1: https://lore.kernel.org/r/20231207-aspire1-ec-v1-0-ba9e1c227007@trvn.ru --- Nikita Travkin (3): dt-bindings: power: supply: Add Acer Aspire 1 EC power: supply: Add Acer Aspire 1 embedded controller driver arm64: dts: qcom: acer-aspire1: Add embedded controller .../bindings/power/supply/acer,aspire1-ec.yaml | 67 ++++ arch/arm64/boot/dts/qcom/sc7180-acer-aspire1.dts | 40 +- drivers/power/supply/Kconfig | 14 + drivers/power/supply/Makefile | 1 + drivers/power/supply/acer-aspire1-ec.c | 433 +++++++++++++++++++++ 5 files changed, 554 insertions(+), 1 deletion(-) --- base-commit: abb240f7a2bd14567ab53e602db562bb683391e6 change-id: 20231206-aspire1-ec-6b3d2cac1a72 Best regards, -- Nikita Travkin