Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp998811rdh; Fri, 27 Oct 2023 01:29:34 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFTPHQw8W9T2vPw5CzNtpKnuLmGOe+t3EDXiqDzNK6NIHyuobhFFayTDvwaeWQ9WoK+DsYT X-Received: by 2002:a25:ad20:0:b0:da0:3c34:2bf5 with SMTP id y32-20020a25ad20000000b00da03c342bf5mr1811003ybi.2.1698395374596; Fri, 27 Oct 2023 01:29:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698395374; cv=none; d=google.com; s=arc-20160816; b=V8XtAZi3b19EcuAOEgiXrSh3B3/YGhJLBL2yEnScw5Czei2YQVsHteaWfj7xsQalop 0ViCOA15GkVBoVgEvN7OCLY7a/Vqd+7vAlEpRGxZS1kGvUJ5PbvICKhGG1p4phULaq8Y 5XYmNJz3MUT5x4QbCDTvshIZtJT3hI0Rr2LHD15aNzf342oVAgXLQsf8lSB+jfjffi/V 9SXQFLrRpCDcQ2Tq7rWQBcAH//DQZWtQChMa9btOkC2IZt7q4HAWoVuEfSkP5Wp/yxAd Yno5nOyUn2vmGOAZdwwbNcAmMlx7hDJwepfU59KTjuh0dAO051INMBlmGketZA+8QwJQ 7zQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=Z11Gq9vTEOKpOY4/+uT4D5tUlHogBNSB+ox5FI0yyM4=; fh=a9Me1BKmgMakTa0gi1aBw13vjx49AikuqF0jLwSflqI=; b=A2VGVYyONTKMBVIb8s4rfzCTxWfp9BHOLegqnejuWBLJqnj/8tQiHGrY32+I9xq9Ci i8GpzBVfxpCGklan7/bPORcqfEZMHlwXyrCNykF9+vT7sEZb+WDQCUR0/FxI8Th+XPFd oDJoKloAtRfYFylDuPP1gSVZOF3lCy9eUVYibot+1X6O8Hc1DW2BWgDfKAyENyuvv6Ac 1xValpnDnIGshZ61JOeHSUuJN1m3NamNfvlFSl9evyukYsmfXH0oTfzjNEBUgmchujB8 k1unHuQSCN3bdFGoZ+99xaGD7nRwtnCslgy6y+2YODv9TLl3bnWFFzsAGj7G//7UjZmb rYCA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=fRYlL2+i; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id t78-20020a25aad4000000b00d9acd9b2088si1857971ybi.620.2023.10.27.01.29.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 Oct 2023 01:29:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=fRYlL2+i; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 9B8AC82ACAF4; Fri, 27 Oct 2023 01:29:30 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345512AbjJ0I3T (ORCPT + 99 others); Fri, 27 Oct 2023 04:29:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345502AbjJ0I3R (ORCPT ); Fri, 27 Oct 2023 04:29:17 -0400 Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C50A6196; Fri, 27 Oct 2023 01:29:14 -0700 (PDT) Received: by mail.gandi.net (Postfix) with ESMTPSA id 1AEDDE000D; Fri, 27 Oct 2023 08:29:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1698395353; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=Z11Gq9vTEOKpOY4/+uT4D5tUlHogBNSB+ox5FI0yyM4=; b=fRYlL2+i4k0d0AdJ263haEskeTBUYD1XMeQf18Ha5v1ez1RJEaHIejM1TWONSQal0tsXob MpEKlqZADXxyn822XQsKQiwfINCd9dssXwE/R9X7XCRg1Wqx4u8u62R/89GZaXjSuu6o/M LkgdMigSYOwsNc7jiSLw+AFlFSi4nvZ+uvdMTuD/oCw4opCbILlkoBFMh8VKBiclyo7Veq CHEb6QtF6FdCx2ewK7QPtq0z78qN2Wz0Hwy3icjJNZvn0XZI7m4xqQqjt7Db1iZmg9lTpf efxFvpu2kaXH24hGa3/8as638+I9vzcv7qYXTcvgIsHzh50FrS/dvQq9nsndSQ== From: Thomas Richard To: nm@ti.com, vigneshr@ti.com, kristo@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, gregory.clement@bootlin.com, thomas.petazzoni@bootlin.com, u-kumar1@ti.com, Esteban Blanc , Jai Luthra , Thomas Richard Subject: [PATCH] arm64: dts: ti: k3-j7200-som-p0: Add TP6594 family PMICs Date: Fri, 27 Oct 2023 10:28:52 +0200 Message-Id: <20231027082852.2922552-1-thomas.richard@bootlin.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-GND-Sasl: thomas.richard@bootlin.com 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 autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.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 (fry.vger.email [0.0.0.0]); Fri, 27 Oct 2023 01:29:31 -0700 (PDT) From: Esteban Blanc This patch adds support for TPS6594 PMIC family on wakup I2C0 bus. Theses devices provides regulators (bucks and LDOs), but also GPIOs, a RTC, a watchdog, an ESM (Error Signal Monitor) which monitors the SoC error output signal, and a PFSM (Pre-configurable Finite State Machine) which manages the operational modes of the PMIC. Signed-off-by: Esteban Blanc Signed-off-by: Jai Luthra Signed-off-by: Thomas Richard --- Notes: This patch was picked from: https://lore.kernel.org/all/20230810-tps6594-v6-0-2b2e2399e2ef@ti.com/ I reviewed it, and checked that there is no issue during the boot. arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi | 157 ++++++++++++++++++++ 1 file changed, 157 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi b/arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi index 5a300d4c8ba0..f23b37293c8b 100644 --- a/arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi +++ b/arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi @@ -127,6 +127,14 @@ J721E_WKUP_IOPAD(0x9c, PIN_INPUT_PULLUP, 0) /* (H21) WKUP_I2C0_SDA */ }; }; +&wkup_pmx3 { + pmic_irq_pins_default: pmic-irq-default-pins { + pinctrl-single,pins = < + J721E_WKUP_IOPAD(0x01c, PIN_INPUT, 7) /* (E18) WKUP_GPIO0_84 */ + >; + }; +}; + &main_pmx0 { main_i2c0_pins_default: main-i2c0-default-pins { pinctrl-single,pins = < @@ -264,6 +272,155 @@ eeprom@50 { compatible = "atmel,24c256"; reg = <0x50>; }; + + tps659414: pmic@48 { + compatible = "ti,tps6594-q1"; + reg = <0x48>; + ti,primary-pmic; + system-power-controller; + + pinctrl-names = "default"; + pinctrl-0 = <&pmic_irq_pins_default>; + interrupt-parent = <&wkup_gpio0>; + interrupts = <84 IRQ_TYPE_EDGE_FALLING>; + + gpio-controller; + #gpio-cells = <2>; + + buck1-supply = <&vsys_3v3>; + buck2-supply = <&vsys_3v3>; + buck3-supply = <&vsys_3v3>; + buck4-supply = <&vsys_3v3>; + buck5-supply = <&vsys_3v3>; + ldo1-supply = <&vsys_3v3>; + ldo2-supply = <&vsys_3v3>; + ldo3-supply = <&vsys_3v3>; + ldo4-supply = <&vsys_3v3>; + + regulators { + bucka1: buck1 { + regulator-name = "vda_mcu_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + bucka2: buck2 { + regulator-name = "vdd_mcuio_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + bucka3: buck3 { + regulator-name = "vdd_mcu_0v85"; + regulator-min-microvolt = <850000>; + regulator-max-microvolt = <850000>; + regulator-boot-on; + regulator-always-on; + }; + + bucka4: buck4 { + regulator-name = "vdd_ddr_1v1"; + regulator-min-microvolt = <1100000>; + regulator-max-microvolt = <1100000>; + regulator-boot-on; + regulator-always-on; + }; + + bucka5: buck5 { + regulator-name = "vdd_phyio_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + ldoa1: ldo1 { + regulator-name = "vdd1_lpddr4_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + ldoa2: ldo2 { + regulator-name = "vda_dll_0v8"; + regulator-min-microvolt = <800000>; + regulator-max-microvolt = <800000>; + regulator-boot-on; + regulator-always-on; + }; + + ldoa3: ldo3 { + regulator-name = "vdd_wk_0v8"; + regulator-min-microvolt = <800000>; + regulator-max-microvolt = <800000>; + regulator-boot-on; + regulator-always-on; + }; + + ldoa4: ldo4 { + regulator-name = "vda_pll_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + }; + }; + + lp876441: pmic@4c { + compatible = "ti,lp8764-q1"; + reg = <0x4c>; + system-power-controller; + interrupt-parent = <&wkup_gpio0>; + interrupts = <84 IRQ_TYPE_EDGE_FALLING>; + + gpio-controller; + #gpio-cells = <2>; + + buck1-supply = <&vsys_3v3>; + buck2-supply = <&vsys_3v3>; + buck3-supply = <&vsys_3v3>; + buck4-supply = <&vsys_3v3>; + + regulators: regulators { + buckb1: buck1 { + regulator-name = "vdd_cpu_avs"; + regulator-min-microvolt = <600000>; + regulator-max-microvolt = <900000>; + regulator-always-on; + regulator-boot-on; + }; + + buckb2: buck2 { + regulator-name = "vdd_ram_0v85"; + regulator-min-microvolt = <850000>; + regulator-max-microvolt = <850000>; + regulator-boot-on; + regulator-always-on; + }; + + buckb3: buck3 { + regulator-name = "vdd_core_0v85"; + regulator-min-microvolt = <850000>; + regulator-max-microvolt = <850000>; + regulator-boot-on; + regulator-always-on; + }; + + buckb4: buck4 { + regulator-name = "vdd_io_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + }; + }; }; &ospi0 { -- 2.39.2