From patchwork Thu Oct 15 15:40:01 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cristian Marussi X-Patchwork-Id: 11839533 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 41BB214B2 for ; Thu, 15 Oct 2020 15:40:45 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id F2B5A22248 for ; Thu, 15 Oct 2020 15:40:44 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Sf16tDnT" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F2B5A22248 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:MIME-Version:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:References:In-Reply-To:Message-Id:Date:Subject:To: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=vAfOsu7PXSdJCYqy8pQjI6/1aDl95JTC+lq2XFt5K2g=; b=Sf16tDnT7paBuNQZFItss9+f+m Qspn07tWwq9rnjfUlr3BuUJLevP2crjzLZ00vEFnrHnJGim6VWcwXj3YaERxe6DJUQtOEC3iU6rY3 qfCHQOcsMgzoiocna+paV4jsQHRhM55aS4G4nGTjbb+KVbeEYPpt6aZ1uQvvoyuYlIUfputHCET1f 7X05gyDR0gJH7LMZfHQelP7zeebPxJhe+smO2qboMl+gf/gFukcifdH670LcEV6b6iIk6/JWLf0F1 heHhye+MG4Vo3ev1VYweLBKs6JGCYmIXuQCTv/kOBxr9kGk808b3rCGlzNANmO6sDWY/3RGyzdqVx e/qx6jEA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kT5Mn-0002pN-EH; Thu, 15 Oct 2020 15:40:33 +0000 Received: from foss.arm.com ([217.140.110.172]) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kT5MY-0002lU-LR for linux-arm-kernel@lists.infradead.org; Thu, 15 Oct 2020 15:40:19 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id AE75E143D; Thu, 15 Oct 2020 08:40:17 -0700 (PDT) Received: from e120937-lin.home (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D83853F719; Thu, 15 Oct 2020 08:40:15 -0700 (PDT) From: Cristian Marussi To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v2 4/4] dt-bindings: arm: add support for SCMI Regulators Date: Thu, 15 Oct 2020 16:40:01 +0100 Message-Id: <20201015154001.8931-5-cristian.marussi@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201015154001.8931-1-cristian.marussi@arm.com> References: <20201015154001.8931-1-cristian.marussi@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201015_114018_791763_25C6C44B X-CRM114-Status: GOOD ( 14.22 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [217.140.110.172 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: robh@kernel.org, satyakim@qti.qualcomm.com, f.fainelli@gmail.com, vincent.guittot@linaro.org, sudeep.holla@arm.com, broonie@kernel.org, cristian.marussi@arm.com, james.quinlan@broadcom.com, Jonathan.Cameron@Huawei.com, souvik.chakravarty@arm.com, etienne.carriere@linaro.org, lukasz.luba@arm.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Add devicetree bindings to support regulators based on SCMI Voltage Domain Protocol. Signed-off-by: Cristian Marussi --- v1 --> v2 - removed any reference to negative voltages --- .../devicetree/bindings/arm/arm,scmi.txt | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/arm,scmi.txt b/Documentation/devicetree/bindings/arm/arm,scmi.txt index 55deb68230eb..6d3d0bdab322 100644 --- a/Documentation/devicetree/bindings/arm/arm,scmi.txt +++ b/Documentation/devicetree/bindings/arm/arm,scmi.txt @@ -62,6 +62,28 @@ Required properties: - #power-domain-cells : Should be 1. Contains the device or the power domain ID value used by SCMI commands. +Regulator bindings for the SCMI Regulator based on SCMI Message Protocol +------------------------------------------------------------ + +An SCMI Regulator is permanently bound to a well defined SCMI Voltage Domain, +and should be always positioned as a root regulator. +It does not support any current operation. + +This binding uses the common regulator binding[6]. + +SCMI Regulators are grouped under a 'regulators' node which in turn is a child +of the SCMI Voltage protocol node inside the desired SCMI instance node. + +Required properties: + - reg : shall identify an existent SCMI Voltage Domain. + +Optional properties: + - all of the other standard regulator bindings as in [6]: note that, since + the SCMI Protocol itself aims in fact to hide away many of the operational + capabilities usually exposed by the properties of a standard regulator, + most of the usual regulator bindings could have just no effect in the + context of this SCMI regulator. + Sensor bindings for the sensors based on SCMI Message Protocol -------------------------------------------------------------- SCMI provides an API to access the various sensors on the SoC. @@ -105,6 +127,7 @@ Required sub-node properties: [3] Documentation/devicetree/bindings/thermal/thermal*.yaml [4] Documentation/devicetree/bindings/sram/sram.yaml [5] Documentation/devicetree/bindings/reset/reset.txt +[6] Documentation/devicetree/bindings/regulator/regulator.yaml Example: @@ -169,6 +192,25 @@ firmware { reg = <0x16>; #reset-cells = <1>; }; + + scmi_voltage: protocol@17 { + reg = <0x17>; + + regulators { + regulator_cpu: regulator_scmi_cpu@0 { + reg = <0x0>; + regulator-max-microvolt = <3300000>; + }; + + regulator_gpu: regulator_scmi_gpu@9 { + reg = <0x9>; + regulator-min-microvolt = <500000>; + regulator-max-microvolt = <4200000>; + }; + + ... + }; + }; }; };