From patchwork Mon Apr 17 15:48:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Esteban Blanc X-Patchwork-Id: 13214365 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 51EC7C77B7D for ; Mon, 17 Apr 2023 16:46:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=lO5+ZmSiSnZxhBxWHsl/2ghwDeCpCVvmhKC6v21we2w=; b=SwXdChkRF1riJN 88mvN3OFUFBpTLpS9mWESN3NKgxr8kUpJ5s3Wg4ssDcE0hJFrz1JFxuIfcIUNyaKoJpjel1Umplpw lpYs13MybrTGT66+yuYZKB2+ANDzxqG3wH62CX+C3IaMqoM5wR3eCsPb4G/YdQb4DCbKi9/Um8g14 74S0SQ1DZTbsircAHFTAxgDFHogNtgdhybFs10nB8cfNELb9OGCyj+8D6QAKZ4BOY0u0UTkGMxkhk k97AhJxdBzgtdBHQg/Aax2+8SCkYYtRJ5QswQ0MntyynCk8YyRA+geFAMr++nRxRSlOs8P5Wpnql8 07kz7hFxQ4QTW1y2exVA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1poRyx-00H6BX-2Z; Mon, 17 Apr 2023 16:45:35 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1poRys-00H6AH-1g for linux-arm-kernel@bombadil.infradead.org; Mon, 17 Apr 2023 16:45:30 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Transfer-Encoding:MIME-Version :References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=X85l2d7NJCmwLILZpNY9M6MPLYM0ojKd4DtOQId9uPw=; b=DUwBXI+h+eQuMBlQ2j+jh/Fsio ymRLeBAJLVQgSiNUkegUjPuLcK7IxuqAB9z9rRQhEyGz+clyw0kDm9Hg5/uETdvkIM7wfEzaGpfez 91ZbOnh28N8etcXXRpml5KKhJ7i9lODnFs9iH2y5qZA58PqcHOV0JAzGEO4+GhrSykrwdd364V6Hi WGyjd3JwJnXo3hLvvmtRv7qNweHSCT5XvIifeb2ofK+RfUXf2PU4zEK+wvyZMzJMCg5VSL5qyOtCc 1NvgQMwLXIX3wiSdJztmxzKAQN7xPhPRPOkB2TQwQWkk59fw5+6Lh1osMRBrvzwQN+RZMU6cQ8VxP aQHCkn+A==; Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]) by desiato.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1poR5v-00HNfD-1X for linux-arm-kernel@lists.infradead.org; Mon, 17 Apr 2023 15:48:47 +0000 Received: by mail-wm1-x32a.google.com with SMTP id o9-20020a05600c510900b003f17012276fso2521279wms.4 for ; Mon, 17 Apr 2023 08:48:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20221208.gappssmtp.com; s=20221208; t=1681746521; x=1684338521; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=X85l2d7NJCmwLILZpNY9M6MPLYM0ojKd4DtOQId9uPw=; b=PO1dBDrjSLIMgfg3Kl3hSb8qz17TJbtYsNSQGpabbSMGyKsK+V8PNc1qh6xuRNRQ3V S1cA+WFxT7apXran8o5gIbTD2McnQcM0gTthAvQ+aKS2LkKTyiCiXADs3i2iVDTzfV4z hQ9SpIOo5B0YkOz59PJmQLfMIG9s/hd+1cwxROnKQtSyM53OckZNsnRk52aBiNafNXJx DztWjoVpAyMoDzh6EJwDFJvOtU1lxmDeUeizyTv2AJKLg1/stNrlTMeRS8AmVFnX6Zce tDF2NgnUBgJ+HVeNGRI1/sWOyArO5cHuBPo57/cICjR1xBRkKvhn38N568c8ppaaoKTD C6XA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681746521; x=1684338521; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=X85l2d7NJCmwLILZpNY9M6MPLYM0ojKd4DtOQId9uPw=; b=X23K2eAMhKTCc6WNpcYIcZatbL63siBkipGqHmX5NUmkgYsLoonRjAiWV8HRga1CTS j/CIzGJgJCV4m6SK16l8WaE8rQyvgQgqWqIlySSY+saXP+A+nOWhuRSV6gYvWnnWVcP2 Ys4LWjdTyr2FltOpI5SFObo27cKiSlhxecUjj9Y53Jo1UouoxOKk4VCN1f4lLAkqodLI nRvITHL90BhFH++9X8s388QIT0OhToua6NXOuKgrsL9/V99rxa8VNx3CGvKA7+EVe6Lb FJssLXt+CqobW4c2qp5LGeUE5XQVwhdhhfaF6pNzHH4ZBgLC4bSG/x9k8pPNWMMD6g9b gmRQ== X-Gm-Message-State: AAQBX9eGLoNwiYFvHI1fN+RHzLsksy7PIHWeazk8+s/QfY8lRidubUJr XkvS7E15V767hMBnvAI4ZakzQg== X-Google-Smtp-Source: AKy350ZXBG2QMTqT+vo4TejHH69tUKsW1wMXcv1AoM2I2UhDgW8AbBg5aWaZaLiuXDQY+ifBa0mfsg== X-Received: by 2002:a7b:cb8b:0:b0:3f1:74c7:c7cb with SMTP id m11-20020a7bcb8b000000b003f174c7c7cbmr1442667wmi.16.1681746521286; Mon, 17 Apr 2023 08:48:41 -0700 (PDT) Received: from localhost.localdomain ([2a01:e0a:28d:66d0:5888:afdf:3f10:3b2b]) by smtp.gmail.com with ESMTPSA id v5-20020a05600c444500b003f09cda253esm16189932wmn.34.2023.04.17.08.48.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Apr 2023 08:48:40 -0700 (PDT) From: Esteban Blanc To: nm@ti.com, vigneshr@ti.com, kristo@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, sterzik@ti.com, u-kumar1@ti.com, eblanc@baylibre.com, jneanne@baylibre.com, jpanis@baylibre.com, aseketeli@baylibre.com Subject: [PATCH v3 6/6] arm64: dts: ti: k3-am62a7-sk: Add support for TPS6593 PMIC Date: Mon, 17 Apr 2023 17:48:32 +0200 Message-Id: <20230417154832.216774-7-eblanc@baylibre.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230417154832.216774-1-eblanc@baylibre.com> References: <20230417154832.216774-1-eblanc@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230417_164843_600751_A1ED34BC X-CRM114-Status: GOOD ( 12.18 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Julien Panis This patch adds support for TPS6593 PMIC on main I2C0 bus. This device 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: Julien Panis Signed-off-by: Esteban Blanc --- arch/arm64/boot/dts/ti/k3-am62a7-sk.dts | 95 +++++++++++++++++++++++++ 1 file changed, 95 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-am62a7-sk.dts b/arch/arm64/boot/dts/ti/k3-am62a7-sk.dts index 5c9012141ee2..8484cd987646 100644 --- a/arch/arm64/boot/dts/ti/k3-am62a7-sk.dts +++ b/arch/arm64/boot/dts/ti/k3-am62a7-sk.dts @@ -191,11 +191,106 @@ AM62AX_IOPAD(0x12c, PIN_INPUT, 0) /* (W16) RGMII1_TX_CTL */ }; }; +&mcu_pmx0 { + status = "okay"; + + pmic_irq_pins_default: pmic-irq-pins-default { + pinctrl-single,pins = < + AM62AX_MCU_IOPAD(0x000, PIN_INPUT, 7) /* (E11) MCU_GPIO0_0 */ + >; + }; +}; + +&mcu_gpio0 { + status = "okay"; +}; + &main_i2c0 { status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&main_i2c0_pins_default>; clock-frequency = <400000>; + + tps659312: pmic@48 { + compatible = "ti,tps6593-q1"; + reg = <0x48>; + ti,primary-pmic; + system-power-controller; + + gpio-controller; + #gpio-cells = <2>; + + pinctrl-names = "default"; + pinctrl-0 = <&pmic_irq_pins_default>; + interrupt-parent = <&mcu_gpio0>; + interrupts = <0 IRQ_TYPE_EDGE_FALLING>; + + buck123-supply = <&vcc_3v3_sys>; + buck4-supply = <&vcc_3v3_sys>; + buck5-supply = <&vcc_3v3_sys>; + ldo1-supply = <&vcc_3v3_sys>; + ldo2-supply = <&vcc_3v3_sys>; + ldo3-supply = <&buck5>; + ldo4-supply = <&vcc_3v3_sys>; + + regulators { + buck123: buck123 { + regulator-name = "vcc_core"; + regulator-min-microvolt = <715000>; + regulator-max-microvolt = <895000>; + regulator-boot-on; + regulator-always-on; + }; + + buck4: buck4 { + regulator-name = "vcc_1v1"; + regulator-min-microvolt = <1100000>; + regulator-max-microvolt = <1100000>; + regulator-boot-on; + regulator-always-on; + }; + + buck5: buck5 { + regulator-name = "vcc_1v8_sys"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + ldo1: ldo1 { + regulator-name = "vddshv5_sdio"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-boot-on; + regulator-always-on; + }; + + ldo2: ldo2 { + regulator-name = "vpp_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + ldo3: ldo3 { + regulator-name = "vcc_0v85"; + regulator-min-microvolt = <850000>; + regulator-max-microvolt = <850000>; + regulator-boot-on; + regulator-always-on; + }; + + ldo4: ldo4 { + regulator-name = "vdda_1v8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + }; + }; }; &main_i2c1 {