Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp5707703rdb; Sun, 17 Sep 2023 08:39:35 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFJHTEQHBuzc/OVJ06WzAI5wRqF/pt42t6xZe7fLpGgOVnVNr0W7RFTdMXnTdL2oP1vxfjQ X-Received: by 2002:a17:902:ea0a:b0:1c0:9b7c:f82a with SMTP id s10-20020a170902ea0a00b001c09b7cf82amr9120569plg.53.1694965175301; Sun, 17 Sep 2023 08:39:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694965175; cv=none; d=google.com; s=arc-20160816; b=Tb3SkWxXpW1ac+JBcuVtUp7PcRlvJ1VpSDD7Ejx9egmHdUCtAAxFECRhCMwIg0qDf2 qFz1waVrTSd5XIJqvDvV7txviOoZoLcOceQGwNzW5rTONpt4a5V3OwZ9KOQjdhUPa4OI F5NYsCggP3DS/zLt5hbgLzBmUebnVq+mAse7QNcqXmUzDcNkrMCSc0BZmSm8oX3MF8tZ BEDOvM7QR6BflbBUIT7BpHj1ec4dgN8f1C6OEW1j209tP2BMKwLXEQG+vzavUWisAhLG hxk7S9H6YQiNQESStCqneYJXRXOGwqoVA5Rlm5rLbSK02A0KvtE9Jg7VWlX5T0LHU3ZP G3TQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:message-id:references :in-reply-to:subject:cc:to:from:date:mime-version:dkim-signature; bh=ijB38zXEolhNiwPihsQgCwcz8q3f1WAC85f9FE5kY/c=; fh=4snbFD+x2x3pHJ081AjR2zdjqdmahNP1gxjOhJ6s1k4=; b=M4hBwEIVqB2gO5NkUuDo117hvMslaBl9dz8Zxrl5WIauTTJSQxOcK0aBlyAyXSxx85 iOyEhorsyeSC9uQNHsosVl1pfJIqtneGyH540X/8OAJre9yquLVg+uKr/XXkhYEjcrGJ gq0rxJCkEL58mE24p+T3tfs7Oz/mX1nMB76vPUKHnfR5Klb3MzHRBt5Z8jCnVcQbVy4k POrchBpuzGjF9aCH4Z3ZiPq7F9/RoaVVkPlf0NU9TUW6C8iafommqtfCaLo/j4LP2qZe Gz/85JQIcebagPpMweEsAJDug9Auscy97G1dx/Dh8QRt1dHrexr24NbBIXyJoitSuKNs fT/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@trvn.ru header.s=mail header.b=GYSyBN7f; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 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 pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id m1-20020a170902d18100b001c4401a7e18si3545594plb.382.2023.09.17.08.39.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 17 Sep 2023 08:39:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; dkim=pass header.i=@trvn.ru header.s=mail header.b=GYSyBN7f; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 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 pete.vger.email (Postfix) with ESMTP id D6D4F812E372; Sun, 17 Sep 2023 01:55:36 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233080AbjIQIyx (ORCPT + 99 others); Sun, 17 Sep 2023 04:54:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51934 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235129AbjIQIys (ORCPT ); Sun, 17 Sep 2023 04:54:48 -0400 Received: from box.trvn.ru (box.trvn.ru [194.87.146.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B7911186; Sun, 17 Sep 2023 01:54:42 -0700 (PDT) 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 26B77408E9; Sun, 17 Sep 2023 13:54:40 +0500 (+05) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=trvn.ru; s=mail; t=1694940880; bh=zGA3bn2I6aIG1camvyuPV4ppUOrnRMOzLfdsDkjVc9I=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=GYSyBN7fl2zAnhLH0wmyTgp8UCcb4dp3Z8GAr+Ok6KSct1PFGjHCktMg9voUVPGht 0d8cJeMG6L+sWUsaJ5Pss7hOxQ/p9s4HyBJZClnW0axnA7mCWpzYSGt+DEFSWzub+U B9pjA2jxX7KeLXlq2Aqff1OtoyMXrgHVqlBd65oXWZjeM+MY2JXi+CysheDwqz5ypH Md/bS2CTXBsWef8v6QC5hrZThRGffs+4rEQq+YX+YnkJuKBkhE44P8bNE/4cEwMyY9 0+osf62pe14Sh2Zl8mSUZ5guEtVGrDVIKWo4MnotGYEB27/jKWT6tQgvISgJ7bPoix qxB3Qdr0YI65w== MIME-Version: 1.0 Date: Sun, 17 Sep 2023 13:54:39 +0500 From: Nikita Travkin To: Krzysztof Kozlowski Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: Re: [PATCH 1/3] dt-bindings: mfd: qcom,spmi-pmic: Add pm8916 vm-bms and lbc In-Reply-To: <011074e5-cec2-1c69-7324-30d9ab653577@linaro.org> References: <20230916-pm8916-dtsi-bms-lbc-v1-0-7db0b42f9fb1@trvn.ru> <20230916-pm8916-dtsi-bms-lbc-v1-1-7db0b42f9fb1@trvn.ru> <18bef7a4-608b-9ba3-ce8f-ca25999705c3@linaro.org> <011074e5-cec2-1c69-7324-30d9ab653577@linaro.org> Message-ID: <27adb905b990398989b4c13f03339ae9@trvn.ru> X-Sender: nikita@trvn.ru Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.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 (pete.vger.email [0.0.0.0]); Sun, 17 Sep 2023 01:55:37 -0700 (PDT) Krzysztof Kozlowski писал(а) 17.09.2023 13:32: > On 17/09/2023 10:26, Nikita Travkin wrote: >> Krzysztof Kozlowski писал(а) 17.09.2023 12:58: >>> On 16/09/2023 15:57, Nikita Travkin wrote: >>>> PM8916 (and probably some other similar pmics) have hardware blocks for >>>> battery monitoring and charging. Add patterns for respecive nodes so the >>> >>> typo: respective >>> >> >> Oops, will fix if we get to v2. >> >>>> dt for those blocks can be validated properly. >>>> >>>> Signed-off-by: Nikita Travkin >>>> --- >>>> Schemas for those devices were added in [1]. >>> >>> "Dependency" >>> >> >> You are right, will try to word it better next time. >> >>>> >>>> [1] https://lore.kernel.org/r/20230915-pm8916-bms-lbc-v3-0-f30881e951a0@trvn.ru >>>> --- >>>> Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml | 6 ++++++ >>>> 1 file changed, 6 insertions(+) >>>> >>>> diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml >>>> index 9f03436b1cdc..8bcd76748faa 100644 >>>> --- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml >>>> +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml >>>> @@ -133,9 +133,15 @@ patternProperties: >>>> type: object >>>> $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml# >>>> >>>> + "^battery@[0-9a-f]+$": >>>> + type: object >>>> + oneOf: >>>> + - $ref: /schemas/power/supply/qcom,pm8916-bms-vm.yaml# >>> >>> That's just ref, so no need for oneOf... unless you already think this >>> will grow with different schemas like the charger below? >>> >> >> Yes, I think some other PMICs have different battery/fuel-gauge >> blocks too so I'd like to have some room for expansion here. > > There is always room. Which other device will have different battery > charger? > I know of non-"VM" BMS block in PM8226. It's used on some Nokia devices that people were working on so I expect it to appear in the future. There is also some BMS block in more modern PM6150 that I've seen being looked at by people interested in bringing sm7125 phones upstream. Both of those, to my knowledge, are completely different from this VM-BMS block, which I believe was present in the generation of pm8916, pm8909 and was abandoned again shortly after... Nikita > Best regards, > Krzysztof