Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp1061753rwb; Fri, 13 Jan 2023 07:30:13 -0800 (PST) X-Google-Smtp-Source: AMrXdXu4J2ixpgEAbDnds8hIwV93nHl+R6u4XtiS8YLPw7Q26h4//aPrMpjx0C/fKJTIr5w6UZsm X-Received: by 2002:a17:906:fb17:b0:86a:addf:880a with SMTP id lz23-20020a170906fb1700b0086aaddf880amr2401653ejb.65.1673623813616; Fri, 13 Jan 2023 07:30:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673623813; cv=none; d=google.com; s=arc-20160816; b=mUUaK1Fn40WztnBmDiPD0qaxy8s/NBfIeRNSCxf+O97yMBjNZMj7Z/n/E69jccAZET U0Pku+7+8hGOdy8RuPuU0tUaPTrkW2eITSy9Qjm60O1RZ/+M160CcEq00j5PDGS1xsUc 2Qc1eIqd57C3nm5XSbSGcC+WEMVZ2dvhdXdjJMHx+BzT+0Mj/P4Ob14CrAqwXe9m6MX1 NVUV1lnmk59aWr1Jfk0RJDjbACKv96vNrChsOc17MddQ7AGfpv/7UDEWfeZiCmDuhDPr xZWtexwgPffQUSxaHhixfavIJh9beQMP2gHeN4n7OqUzSkBYWY3/3nvC3MNhY5GHDfi9 Sfxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=Na3ZrE6A9rh81pSsXiZxGcF9IK4nLW3nyLKYL0aIcJk=; b=H8GFxbAJZdDOXbW/QLm+//jDAFiG4vEj4zyMkq6EjE00W4caalzFx3mcFtH9Sv+IMn 3Bq2+67kGaTwr0kxWReEFQwd9MafRQ3UncE5a+gb1cW2ab0/KM4SSyB/d64ix08AVQu9 2jtlKYdoAJNZyBrpmAwfrhZhGgBK0VI+Azpm2j4VTR1Pnruk0uUclQf/673mxH1SApGF C0zArODuv0UB4JtXsjZaLjGurFzMdpoa6lAmjTrBAMfITSB5QAMcB05q/Q1/LW/wEgVM uLao03llhaPKKKCPxqeTlF47Co3qnwh2szn+hOaCsZ4xYVLFXlDZ5RMtqrRBihDISXf7 xYyQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jxuFWlPt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g17-20020a056402321100b0049c1e28a77dsi2865496eda.42.2023.01.13.07.30.00; Fri, 13 Jan 2023 07:30:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jxuFWlPt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229583AbjAMPGT (ORCPT + 51 others); Fri, 13 Jan 2023 10:06:19 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59260 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230070AbjAMPFl (ORCPT ); Fri, 13 Jan 2023 10:05:41 -0500 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 24E3F8D3A5 for ; Fri, 13 Jan 2023 06:57:05 -0800 (PST) Received: by mail-lf1-x132.google.com with SMTP id o20so1534802lfk.5 for ; Fri, 13 Jan 2023 06:57:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=Na3ZrE6A9rh81pSsXiZxGcF9IK4nLW3nyLKYL0aIcJk=; b=jxuFWlPtwQ9F568YD6d7nIFz8eLjcs0j6kLwHG29Ujh36BK6Us5Gs+I+TQ/BD0dEXl Vw+WzawLuT/IjVpiybsa+PeKnqFKEEre++X0MiSNNoNAUEpZrOoifKCAU3uHgHprg29v bTB+RmgdNBJMTyz/mqCQCACxdjVTybgSP9fcZ72i/M09OGBAWDQ/2SOV8iQQhEsSdMCH GOm92NsH7S4h0K+5Smgzr8+IFa9qf3MQeUjSpkltR5akxfyvz+G+/rmyU+oVLHxE1n4k ihEy+h4XJQRkPFVfcnsej/1i2bHhY63EkW9Ybesg6fgAEzRhzPkOUi7CjLNfHgCzRQqa xRSw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Na3ZrE6A9rh81pSsXiZxGcF9IK4nLW3nyLKYL0aIcJk=; b=CnuchFUOcRQ4UM6WqFUUNj/aAVxSIxNAdaOi1Ha/F0JaCvYyPvgy4jIXY9PNjVDRNT B1K0lNZg0VFboK2biYevMQjF0WHtbaKtJG4vvljKU9h+jNe94Q4qFJTkCUdt2Cr1AGb0 7koOBM218vcBp99Oqm6QJeCNqgImUkx0dK67srMnYrpzmuB7l7aK1DV2er3ZamQaatkM +Ubni3/10H1xWKw9Ese9VX7Nch8wSHuyuZvbswhHN0MosTWArNmxrS8ijYhvKPrlH7HM RIjtE8z/P8bwh9Gnr/YTWqgz/XwVTOA5Smvxt1v7lLKQy3aOH0Sr3fms+sY9vC0rytUF DE1g== X-Gm-Message-State: AFqh2ko1ozQmGy1hFgnW1bejAf6tW+rFsK2TOrxcVr6721MBv4NBKuYy fJm1mJl7Tik9ozZo6fYNoAjURA== X-Received: by 2002:ac2:4ad1:0:b0:4d2:bb83:e7e6 with SMTP id m17-20020ac24ad1000000b004d2bb83e7e6mr221744lfp.59.1673621823553; Fri, 13 Jan 2023 06:57:03 -0800 (PST) Received: from [192.168.1.101] (abym53.neoplus.adsl.tpnet.pl. [83.9.32.53]) by smtp.gmail.com with ESMTPSA id e19-20020a05651236d300b00499b1873d6dsm3851569lfs.269.2023.01.13.06.57.00 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 13 Jan 2023 06:57:02 -0800 (PST) Message-ID: Date: Fri, 13 Jan 2023 15:56:59 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: [PATCH v2 0/4] soc: qcom: Introduce PMIC GLINK Content-Language: en-US To: Bjorn Andersson , Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Sebastian Reichel Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Subbaraman Narayanamurthy , Johan Hovold , Neil Armstrong References: <20230113041132.4189268-1-quic_bjorande@quicinc.com> From: Konrad Dybcio In-Reply-To: <20230113041132.4189268-1-quic_bjorande@quicinc.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, RCVD_IN_SORBS_HTTP,RCVD_IN_SORBS_SOCKS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 13.01.2023 05:11, Bjorn Andersson wrote: > This implements the base PMIC GLINK driver, a power_supply driver and a > driver for the USB Type-C altmode protocol. This has been tested and > shown to provide battery information, USB Type-C switch and mux requests > and DisplayPort notifications on SC8180X, SC8280XP and SM8350. > For the series: Tested-by: Konrad Dybcio # SM8350 PDX215 Thanks a lot for working on this! One thing, /sys/class/power_supply/qcom-battmgr-usb/input_current_limit is stuck at zero and so is the current_now as a result (the voltage readout is 5V + some noise, so that looks good), but I don't see any SET paths for it in the driver, so I suppose that's what the firmware default is? Konrad > Bjorn Andersson (4): > dt-bindings: soc: qcom: Introduce PMIC GLINK binding > soc: qcom: pmic_glink: Introduce base PMIC GLINK driver > soc: qcom: pmic_glink: Introduce altmode support > power: supply: Introduce Qualcomm PMIC GLINK power supply > > .../bindings/soc/qcom/qcom,pmic-glink.yaml | 102 ++ > drivers/power/supply/Kconfig | 9 + > drivers/power/supply/Makefile | 1 + > drivers/power/supply/qcom_battmgr.c | 1421 +++++++++++++++++ > drivers/soc/qcom/Kconfig | 15 + > drivers/soc/qcom/Makefile | 2 + > drivers/soc/qcom/pmic_glink.c | 336 ++++ > drivers/soc/qcom/pmic_glink_altmode.c | 477 ++++++ > include/linux/soc/qcom/pmic_glink.h | 32 + > 9 files changed, 2395 insertions(+) > create mode 100644 Documentation/devicetree/bindings/soc/qcom/qcom,pmic-glink.yaml > create mode 100644 drivers/power/supply/qcom_battmgr.c > create mode 100644 drivers/soc/qcom/pmic_glink.c > create mode 100644 drivers/soc/qcom/pmic_glink_altmode.c > create mode 100644 include/linux/soc/qcom/pmic_glink.h >