Message ID | 20230711-topic-rb1_regulator-v1-1-bc4398c35800@linaro.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a6b2:0:b0:3e4:2afc:c1 with SMTP id c18csp386404vqm; Tue, 11 Jul 2023 03:53:54 -0700 (PDT) X-Google-Smtp-Source: APBJJlF1SHMCV9qLmvJkfSnfGUfA2HPQkBcZR67K4e8kRP60x3tsuosax+vCl34EI9jt1A8EBkUR X-Received: by 2002:a17:906:2207:b0:991:b613:9b65 with SMTP id s7-20020a170906220700b00991b6139b65mr13249735ejs.37.1689072833957; Tue, 11 Jul 2023 03:53:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689072833; cv=none; d=google.com; s=arc-20160816; b=IwDBYKsS8RZY9CPwptddNy+87Nmi3FVc2PfxG9qCsnKm34v3Ph0AcOcCTRiFOLW4BV xHEasgYIgzhhMPeZAHI/EXTUwTtqaQ5OtSKzY7UBV4Q/RJjeFzrjgtf5+1LMwbuWSZQn WlmrAioBThzHdWMZy9OiMWz0HmCxvM8z8ttUrwGhg7o46W7WJm94DMvhuTTVqH/zeSly pl4S88Xx2lYAA73j3bdM0dqiCOjEYB7mHSK+qGE4NCpjV1D0pNLQj6FljBe/EAW5Q9QE sWQ4Vxp24ekf1EK6uCiGWsAQdj7Zdq/ZMBwMs0gNwN93LuaBvW8WbwzObNhgm/Lprx7M wvxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:message-id:content-transfer-encoding :mime-version:subject:date:from:dkim-signature; bh=NyZ8tGGEOmeJVu8EC8qxSRaeNCjOU6ONoIt2Vl89luE=; fh=lBkGO1Pg/rkqrTY1fvKKqf5E1Ky82e99gwdKb2DA3Q4=; b=RdI6LObzRcCxRSC/VIouootgv5AgcpmNXeuOvfee/WojtkN7Trn3mr78Exr5xz8K2f CMnaNbwY2WHo4byXD3dW2PKy3W6UKS6fMFu8A1KpVGLuac7wMnpQVnPEE867tq3m8Fae 14q0N6+rpBZ8fFyTw7/68x2KdI6fkgwY9uLjNwJy6IIBIa9GWm1QjaM+ACxMJ2/CJIqf Boeg2BOTxxiZuDNwTf8QQRpwZmVeuvhEu5YBgH2xM/dupwZGbPaxVbdZb3uImq39CbS8 LWwo76UotpEQRUBbv4/QUBU9YaPl0/HenqdjUbbjY6PWjyJCkMOgxLd6lTVhbSiTBZ48 tBsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=X5buVxt+; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t5-20020a170906948500b00988c81e980dsi1805772ejx.1039.2023.07.11.03.53.30; Tue, 11 Jul 2023 03:53:53 -0700 (PDT) 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=X5buVxt+; 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 S230313AbjGKK21 (ORCPT <rfc822;gnulinuxfreebsd@gmail.com> + 99 others); Tue, 11 Jul 2023 06:28:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230063AbjGKK20 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 11 Jul 2023 06:28:26 -0400 Received: from mail-lf1-x134.google.com (mail-lf1-x134.google.com [IPv6:2a00:1450:4864:20::134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 46D5FE42 for <linux-kernel@vger.kernel.org>; Tue, 11 Jul 2023 03:28:24 -0700 (PDT) Received: by mail-lf1-x134.google.com with SMTP id 2adb3069b0e04-4fb8574a3a1so8446942e87.1 for <linux-kernel@vger.kernel.org>; Tue, 11 Jul 2023 03:28:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1689071302; x=1691663302; h=cc:to:message-id:content-transfer-encoding:mime-version:subject :date:from:from:to:cc:subject:date:message-id:reply-to; bh=NyZ8tGGEOmeJVu8EC8qxSRaeNCjOU6ONoIt2Vl89luE=; b=X5buVxt+KuCkOgj/KaZqhBOVzH2mKBG2uR/fietaam6PmKctkFr/m+xqMp3kXCTYi/ oBGjo9HYIEacnJPqbPVoH4wLIBoXjp2yKrK/Ga7v7/+7qDG5lEuKHiWhwlhY7mZD5xw1 i0JH7JtfQ2iFf3TCUD3uJn+Rc7lUkzWfU2Ob2Th0SPOhUhUbZsHmJ9NqZ76VBs80cc7v 26RqbmeduzcSDhspc2R/yTJrz2ddh08AfORZZCR0arBBosdCcYTkdAMw8vGjmWCToGOu jEI+kZy1SQ4VzjB5wbqtQqXBbi1oPRkkqm5Dgh3qff9xP8an3rqssV+oMkt2fxykTRG/ W5Qg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689071302; x=1691663302; h=cc:to:message-id:content-transfer-encoding:mime-version:subject :date:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=NyZ8tGGEOmeJVu8EC8qxSRaeNCjOU6ONoIt2Vl89luE=; b=HcTf2dggOeCaWABR2oCg09VYc3xWH9DtsRtJM2GjS7Ak6rg6bBrre/5mJFF/Ro3+WX KlLcoj471smMZ3tOWzLYkIGxCP7CZvdZ1+1lo0VZFmBjJUGwyqRBktRMG6qBQ4rFGUKQ Nn9xFwoGL0JVYl73MULWl8eNRxWfvQ+B0SU+DZYC4OU4nEfrW4+Hkk/T6nyG72i8mgeR 8/Vn8GwQnNJPdGtAuVPVfimGh0NgAahkQNWCfKT4rHkTrj9f3PfhoHwxZ6cEzoG+ohPi bWsXmimVQBjjR5IJWBdrqyRz/MbJvkepE44qwUkHI/1RtuNMxRfMj9TfBvifa0x9RlFv ahCQ== X-Gm-Message-State: ABy/qLYO81/0WQS7jAM2eSCVdloMKP0FHjl9eOyLWzCwAcEJ3CJ/G9qh qo0O2RsaYVV22xn/lS8dMxZAlg== X-Received: by 2002:a19:6601:0:b0:4fb:7447:e724 with SMTP id a1-20020a196601000000b004fb7447e724mr12807977lfc.8.1689071302424; Tue, 11 Jul 2023 03:28:22 -0700 (PDT) Received: from [192.168.1.101] (abyl96.neoplus.adsl.tpnet.pl. [83.9.31.96]) by smtp.gmail.com with ESMTPSA id b26-20020ac247fa000000b004fbb207ee0asm260092lfp.206.2023.07.11.03.28.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Jul 2023 03:28:22 -0700 (PDT) From: Konrad Dybcio <konrad.dybcio@linaro.org> Date: Tue, 11 Jul 2023 12:28:17 +0200 Subject: [PATCH] arm64: dts: qcom: qrb2210-rb1: Add regulators MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230711-topic-rb1_regulator-v1-1-bc4398c35800@linaro.org> X-B4-Tracking: v=1; b=H4sIAMAurWQC/x2N0QrCMAwAf2Xk2cDaFUV/RWSkXdwCpR3pJsLYv xt8vIPjDmiswg0e3QHKH2lSi4G7dJAWKjOjTMbgez/0N+dwq6sk1OhG5XnPtFXFEFKgie+DD1e wMlJjjEolLdaWPWeTq/Jbvv/V83WeP+qmkcl6AAAA To: Andy Gross <agross@kernel.org>, Bjorn Andersson <andersson@kernel.org>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org> Cc: Marijn Suijten <marijn.suijten@somainline.org>, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio <konrad.dybcio@linaro.org> X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1689071300; l=8057; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=Iba3nS85j60Hy+togLR/dX0iY23cMPgt7+PGSw52Izc=; b=sZMBSlLzoztBrESJW0fOCRIgMEf10JSI/h9W9GIfu1cLcJ/vF6qyKTpQMfgfkblHkvZXJLuQb FQPaZdWgZt7CoBniFotFMyYx+uUHWx9Z+xBu+gZyZX+k8NGbDq7teOv X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771121235784679664 X-GMAIL-MSGID: 1771121235784679664 |
Series |
arm64: dts: qcom: qrb2210-rb1: Add regulators
|
|
Commit Message
Konrad Dybcio
July 11, 2023, 10:28 a.m. UTC
Add and assign RPM regulators coming from PM2250.
Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
arch/arm64/boot/dts/qcom/qrb2210-rb1.dts | 266 +++++++++++++++++++++++++++++++
1 file changed, 266 insertions(+)
---
base-commit: 8e4b7f2f3d6071665b1dfd70786229c8a5d6c256
change-id: 20230711-topic-rb1_regulator-44c4ade93246
Best regards,
Comments
On Tue, 11 Jul 2023 at 13:28, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > > Add and assign RPM regulators coming from PM2250. > > Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> > --- > arch/arm64/boot/dts/qcom/qrb2210-rb1.dts | 266 +++++++++++++++++++++++++++++++ > 1 file changed, 266 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts b/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts > index ef3616093289..eadba066972e 100644 > --- a/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts > +++ b/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts > @@ -38,6 +38,91 @@ key-volume-up { > wakeup-source; > }; > }; > + > + vreg_hdmi_out_1p2: regulator-hdmi-out-1p2 { > + compatible = "regulator-fixed"; > + regulator-name = "VREG_HDMI_OUT_1P2"; > + regulator-min-microvolt = <1200000>; > + regulator-max-microvolt = <1200000>; > + vin-supply = <&vdc_1v2>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + lt9611_3v3: regulator-lt9611-3v3 { > + compatible = "regulator-fixed"; > + regulator-name = "LT9611_3V3"; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + vin-supply = <&vdc_3v3>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + /* Main barrel jack input */ > + vdc_12v: regulator-vdc-12v { > + compatible = "regulator-fixed"; > + regulator-name = "DC_12V"; > + regulator-min-microvolt = <12000000>; > + regulator-max-microvolt = <12000000>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + /* 1.2V supply stepped down from the barrel jack input */ > + vdc_1v2: regulator-vdc-1v2 { > + compatible = "regulator-fixed"; > + regulator-name = "VDC_1V2"; > + regulator-min-microvolt = <1200000>; > + regulator-max-microvolt = <1200000>; > + vin-supply = <&vdc_12v>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + /* 3.3V supply stepped down from the barrel jack input */ > + vdc_3v3: regulator-vdc-3v3 { > + compatible = "regulator-fixed"; > + regulator-name = "VDC_3V3"; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + vin-supply = <&vdc_12v>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + /* 5V supply stepped down from the barrel jack input */ > + vdc_5v: regulator-vdc-5v { > + compatible = "regulator-fixed"; > + regulator-name = "VDC_5V"; > + > + regulator-min-microvolt = <5000000>; > + regulator-max-microvolt = <5000000>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + /* "Battery" voltage for the SoM, stepped down from the barrel jack input */ > + vdc_vbat_som: regulator-vdc-vbat { > + compatible = "regulator-fixed"; > + regulator-name = "VBAT_SOM"; > + regulator-min-microvolt = <4200000>; > + regulator-max-microvolt = <4200000>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + /* PM2250 charger out, supplied by VBAT */ > + vph_pwr: regulator-vph-pwr { > + compatible = "regulator-fixed"; > + regulator-name = "vph_pwr"; > + regulator-min-microvolt = <3700000>; > + regulator-max-microvolt = <3700000>; > + vin-supply = <&vdc_vbat_som>; > + > + regulator-always-on; > + regulator-boot-on; > + }; > }; > > &pm2250_resin { > @@ -49,7 +134,183 @@ &qupv3_id_0 { > status = "okay"; > }; > > +&rpm_requests { > + regulators { > + compatible = "qcom,rpm-pm2250-regulators"; > + vdd_s3-supply = <&vph_pwr>; > + vdd_s4-supply = <&vph_pwr>; > + vdd_l1_l2_l3_l5_l6_l7_l8_l9_l10_l11_l12-supply = <&pm2250_s3>; > + vdd_l4_l17_l18_l19_l20_l21_l22-supply = <&vph_pwr>; > + vdd_l13_l14_l15_l16-supply = <&pm2250_s4>; > + > + /* > + * S1 - VDD_APC > + * S2 - VDD_CX > + */ > + > + pm2250_s3: s3 { > + /* 0.4V-1.6625V -> 1.3V (Power tree requirements) */ > + regulator-min-microvolts = <1350000>; > + regulator-max-microvolts = <1350000>; > + regulator-boot-on; > + }; > + > + pm2250_s4: s4 { > + /* 1.2V-2.35V -> 2.05V (Power tree requirements) */ > + regulator-min-microvolts = <2072000>; > + regulator-max-microvolts = <2072000>; > + regulator-boot-on; Do you still need this with the proper foo-supply in place? > + }; > + > + /* L1 - VDD_MX */ > + > + pm2250_l2: l2 { > + /* LPDDR4X VDD2 */ > + regulator-min-microvolts = <1136000>; > + regulator-max-microvolts = <1136000>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + pm2250_l3: l3 { > + /* LPDDR4X VDDQ */ > + regulator-min-microvolts = <616000>; > + regulator-max-microvolts = <616000>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + pm2250_l4: l4 { > + /* max = 3.05V -> max = just below 3V (SDHCI2) */ > + regulator-min-microvolts = <1648000>; > + regulator-max-microvolts = <2992000>; > + regulator-allow-set-load; > + }; > + > + pm2250_l5: l5 { > + /* CSI/DSI */ > + regulator-min-microvolts = <1232000>; > + regulator-max-microvolts = <1232000>; > + regulator-allow-set-load; > + regulator-boot-on; why? > + }; > + > + pm2250_l6: l6 { > + /* DRAM PLL */ > + regulator-min-microvolts = <928000>; > + regulator-max-microvolts = <928000>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + pm2250_l7: l7 { > + /* Wi-Fi CX/MX */ > + regulator-min-microvolts = <664000>; > + regulator-max-microvolts = <664000>; > + }; > + > + /* > + * L8 - VDD_LPI_CX > + * L9 - VDD_LPI_MX > + */ > + > + pm2250_l10: l10 { > + /* Wi-Fi RFA */ > + regulator-min-microvolts = <1300000>; > + regulator-max-microvolts = <1300000>; > + }; > + > + pm2250_l11: l11 { > + /* GPS RF1 */ > + regulator-min-microvolts = <1000000>; > + regulator-max-microvolts = <1000000>; > + regulator-boot-on; Shouldn't it be handled by the modem on its own? > + }; > + > + pm2250_l12: l12 { > + /* USB PHYs */ > + regulator-min-microvolts = <928000>; > + regulator-max-microvolts = <928000>; > + regulator-allow-set-load; > + regulator-boot-on; You guess the question (and further on) > + }; > + > + pm2250_l13: l13 { > + /* USB/QFPROM/PLLs */ > + regulator-min-microvolts = <1800000>; > + regulator-max-microvolts = <1800000>; > + regulator-allow-set-load; > + regulator-boot-on; > + }; > + > + pm2250_l14: l14 { > + /* SDHCI1 VQMMC */ > + regulator-min-microvolts = <1800000>; > + regulator-max-microvolts = <1800000>; > + regulator-allow-set-load; > + /* Broken hardware, never turn it off! */ > + regulator-always-on; > + }; > + > + pm2250_l15: l15 { > + /* WCD/DSI/BT VDDIO */ > + regulator-min-microvolts = <1800000>; > + regulator-max-microvolts = <1800000>; > + regulator-allow-set-load; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + pm2250_l16: l16 { > + /* GPS RF2 */ > + regulator-min-microvolts = <1800000>; > + regulator-max-microvolts = <1800000>; > + regulator-boot-on; > + }; > + > + pm2250_l17: l17 { > + regulator-min-microvolts = <3000000>; > + regulator-max-microvolts = <3000000>; > + }; > + > + pm2250_l18: l18 { > + /* VDD_PXn */ > + regulator-min-microvolts = <1800000>; > + regulator-max-microvolts = <1800000>; > + }; > + > + pm2250_l19: l19 { > + /* VDD_PXn */ > + regulator-min-microvolts = <1800000>; > + regulator-max-microvolts = <1800000>; > + }; > + > + pm2250_l20: l20 { > + /* SDHCI1 VMMC */ > + regulator-min-microvolts = <2856000>; > + regulator-max-microvolts = <2856000>; > + regulator-allow-set-load; > + }; > + > + pm2250_l21: l21 { > + /* SDHCI2 VMMC */ > + regulator-min-microvolts = <2960000>; > + regulator-max-microvolts = <3300000>; > + regulator-allow-set-load; > + regulator-boot-on; > + }; > + > + pm2250_l22: l22 { > + /* Wi-Fi */ > + regulator-min-microvolts = <3312000>; > + regulator-max-microvolts = <3312000>; > + }; > + }; > +}; > + > &sdhc_1 { > + vmmc-supply = <&pm2250_l20>; > + vqmmc-supply = <&pm2250_l14>; > pinctrl-0 = <&sdc1_state_on>; > pinctrl-1 = <&sdc1_state_off>; > pinctrl-names = "default", "sleep"; > @@ -61,6 +322,8 @@ &sdhc_1 { > }; > > &sdhc_2 { > + vmmc-supply = <&pm2250_l21>; > + vqmmc-supply = <&pm2250_l4>; > cd-gpios = <&tlmm 88 GPIO_ACTIVE_LOW>; > pinctrl-0 = <&sdc2_state_on &sd_det_in_on>; > pinctrl-1 = <&sdc2_state_off &sd_det_in_off>; > @@ -104,6 +367,9 @@ &usb { > }; > > &usb_hsphy { > + vdd-supply = <&pm2250_l12>; > + vdda-pll-supply = <&pm2250_l13>; > + vdda-phy-dpdm-supply = <&pm2250_l21>; > status = "okay"; > }; > > > --- > base-commit: 8e4b7f2f3d6071665b1dfd70786229c8a5d6c256 > change-id: 20230711-topic-rb1_regulator-44c4ade93246 > > Best regards, > -- > Konrad Dybcio <konrad.dybcio@linaro.org> >
On 11.07.2023 12:44, Dmitry Baryshkov wrote: > On Tue, 11 Jul 2023 at 13:28, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: >> >> Add and assign RPM regulators coming from PM2250. >> >> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> >> --- [...] >> + pm2250_l5: l5 { >> + /* CSI/DSI */ >> + regulator-min-microvolts = <1232000>; >> + regulator-max-microvolts = <1232000>; >> + regulator-allow-set-load; >> + regulator-boot-on; > > why? > To answer all of the questions in one go: "it's because the regulator is enabled at boot" Konrad >> + }; >> + >> + pm2250_l6: l6 { >> + /* DRAM PLL */ >> + regulator-min-microvolts = <928000>; >> + regulator-max-microvolts = <928000>; >> + regulator-always-on; >> + regulator-boot-on; >> + }; >> + >> + pm2250_l7: l7 { >> + /* Wi-Fi CX/MX */ >> + regulator-min-microvolts = <664000>; >> + regulator-max-microvolts = <664000>; >> + }; >> + >> + /* >> + * L8 - VDD_LPI_CX >> + * L9 - VDD_LPI_MX >> + */ >> + >> + pm2250_l10: l10 { >> + /* Wi-Fi RFA */ >> + regulator-min-microvolts = <1300000>; >> + regulator-max-microvolts = <1300000>; >> + }; >> + >> + pm2250_l11: l11 { >> + /* GPS RF1 */ >> + regulator-min-microvolts = <1000000>; >> + regulator-max-microvolts = <1000000>; >> + regulator-boot-on; > > Shouldn't it be handled by the modem on its own? > >> + }; >> + >> + pm2250_l12: l12 { >> + /* USB PHYs */ >> + regulator-min-microvolts = <928000>; >> + regulator-max-microvolts = <928000>; >> + regulator-allow-set-load; >> + regulator-boot-on; > > You guess the question (and further on) > >> + }; >> + >> + pm2250_l13: l13 { >> + /* USB/QFPROM/PLLs */ >> + regulator-min-microvolts = <1800000>; >> + regulator-max-microvolts = <1800000>; >> + regulator-allow-set-load; >> + regulator-boot-on; >> + }; >> + >> + pm2250_l14: l14 { >> + /* SDHCI1 VQMMC */ >> + regulator-min-microvolts = <1800000>; >> + regulator-max-microvolts = <1800000>; >> + regulator-allow-set-load; >> + /* Broken hardware, never turn it off! */ >> + regulator-always-on; >> + }; >> + >> + pm2250_l15: l15 { >> + /* WCD/DSI/BT VDDIO */ >> + regulator-min-microvolts = <1800000>; >> + regulator-max-microvolts = <1800000>; >> + regulator-allow-set-load; >> + regulator-always-on; >> + regulator-boot-on; >> + }; >> + >> + pm2250_l16: l16 { >> + /* GPS RF2 */ >> + regulator-min-microvolts = <1800000>; >> + regulator-max-microvolts = <1800000>; >> + regulator-boot-on; >> + }; >> + >> + pm2250_l17: l17 { >> + regulator-min-microvolts = <3000000>; >> + regulator-max-microvolts = <3000000>; >> + }; >> + >> + pm2250_l18: l18 { >> + /* VDD_PXn */ >> + regulator-min-microvolts = <1800000>; >> + regulator-max-microvolts = <1800000>; >> + }; >> + >> + pm2250_l19: l19 { >> + /* VDD_PXn */ >> + regulator-min-microvolts = <1800000>; >> + regulator-max-microvolts = <1800000>; >> + }; >> + >> + pm2250_l20: l20 { >> + /* SDHCI1 VMMC */ >> + regulator-min-microvolts = <2856000>; >> + regulator-max-microvolts = <2856000>; >> + regulator-allow-set-load; >> + }; >> + >> + pm2250_l21: l21 { >> + /* SDHCI2 VMMC */ >> + regulator-min-microvolts = <2960000>; >> + regulator-max-microvolts = <3300000>; >> + regulator-allow-set-load; >> + regulator-boot-on; >> + }; >> + >> + pm2250_l22: l22 { >> + /* Wi-Fi */ >> + regulator-min-microvolts = <3312000>; >> + regulator-max-microvolts = <3312000>; >> + }; >> + }; >> +}; >> + >> &sdhc_1 { >> + vmmc-supply = <&pm2250_l20>; >> + vqmmc-supply = <&pm2250_l14>; >> pinctrl-0 = <&sdc1_state_on>; >> pinctrl-1 = <&sdc1_state_off>; >> pinctrl-names = "default", "sleep"; >> @@ -61,6 +322,8 @@ &sdhc_1 { >> }; >> >> &sdhc_2 { >> + vmmc-supply = <&pm2250_l21>; >> + vqmmc-supply = <&pm2250_l4>; >> cd-gpios = <&tlmm 88 GPIO_ACTIVE_LOW>; >> pinctrl-0 = <&sdc2_state_on &sd_det_in_on>; >> pinctrl-1 = <&sdc2_state_off &sd_det_in_off>; >> @@ -104,6 +367,9 @@ &usb { >> }; >> >> &usb_hsphy { >> + vdd-supply = <&pm2250_l12>; >> + vdda-pll-supply = <&pm2250_l13>; >> + vdda-phy-dpdm-supply = <&pm2250_l21>; >> status = "okay"; >> }; >> >> >> --- >> base-commit: 8e4b7f2f3d6071665b1dfd70786229c8a5d6c256 >> change-id: 20230711-topic-rb1_regulator-44c4ade93246 >> >> Best regards, >> -- >> Konrad Dybcio <konrad.dybcio@linaro.org> >> > >
On Tue, 11 Jul 2023 at 13:48, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > > On 11.07.2023 12:44, Dmitry Baryshkov wrote: > > On Tue, 11 Jul 2023 at 13:28, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > >> > >> Add and assign RPM regulators coming from PM2250. > >> > >> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> > >> --- > [...] > > >> + pm2250_l5: l5 { > >> + /* CSI/DSI */ > >> + regulator-min-microvolts = <1232000>; > >> + regulator-max-microvolts = <1232000>; > >> + regulator-allow-set-load; > >> + regulator-boot-on; > > > > why? > > > To answer all of the questions in one go: > > "it's because the regulator is enabled at boot" I was more concerned about the following part: If the bootloader didn't leave it on then OS should turn it on at boot ... Please remind me, are we declaring them as boot-on so that the regulator core can turn them off later if they are unused? > > Konrad > >> + }; > >> + > >> + pm2250_l6: l6 { > >> + /* DRAM PLL */ > >> + regulator-min-microvolts = <928000>; > >> + regulator-max-microvolts = <928000>; > >> + regulator-always-on; > >> + regulator-boot-on; > >> + }; > >> + > >> + pm2250_l7: l7 { > >> + /* Wi-Fi CX/MX */ > >> + regulator-min-microvolts = <664000>; > >> + regulator-max-microvolts = <664000>; > >> + }; > >> + > >> + /* > >> + * L8 - VDD_LPI_CX > >> + * L9 - VDD_LPI_MX > >> + */ > >> + > >> + pm2250_l10: l10 { > >> + /* Wi-Fi RFA */ > >> + regulator-min-microvolts = <1300000>; > >> + regulator-max-microvolts = <1300000>; > >> + }; > >> + > >> + pm2250_l11: l11 { > >> + /* GPS RF1 */ > >> + regulator-min-microvolts = <1000000>; > >> + regulator-max-microvolts = <1000000>; > >> + regulator-boot-on; > > > > Shouldn't it be handled by the modem on its own? > > > >> + }; > >> + > >> + pm2250_l12: l12 { > >> + /* USB PHYs */ > >> + regulator-min-microvolts = <928000>; > >> + regulator-max-microvolts = <928000>; > >> + regulator-allow-set-load; > >> + regulator-boot-on; > > > > You guess the question (and further on) > > > >> + }; > >> + > >> + pm2250_l13: l13 { > >> + /* USB/QFPROM/PLLs */ > >> + regulator-min-microvolts = <1800000>; > >> + regulator-max-microvolts = <1800000>; > >> + regulator-allow-set-load; > >> + regulator-boot-on; > >> + }; > >> + > >> + pm2250_l14: l14 { > >> + /* SDHCI1 VQMMC */ > >> + regulator-min-microvolts = <1800000>; > >> + regulator-max-microvolts = <1800000>; > >> + regulator-allow-set-load; > >> + /* Broken hardware, never turn it off! */ > >> + regulator-always-on; > >> + }; > >> + > >> + pm2250_l15: l15 { > >> + /* WCD/DSI/BT VDDIO */ > >> + regulator-min-microvolts = <1800000>; > >> + regulator-max-microvolts = <1800000>; > >> + regulator-allow-set-load; > >> + regulator-always-on; > >> + regulator-boot-on; > >> + }; > >> + > >> + pm2250_l16: l16 { > >> + /* GPS RF2 */ > >> + regulator-min-microvolts = <1800000>; > >> + regulator-max-microvolts = <1800000>; > >> + regulator-boot-on; > >> + }; > >> + > >> + pm2250_l17: l17 { > >> + regulator-min-microvolts = <3000000>; > >> + regulator-max-microvolts = <3000000>; > >> + }; > >> + > >> + pm2250_l18: l18 { > >> + /* VDD_PXn */ > >> + regulator-min-microvolts = <1800000>; > >> + regulator-max-microvolts = <1800000>; > >> + }; > >> + > >> + pm2250_l19: l19 { > >> + /* VDD_PXn */ > >> + regulator-min-microvolts = <1800000>; > >> + regulator-max-microvolts = <1800000>; > >> + }; > >> + > >> + pm2250_l20: l20 { > >> + /* SDHCI1 VMMC */ > >> + regulator-min-microvolts = <2856000>; > >> + regulator-max-microvolts = <2856000>; > >> + regulator-allow-set-load; > >> + }; > >> + > >> + pm2250_l21: l21 { > >> + /* SDHCI2 VMMC */ > >> + regulator-min-microvolts = <2960000>; > >> + regulator-max-microvolts = <3300000>; > >> + regulator-allow-set-load; > >> + regulator-boot-on; > >> + }; > >> + > >> + pm2250_l22: l22 { > >> + /* Wi-Fi */ > >> + regulator-min-microvolts = <3312000>; > >> + regulator-max-microvolts = <3312000>; > >> + }; > >> + }; > >> +}; > >> + > >> &sdhc_1 { > >> + vmmc-supply = <&pm2250_l20>; > >> + vqmmc-supply = <&pm2250_l14>; > >> pinctrl-0 = <&sdc1_state_on>; > >> pinctrl-1 = <&sdc1_state_off>; > >> pinctrl-names = "default", "sleep"; > >> @@ -61,6 +322,8 @@ &sdhc_1 { > >> }; > >> > >> &sdhc_2 { > >> + vmmc-supply = <&pm2250_l21>; > >> + vqmmc-supply = <&pm2250_l4>; > >> cd-gpios = <&tlmm 88 GPIO_ACTIVE_LOW>; > >> pinctrl-0 = <&sdc2_state_on &sd_det_in_on>; > >> pinctrl-1 = <&sdc2_state_off &sd_det_in_off>; > >> @@ -104,6 +367,9 @@ &usb { > >> }; > >> > >> &usb_hsphy { > >> + vdd-supply = <&pm2250_l12>; > >> + vdda-pll-supply = <&pm2250_l13>; > >> + vdda-phy-dpdm-supply = <&pm2250_l21>; > >> status = "okay"; > >> }; > >> > >> > >> --- > >> base-commit: 8e4b7f2f3d6071665b1dfd70786229c8a5d6c256 > >> change-id: 20230711-topic-rb1_regulator-44c4ade93246 > >> > >> Best regards, > >> -- > >> Konrad Dybcio <konrad.dybcio@linaro.org> > >> > > > >
On 11.07.2023 12:56, Dmitry Baryshkov wrote: > On Tue, 11 Jul 2023 at 13:48, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: >> >> On 11.07.2023 12:44, Dmitry Baryshkov wrote: >>> On Tue, 11 Jul 2023 at 13:28, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: >>>> >>>> Add and assign RPM regulators coming from PM2250. >>>> >>>> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> >>>> --- >> [...] >> >>>> + pm2250_l5: l5 { >>>> + /* CSI/DSI */ >>>> + regulator-min-microvolts = <1232000>; >>>> + regulator-max-microvolts = <1232000>; >>>> + regulator-allow-set-load; >>>> + regulator-boot-on; >>> >>> why? >>> >> To answer all of the questions in one go: >> >> "it's because the regulator is enabled at boot" > > I was more concerned about the following part: > If the bootloader didn't leave it on then OS should turn it on at boot ... > > Please remind me, are we declaring them as boot-on so that the > regulator core can turn them off later if they are unused? In the Linux implementation, yes. Konrad > >> >> Konrad >>>> + }; >>>> + >>>> + pm2250_l6: l6 { >>>> + /* DRAM PLL */ >>>> + regulator-min-microvolts = <928000>; >>>> + regulator-max-microvolts = <928000>; >>>> + regulator-always-on; >>>> + regulator-boot-on; >>>> + }; >>>> + >>>> + pm2250_l7: l7 { >>>> + /* Wi-Fi CX/MX */ >>>> + regulator-min-microvolts = <664000>; >>>> + regulator-max-microvolts = <664000>; >>>> + }; >>>> + >>>> + /* >>>> + * L8 - VDD_LPI_CX >>>> + * L9 - VDD_LPI_MX >>>> + */ >>>> + >>>> + pm2250_l10: l10 { >>>> + /* Wi-Fi RFA */ >>>> + regulator-min-microvolts = <1300000>; >>>> + regulator-max-microvolts = <1300000>; >>>> + }; >>>> + >>>> + pm2250_l11: l11 { >>>> + /* GPS RF1 */ >>>> + regulator-min-microvolts = <1000000>; >>>> + regulator-max-microvolts = <1000000>; >>>> + regulator-boot-on; >>> >>> Shouldn't it be handled by the modem on its own? >>> >>>> + }; >>>> + >>>> + pm2250_l12: l12 { >>>> + /* USB PHYs */ >>>> + regulator-min-microvolts = <928000>; >>>> + regulator-max-microvolts = <928000>; >>>> + regulator-allow-set-load; >>>> + regulator-boot-on; >>> >>> You guess the question (and further on) >>> >>>> + }; >>>> + >>>> + pm2250_l13: l13 { >>>> + /* USB/QFPROM/PLLs */ >>>> + regulator-min-microvolts = <1800000>; >>>> + regulator-max-microvolts = <1800000>; >>>> + regulator-allow-set-load; >>>> + regulator-boot-on; >>>> + }; >>>> + >>>> + pm2250_l14: l14 { >>>> + /* SDHCI1 VQMMC */ >>>> + regulator-min-microvolts = <1800000>; >>>> + regulator-max-microvolts = <1800000>; >>>> + regulator-allow-set-load; >>>> + /* Broken hardware, never turn it off! */ >>>> + regulator-always-on; >>>> + }; >>>> + >>>> + pm2250_l15: l15 { >>>> + /* WCD/DSI/BT VDDIO */ >>>> + regulator-min-microvolts = <1800000>; >>>> + regulator-max-microvolts = <1800000>; >>>> + regulator-allow-set-load; >>>> + regulator-always-on; >>>> + regulator-boot-on; >>>> + }; >>>> + >>>> + pm2250_l16: l16 { >>>> + /* GPS RF2 */ >>>> + regulator-min-microvolts = <1800000>; >>>> + regulator-max-microvolts = <1800000>; >>>> + regulator-boot-on; >>>> + }; >>>> + >>>> + pm2250_l17: l17 { >>>> + regulator-min-microvolts = <3000000>; >>>> + regulator-max-microvolts = <3000000>; >>>> + }; >>>> + >>>> + pm2250_l18: l18 { >>>> + /* VDD_PXn */ >>>> + regulator-min-microvolts = <1800000>; >>>> + regulator-max-microvolts = <1800000>; >>>> + }; >>>> + >>>> + pm2250_l19: l19 { >>>> + /* VDD_PXn */ >>>> + regulator-min-microvolts = <1800000>; >>>> + regulator-max-microvolts = <1800000>; >>>> + }; >>>> + >>>> + pm2250_l20: l20 { >>>> + /* SDHCI1 VMMC */ >>>> + regulator-min-microvolts = <2856000>; >>>> + regulator-max-microvolts = <2856000>; >>>> + regulator-allow-set-load; >>>> + }; >>>> + >>>> + pm2250_l21: l21 { >>>> + /* SDHCI2 VMMC */ >>>> + regulator-min-microvolts = <2960000>; >>>> + regulator-max-microvolts = <3300000>; >>>> + regulator-allow-set-load; >>>> + regulator-boot-on; >>>> + }; >>>> + >>>> + pm2250_l22: l22 { >>>> + /* Wi-Fi */ >>>> + regulator-min-microvolts = <3312000>; >>>> + regulator-max-microvolts = <3312000>; >>>> + }; >>>> + }; >>>> +}; >>>> + >>>> &sdhc_1 { >>>> + vmmc-supply = <&pm2250_l20>; >>>> + vqmmc-supply = <&pm2250_l14>; >>>> pinctrl-0 = <&sdc1_state_on>; >>>> pinctrl-1 = <&sdc1_state_off>; >>>> pinctrl-names = "default", "sleep"; >>>> @@ -61,6 +322,8 @@ &sdhc_1 { >>>> }; >>>> >>>> &sdhc_2 { >>>> + vmmc-supply = <&pm2250_l21>; >>>> + vqmmc-supply = <&pm2250_l4>; >>>> cd-gpios = <&tlmm 88 GPIO_ACTIVE_LOW>; >>>> pinctrl-0 = <&sdc2_state_on &sd_det_in_on>; >>>> pinctrl-1 = <&sdc2_state_off &sd_det_in_off>; >>>> @@ -104,6 +367,9 @@ &usb { >>>> }; >>>> >>>> &usb_hsphy { >>>> + vdd-supply = <&pm2250_l12>; >>>> + vdda-pll-supply = <&pm2250_l13>; >>>> + vdda-phy-dpdm-supply = <&pm2250_l21>; >>>> status = "okay"; >>>> }; >>>> >>>> >>>> --- >>>> base-commit: 8e4b7f2f3d6071665b1dfd70786229c8a5d6c256 >>>> change-id: 20230711-topic-rb1_regulator-44c4ade93246 >>>> >>>> Best regards, >>>> -- >>>> Konrad Dybcio <konrad.dybcio@linaro.org> >>>> >>> >>> > > >
On Tue, 11 Jul 2023 at 14:41, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > > On 11.07.2023 12:56, Dmitry Baryshkov wrote: > > On Tue, 11 Jul 2023 at 13:48, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > >> > >> On 11.07.2023 12:44, Dmitry Baryshkov wrote: > >>> On Tue, 11 Jul 2023 at 13:28, Konrad Dybcio <konrad.dybcio@linaro.org> wrote: > >>>> > >>>> Add and assign RPM regulators coming from PM2250. > >>>> > >>>> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org> > >>>> --- > >> [...] > >> > >>>> + pm2250_l5: l5 { > >>>> + /* CSI/DSI */ > >>>> + regulator-min-microvolts = <1232000>; > >>>> + regulator-max-microvolts = <1232000>; > >>>> + regulator-allow-set-load; > >>>> + regulator-boot-on; > >>> > >>> why? > >>> > >> To answer all of the questions in one go: > >> > >> "it's because the regulator is enabled at boot" > > > > I was more concerned about the following part: > > If the bootloader didn't leave it on then OS should turn it on at boot ... > > > > Please remind me, are we declaring them as boot-on so that the > > regulator core can turn them off later if they are unused? > In the Linux implementation, yes. Ack. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> > > Konrad > > > >> > >> Konrad > >>>> + }; > >>>> + > >>>> + pm2250_l6: l6 { > >>>> + /* DRAM PLL */ > >>>> + regulator-min-microvolts = <928000>; > >>>> + regulator-max-microvolts = <928000>; > >>>> + regulator-always-on; > >>>> + regulator-boot-on; > >>>> + }; > >>>> + > >>>> + pm2250_l7: l7 { > >>>> + /* Wi-Fi CX/MX */ > >>>> + regulator-min-microvolts = <664000>; > >>>> + regulator-max-microvolts = <664000>; > >>>> + }; > >>>> + > >>>> + /* > >>>> + * L8 - VDD_LPI_CX > >>>> + * L9 - VDD_LPI_MX > >>>> + */ > >>>> + > >>>> + pm2250_l10: l10 { > >>>> + /* Wi-Fi RFA */ > >>>> + regulator-min-microvolts = <1300000>; > >>>> + regulator-max-microvolts = <1300000>; > >>>> + }; > >>>> + > >>>> + pm2250_l11: l11 { > >>>> + /* GPS RF1 */ > >>>> + regulator-min-microvolts = <1000000>; > >>>> + regulator-max-microvolts = <1000000>; > >>>> + regulator-boot-on; > >>> > >>> Shouldn't it be handled by the modem on its own? > >>> > >>>> + }; > >>>> + > >>>> + pm2250_l12: l12 { > >>>> + /* USB PHYs */ > >>>> + regulator-min-microvolts = <928000>; > >>>> + regulator-max-microvolts = <928000>; > >>>> + regulator-allow-set-load; > >>>> + regulator-boot-on; > >>> > >>> You guess the question (and further on) > >>> > >>>> + }; > >>>> + > >>>> + pm2250_l13: l13 { > >>>> + /* USB/QFPROM/PLLs */ > >>>> + regulator-min-microvolts = <1800000>; > >>>> + regulator-max-microvolts = <1800000>; > >>>> + regulator-allow-set-load; > >>>> + regulator-boot-on; > >>>> + }; > >>>> + > >>>> + pm2250_l14: l14 { > >>>> + /* SDHCI1 VQMMC */ > >>>> + regulator-min-microvolts = <1800000>; > >>>> + regulator-max-microvolts = <1800000>; > >>>> + regulator-allow-set-load; > >>>> + /* Broken hardware, never turn it off! */ > >>>> + regulator-always-on; > >>>> + }; > >>>> + > >>>> + pm2250_l15: l15 { > >>>> + /* WCD/DSI/BT VDDIO */ > >>>> + regulator-min-microvolts = <1800000>; > >>>> + regulator-max-microvolts = <1800000>; > >>>> + regulator-allow-set-load; > >>>> + regulator-always-on; > >>>> + regulator-boot-on; > >>>> + }; > >>>> + > >>>> + pm2250_l16: l16 { > >>>> + /* GPS RF2 */ > >>>> + regulator-min-microvolts = <1800000>; > >>>> + regulator-max-microvolts = <1800000>; > >>>> + regulator-boot-on; > >>>> + }; > >>>> + > >>>> + pm2250_l17: l17 { > >>>> + regulator-min-microvolts = <3000000>; > >>>> + regulator-max-microvolts = <3000000>; > >>>> + }; > >>>> + > >>>> + pm2250_l18: l18 { > >>>> + /* VDD_PXn */ > >>>> + regulator-min-microvolts = <1800000>; > >>>> + regulator-max-microvolts = <1800000>; > >>>> + }; > >>>> + > >>>> + pm2250_l19: l19 { > >>>> + /* VDD_PXn */ > >>>> + regulator-min-microvolts = <1800000>; > >>>> + regulator-max-microvolts = <1800000>; > >>>> + }; > >>>> + > >>>> + pm2250_l20: l20 { > >>>> + /* SDHCI1 VMMC */ > >>>> + regulator-min-microvolts = <2856000>; > >>>> + regulator-max-microvolts = <2856000>; > >>>> + regulator-allow-set-load; > >>>> + }; > >>>> + > >>>> + pm2250_l21: l21 { > >>>> + /* SDHCI2 VMMC */ > >>>> + regulator-min-microvolts = <2960000>; > >>>> + regulator-max-microvolts = <3300000>; > >>>> + regulator-allow-set-load; > >>>> + regulator-boot-on; > >>>> + }; > >>>> + > >>>> + pm2250_l22: l22 { > >>>> + /* Wi-Fi */ > >>>> + regulator-min-microvolts = <3312000>; > >>>> + regulator-max-microvolts = <3312000>; > >>>> + }; > >>>> + }; > >>>> +}; > >>>> + > >>>> &sdhc_1 { > >>>> + vmmc-supply = <&pm2250_l20>; > >>>> + vqmmc-supply = <&pm2250_l14>; > >>>> pinctrl-0 = <&sdc1_state_on>; > >>>> pinctrl-1 = <&sdc1_state_off>; > >>>> pinctrl-names = "default", "sleep"; > >>>> @@ -61,6 +322,8 @@ &sdhc_1 { > >>>> }; > >>>> > >>>> &sdhc_2 { > >>>> + vmmc-supply = <&pm2250_l21>; > >>>> + vqmmc-supply = <&pm2250_l4>; > >>>> cd-gpios = <&tlmm 88 GPIO_ACTIVE_LOW>; > >>>> pinctrl-0 = <&sdc2_state_on &sd_det_in_on>; > >>>> pinctrl-1 = <&sdc2_state_off &sd_det_in_off>; > >>>> @@ -104,6 +367,9 @@ &usb { > >>>> }; > >>>> > >>>> &usb_hsphy { > >>>> + vdd-supply = <&pm2250_l12>; > >>>> + vdda-pll-supply = <&pm2250_l13>; > >>>> + vdda-phy-dpdm-supply = <&pm2250_l21>; > >>>> status = "okay"; > >>>> }; > >>>> > >>>> > >>>> --- > >>>> base-commit: 8e4b7f2f3d6071665b1dfd70786229c8a5d6c256 > >>>> change-id: 20230711-topic-rb1_regulator-44c4ade93246 > >>>> > >>>> Best regards, > >>>> -- > >>>> Konrad Dybcio <konrad.dybcio@linaro.org> > >>>> > >>> > >>> > > > > > >
On Tue, 11 Jul 2023 12:28:17 +0200, Konrad Dybcio wrote: > Add and assign RPM regulators coming from PM2250. > > Applied, thanks! [1/1] arm64: dts: qcom: qrb2210-rb1: Add regulators commit: b4fe47d12f1f8ee82ab18803d1ab074ff3d4b368 Best regards,
diff --git a/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts b/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts index ef3616093289..eadba066972e 100644 --- a/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts +++ b/arch/arm64/boot/dts/qcom/qrb2210-rb1.dts @@ -38,6 +38,91 @@ key-volume-up { wakeup-source; }; }; + + vreg_hdmi_out_1p2: regulator-hdmi-out-1p2 { + compatible = "regulator-fixed"; + regulator-name = "VREG_HDMI_OUT_1P2"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1200000>; + vin-supply = <&vdc_1v2>; + regulator-always-on; + regulator-boot-on; + }; + + lt9611_3v3: regulator-lt9611-3v3 { + compatible = "regulator-fixed"; + regulator-name = "LT9611_3V3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vdc_3v3>; + regulator-always-on; + regulator-boot-on; + }; + + /* Main barrel jack input */ + vdc_12v: regulator-vdc-12v { + compatible = "regulator-fixed"; + regulator-name = "DC_12V"; + regulator-min-microvolt = <12000000>; + regulator-max-microvolt = <12000000>; + regulator-always-on; + regulator-boot-on; + }; + + /* 1.2V supply stepped down from the barrel jack input */ + vdc_1v2: regulator-vdc-1v2 { + compatible = "regulator-fixed"; + regulator-name = "VDC_1V2"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1200000>; + vin-supply = <&vdc_12v>; + regulator-always-on; + regulator-boot-on; + }; + + /* 3.3V supply stepped down from the barrel jack input */ + vdc_3v3: regulator-vdc-3v3 { + compatible = "regulator-fixed"; + regulator-name = "VDC_3V3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vdc_12v>; + regulator-always-on; + regulator-boot-on; + }; + + /* 5V supply stepped down from the barrel jack input */ + vdc_5v: regulator-vdc-5v { + compatible = "regulator-fixed"; + regulator-name = "VDC_5V"; + + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + }; + + /* "Battery" voltage for the SoM, stepped down from the barrel jack input */ + vdc_vbat_som: regulator-vdc-vbat { + compatible = "regulator-fixed"; + regulator-name = "VBAT_SOM"; + regulator-min-microvolt = <4200000>; + regulator-max-microvolt = <4200000>; + regulator-always-on; + regulator-boot-on; + }; + + /* PM2250 charger out, supplied by VBAT */ + vph_pwr: regulator-vph-pwr { + compatible = "regulator-fixed"; + regulator-name = "vph_pwr"; + regulator-min-microvolt = <3700000>; + regulator-max-microvolt = <3700000>; + vin-supply = <&vdc_vbat_som>; + + regulator-always-on; + regulator-boot-on; + }; }; &pm2250_resin { @@ -49,7 +134,183 @@ &qupv3_id_0 { status = "okay"; }; +&rpm_requests { + regulators { + compatible = "qcom,rpm-pm2250-regulators"; + vdd_s3-supply = <&vph_pwr>; + vdd_s4-supply = <&vph_pwr>; + vdd_l1_l2_l3_l5_l6_l7_l8_l9_l10_l11_l12-supply = <&pm2250_s3>; + vdd_l4_l17_l18_l19_l20_l21_l22-supply = <&vph_pwr>; + vdd_l13_l14_l15_l16-supply = <&pm2250_s4>; + + /* + * S1 - VDD_APC + * S2 - VDD_CX + */ + + pm2250_s3: s3 { + /* 0.4V-1.6625V -> 1.3V (Power tree requirements) */ + regulator-min-microvolts = <1350000>; + regulator-max-microvolts = <1350000>; + regulator-boot-on; + }; + + pm2250_s4: s4 { + /* 1.2V-2.35V -> 2.05V (Power tree requirements) */ + regulator-min-microvolts = <2072000>; + regulator-max-microvolts = <2072000>; + regulator-boot-on; + }; + + /* L1 - VDD_MX */ + + pm2250_l2: l2 { + /* LPDDR4X VDD2 */ + regulator-min-microvolts = <1136000>; + regulator-max-microvolts = <1136000>; + regulator-always-on; + regulator-boot-on; + }; + + pm2250_l3: l3 { + /* LPDDR4X VDDQ */ + regulator-min-microvolts = <616000>; + regulator-max-microvolts = <616000>; + regulator-always-on; + regulator-boot-on; + }; + + pm2250_l4: l4 { + /* max = 3.05V -> max = just below 3V (SDHCI2) */ + regulator-min-microvolts = <1648000>; + regulator-max-microvolts = <2992000>; + regulator-allow-set-load; + }; + + pm2250_l5: l5 { + /* CSI/DSI */ + regulator-min-microvolts = <1232000>; + regulator-max-microvolts = <1232000>; + regulator-allow-set-load; + regulator-boot-on; + }; + + pm2250_l6: l6 { + /* DRAM PLL */ + regulator-min-microvolts = <928000>; + regulator-max-microvolts = <928000>; + regulator-always-on; + regulator-boot-on; + }; + + pm2250_l7: l7 { + /* Wi-Fi CX/MX */ + regulator-min-microvolts = <664000>; + regulator-max-microvolts = <664000>; + }; + + /* + * L8 - VDD_LPI_CX + * L9 - VDD_LPI_MX + */ + + pm2250_l10: l10 { + /* Wi-Fi RFA */ + regulator-min-microvolts = <1300000>; + regulator-max-microvolts = <1300000>; + }; + + pm2250_l11: l11 { + /* GPS RF1 */ + regulator-min-microvolts = <1000000>; + regulator-max-microvolts = <1000000>; + regulator-boot-on; + }; + + pm2250_l12: l12 { + /* USB PHYs */ + regulator-min-microvolts = <928000>; + regulator-max-microvolts = <928000>; + regulator-allow-set-load; + regulator-boot-on; + }; + + pm2250_l13: l13 { + /* USB/QFPROM/PLLs */ + regulator-min-microvolts = <1800000>; + regulator-max-microvolts = <1800000>; + regulator-allow-set-load; + regulator-boot-on; + }; + + pm2250_l14: l14 { + /* SDHCI1 VQMMC */ + regulator-min-microvolts = <1800000>; + regulator-max-microvolts = <1800000>; + regulator-allow-set-load; + /* Broken hardware, never turn it off! */ + regulator-always-on; + }; + + pm2250_l15: l15 { + /* WCD/DSI/BT VDDIO */ + regulator-min-microvolts = <1800000>; + regulator-max-microvolts = <1800000>; + regulator-allow-set-load; + regulator-always-on; + regulator-boot-on; + }; + + pm2250_l16: l16 { + /* GPS RF2 */ + regulator-min-microvolts = <1800000>; + regulator-max-microvolts = <1800000>; + regulator-boot-on; + }; + + pm2250_l17: l17 { + regulator-min-microvolts = <3000000>; + regulator-max-microvolts = <3000000>; + }; + + pm2250_l18: l18 { + /* VDD_PXn */ + regulator-min-microvolts = <1800000>; + regulator-max-microvolts = <1800000>; + }; + + pm2250_l19: l19 { + /* VDD_PXn */ + regulator-min-microvolts = <1800000>; + regulator-max-microvolts = <1800000>; + }; + + pm2250_l20: l20 { + /* SDHCI1 VMMC */ + regulator-min-microvolts = <2856000>; + regulator-max-microvolts = <2856000>; + regulator-allow-set-load; + }; + + pm2250_l21: l21 { + /* SDHCI2 VMMC */ + regulator-min-microvolts = <2960000>; + regulator-max-microvolts = <3300000>; + regulator-allow-set-load; + regulator-boot-on; + }; + + pm2250_l22: l22 { + /* Wi-Fi */ + regulator-min-microvolts = <3312000>; + regulator-max-microvolts = <3312000>; + }; + }; +}; + &sdhc_1 { + vmmc-supply = <&pm2250_l20>; + vqmmc-supply = <&pm2250_l14>; pinctrl-0 = <&sdc1_state_on>; pinctrl-1 = <&sdc1_state_off>; pinctrl-names = "default", "sleep"; @@ -61,6 +322,8 @@ &sdhc_1 { }; &sdhc_2 { + vmmc-supply = <&pm2250_l21>; + vqmmc-supply = <&pm2250_l4>; cd-gpios = <&tlmm 88 GPIO_ACTIVE_LOW>; pinctrl-0 = <&sdc2_state_on &sd_det_in_on>; pinctrl-1 = <&sdc2_state_off &sd_det_in_off>; @@ -104,6 +367,9 @@ &usb { }; &usb_hsphy { + vdd-supply = <&pm2250_l12>; + vdda-pll-supply = <&pm2250_l13>; + vdda-phy-dpdm-supply = <&pm2250_l21>; status = "okay"; };