From patchwork Tue Dec 19 16:04:27 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Caleb Connolly X-Patchwork-Id: 755935 Delivered-To: patch@linaro.org Received: by 2002:adf:b181:0:b0:336:6142:bf13 with SMTP id q1csp1502899wra; Tue, 19 Dec 2023 08:09:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IE993D98hD5B0Y5pZtZ0FBMIDvUGRzwnPeEFFeOB6T+3XLuUJmzh0GUtVMxhNOgYjRA55NZ X-Received: by 2002:a7b:cbcb:0:b0:40c:34b1:b98d with SMTP id n11-20020a7bcbcb000000b0040c34b1b98dmr9469198wmi.96.1703002164010; Tue, 19 Dec 2023 08:09:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703002163; cv=none; d=google.com; s=arc-20160816; b=YgNbhE3uXjjIoox3RTqZcaZnArq7Tzznli2Lp7LH9vGjifB9I9ss9i7Wyjld8c/e5v oDErVfht3Qj/zqMfD+8UCgUnpzHS1BcoqGFMEOJS8tbF9wb1krsY8bxi7H+17YjkCKdc QwSHYDc7Y2tTMj9VAZRZkZHaXOdQNOSYqX7gKmCgPcaDp4RwAnVc7fxgS5SgRgW/eukT H/m100EWZWOO3dT8S9uFgEoorl0sjASiRmmHqhSxzZATJhBmFNarMEabiEq3UcgFRHkI D0WWxJGqkjJUeGDJxfQFWtdGGrfRiCML28h2DgAhViZVIYW2Rw3rEfDaXzxokjG1BcNl JXIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:cc:to:in-reply-to:references :message-id:content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=PZkW2+cAyClkWCHJCesNA+B/BKkYS4ezL45ZoOGJSX0=; fh=GB9E9KzRIiNXhkRWIZbZpSMjbCjxnqnvE8nYuQxq8UI=; b=LWW9yY4t9YoP7Kdi+Gxz6rW2vE0NqZgBbgDSk6/fc1YET7O33PVCbS3i6EWC+CSBDv Wxed1LKraEdE6xcep/vZIxDIUiOwnXHP1ywBeBGATjaKuboIkadm7xacSghmPwCtA7+5 lbR2qzVdqdEqRcot8XvKMj5t4K6GBOggCaj7d8vUnuBq55UPAlqNoYw58ZcfPlxtBuj6 kdHQvfrIZZIVGPgmje7KL5F8jpPdZtCkNsxQpTFeSLdGm7/Qwyfr4vQP93jyPIa//RRo YFM1gAJR5eONZjKWnd58nlD+dWPMJY0azbOR33e9QX7vZ6q2TGN12jBxOJdCPDaSxVYE PUJQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=m5TY9pF4; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id 23-20020a05600c025700b0040b563515ffsi925070wmj.8.2023.12.19.08.09.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Dec 2023 08:09:23 -0800 (PST) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=m5TY9pF4; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 6E90E878CF; Tue, 19 Dec 2023 17:05:25 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="m5TY9pF4"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 47DC48784A; Tue, 19 Dec 2023 17:05:18 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 07ABD87705 for ; Tue, 19 Dec 2023 17:04:50 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=caleb.connolly@linaro.org Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-40c39ef63d9so51891545e9.3 for ; Tue, 19 Dec 2023 08:04:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703001889; x=1703606689; darn=lists.denx.de; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=PZkW2+cAyClkWCHJCesNA+B/BKkYS4ezL45ZoOGJSX0=; b=m5TY9pF425U0uWmaOVWAeALFy13QO8jXKazmhprL2ix5cJBRtKoS/7SrEf8mmVNbKp 3WW7CzEDFmxkAl/bABjW2o8P4KLUFTO8QozftDSyHWyane0sYobjZx47f9TRl9s3nG2s 5sc51vSXGdiRVXYKrZ+9+gVIiHU7i9EJKcUuqoGQGTvzXZ1JVpaF4WetsmKL7/lMuZDY jtEKF5lvjMCiSMNIoAr2oSNmIENpWgbiaWELEz2ukKKgjW1+vLZZmZ/hBO3tgR3/1oiv x6sSVxrgF/DCGFp3bCtAyElZ3QZ9ZrxDlkGQBeybgouQaD4/bTGS0G4dEalhpvLWAIh+ 6jFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703001889; x=1703606689; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PZkW2+cAyClkWCHJCesNA+B/BKkYS4ezL45ZoOGJSX0=; b=RZFRzO/R3JvxNrd7ZrFDWF8kveRFGVZi2WTcZl+uMTfaq4H2j8JozpqMhDlrbYqTNp FDv2jVw+6TlaY7x70QXarVPKDohUGjMsFIGv42kIuBGbh6RxxiUFbTyL4AWe+Wc+VRJR n/8xjl0Cmg1MBfpK11Bc/Vb5Rt2RHJrOV+PgmWA+dg9qOxf72S7JAkFuGAxf3mhomqcE 9z6UOMI+h62X67kypo9lnNvjkvCv9asNdkRKNwrTE1cyjBeFkTf74qBadyQAK8PGpdJG K/bAVy2fGzTGG6McrtVBdtKJVOM3gKZe2xHkm3CfSmqbVydzVDiSU068bIHEVDMbTVuB WqLQ== X-Gm-Message-State: AOJu0YyfiR/XFtlY6mzj7WOm/q4nS6lwA15Bz65FszlwPBCxUZm9wrWs FoBOD4n1PE4VEpiZ2RNcGhAasg== X-Received: by 2002:a05:600c:519b:b0:40c:6de5:7613 with SMTP id fa27-20020a05600c519b00b0040c6de57613mr3783827wmb.173.1703001889596; Tue, 19 Dec 2023 08:04:49 -0800 (PST) Received: from lion.localdomain (host-92-17-96-230.as13285.net. [92.17.96.230]) by smtp.gmail.com with ESMTPSA id je17-20020a05600c1f9100b0040d1450ca7esm3429723wmb.7.2023.12.19.08.04.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Dec 2023 08:04:49 -0800 (PST) From: Caleb Connolly Date: Tue, 19 Dec 2023 16:04:27 +0000 Subject: [PATCH v2 26/32] dts: msm8996: import PMIC dtsi files MIME-Version: 1.0 Message-Id: <20231219-b4-qcom-common-target-v2-26-b6dd9704219e@linaro.org> References: <20231219-b4-qcom-common-target-v2-0-b6dd9704219e@linaro.org> In-Reply-To: <20231219-b4-qcom-common-target-v2-0-b6dd9704219e@linaro.org> To: Neil Armstrong , Sumit Garg , Ramon Fried , Dzmitry Sankouski , Caleb Connolly , Peng Fan , Jaehoon Chung , Rayagonda Kokatanur , Lukasz Majewski , Sean Anderson , Jorge Ramirez-Ortiz , Stephan Gerhold Cc: Marek Vasut , u-boot@lists.denx.de X-Mailer: b4 0.13-dev-4bd13 X-Developer-Signature: v=1; a=openpgp-sha256; l=5790; i=caleb.connolly@linaro.org; h=from:subject:message-id; bh=FSnie/BOv8k0n4xvFNwLCSICswUrpxIYKwtYdqTYdLg=; b=owGbwMvMwCFYaeA6f6eBkTjjabUkhtTG/SxsT3dwM4WZTs+yCFSe28uX39idvjYq5VoYG3NU5 Opzujc7SlkYBDkYZMUUWcRPLLNsWnvZXmP7ggswc1iZQIYwcHEKwEQytzL8M9L97BtkrlwfszI8 6VNA6mKl5IhXxteWJ/892/3b+YGaPCPDMrmAXfFdzNU+9Spvztn8q/EwVBG+cmM970SXkJIbHHG aAA== X-Developer-Key: i=caleb.connolly@linaro.org; a=openpgp; fpr=83B24DA7FE145076BC38BB250CD904EB673A7C47 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean Import PM8994 and PMI8994 DTSI files in preparation for switching MSM8996 boards to upstream DTS. Signed-off-by: Caleb Connolly Reviewed-by: Neil Armstrong --- arch/arm/dts/pm8994.dtsi | 152 ++++++++++++++++++++++++++++++++++++++++++++++ arch/arm/dts/pmi8994.dtsi | 65 ++++++++++++++++++++ 2 files changed, 217 insertions(+) diff --git a/arch/arm/dts/pm8994.dtsi b/arch/arm/dts/pm8994.dtsi new file mode 100644 index 000000000000..672094c8ca58 --- /dev/null +++ b/arch/arm/dts/pm8994.dtsi @@ -0,0 +1,152 @@ +// SPDX-License-Identifier: GPL-2.0 +#include +#include +#include +#include + +/ { + thermal-zones { + pm8994-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + + thermal-sensors = <&pm8994_temp>; + + trips { + pm8994_alert0: pm8994-alert0 { + temperature = <95000>; + hysteresis = <2000>; + type = "passive"; + }; + pm8994_crit: pm8994-crit { + temperature = <125000>; + hysteresis = <2000>; + type = "critical"; + }; + }; + }; + }; +}; + +&spmi_bus { + + pmic@0 { + compatible = "qcom,pm8994", "qcom,spmi-pmic"; + reg = <0x0 SPMI_USID>; + #address-cells = <1>; + #size-cells = <0>; + + rtc@6000 { + compatible = "qcom,pm8941-rtc"; + reg = <0x6000>, <0x6100>; + reg-names = "rtc", "alarm"; + interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>; + }; + + pm8994_pon: pon@800 { + compatible = "qcom,pm8916-pon"; + reg = <0x800>; + mode-bootloader = <0x2>; + mode-recovery = <0x1>; + + pwrkey { + compatible = "qcom,pm8941-pwrkey"; + interrupts = <0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>; + debounce = <15625>; + bias-pull-up; + linux,code = ; + }; + + pm8994_resin: resin { + compatible = "qcom,pm8941-resin"; + interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>; + debounce = <15625>; + bias-pull-up; + status = "disabled"; + }; + }; + + pm8994_temp: temp-alarm@2400 { + compatible = "qcom,spmi-temp-alarm"; + reg = <0x2400>; + interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_RISING>; + io-channels = <&pm8994_vadc VADC_DIE_TEMP>; + io-channel-names = "thermal"; + #thermal-sensor-cells = <0>; + }; + + pm8994_vadc: adc@3100 { + compatible = "qcom,spmi-vadc"; + reg = <0x3100>; + interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>; + #address-cells = <1>; + #size-cells = <0>; + #io-channel-cells = <1>; + + adc-chan@7 { + reg = ; + qcom,pre-scaling = <1 3>; + label = "vph_pwr"; + }; + adc-chan@8 { + reg = ; + label = "die_temp"; + }; + adc-chan@9 { + reg = ; + label = "ref_625mv"; + }; + adc-chan@a { + reg = ; + label = "ref_1250mv"; + }; + adc-chan@e { + reg = ; + }; + adc-chan@f { + reg = ; + }; + }; + + pm8994_gpios: gpio@c000 { + compatible = "qcom,pm8994-gpio", "qcom,spmi-gpio"; + reg = <0xc000>; + gpio-controller; + gpio-ranges = <&pm8994_gpios 0 0 22>; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + pm8994_mpps: mpps@a000 { + compatible = "qcom,pm8994-mpp", "qcom,spmi-mpp"; + reg = <0xa000>; + gpio-controller; + #gpio-cells = <2>; + gpio-ranges = <&pm8994_mpps 0 0 8>; + interrupt-controller; + #interrupt-cells = <2>; + }; + }; + + pmic@1 { + compatible = "qcom,pm8994", "qcom,spmi-pmic"; + reg = <0x1 SPMI_USID>; + #address-cells = <1>; + #size-cells = <0>; + + pm8994_lpg: pwm { + compatible = "qcom,pm8994-lpg"; + + #address-cells = <1>; + #size-cells = <0>; + #pwm-cells = <2>; + + status = "disabled"; + }; + + pm8994_spmi_regulators: regulators { + compatible = "qcom,pm8994-regulators"; + }; + }; +}; diff --git a/arch/arm/dts/pmi8994.dtsi b/arch/arm/dts/pmi8994.dtsi new file mode 100644 index 000000000000..36d6a1fb553a --- /dev/null +++ b/arch/arm/dts/pmi8994.dtsi @@ -0,0 +1,65 @@ +// SPDX-License-Identifier: GPL-2.0 +#include +#include + +&spmi_bus { + + pmic@2 { + compatible = "qcom,pmi8994", "qcom,spmi-pmic"; + reg = <0x2 SPMI_USID>; + #address-cells = <1>; + #size-cells = <0>; + + pmi8994_gpios: gpio@c000 { + compatible = "qcom,pmi8994-gpio", "qcom,spmi-gpio"; + reg = <0xc000>; + gpio-controller; + gpio-ranges = <&pmi8994_gpios 0 0 10>; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + pmi8994_mpps: mpps@a000 { + compatible = "qcom,pmi8994-mpp", "qcom,spmi-mpp"; + reg = <0xa000>; + gpio-controller; + gpio-ranges = <&pmi8994_mpps 0 0 4>; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + }; + + pmic@3 { + compatible = "qcom,pmi8994", "qcom,spmi-pmic"; + reg = <0x3 SPMI_USID>; + #address-cells = <1>; + #size-cells = <0>; + + pmi8994_lpg: pwm { + compatible = "qcom,pmi8994-lpg"; + + #address-cells = <1>; + #size-cells = <0>; + #pwm-cells = <2>; + + status = "disabled"; + }; + + pmi8994_spmi_regulators: regulators { + compatible = "qcom,pmi8994-regulators"; + }; + + pmi8994_wled: wled@d800 { + compatible = "qcom,pmi8994-wled"; + reg = <0xd800>, <0xd900>; + interrupts = <0x3 0xd8 0x1 IRQ_TYPE_EDGE_RISING>, + <0x3 0xd8 0x2 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "ovp", "short"; + qcom,cabc; + qcom,external-pfet; + status = "disabled"; + }; + }; +};