From patchwork Wed Aug 29 23:15:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 145480 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp148472ljw; Wed, 29 Aug 2018 16:13:37 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZ7hQgYbB9gXLHlwjFPodB3dqmFfAZPoBVPW2DdEtQZonihYECNzVUVs3WwpO8D8Mm6/75T X-Received: by 2002:a63:d518:: with SMTP id c24-v6mr7066911pgg.357.1535584417628; Wed, 29 Aug 2018 16:13:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535584417; cv=none; d=google.com; s=arc-20160816; b=l0iQtis/eXkA2E8r9i0URfJF6cnZtX7Xl8NKrE9E5BgTNTTUnAyUOqDO7mfpwjjiqV +f8qRWR2kJOSQbw8tTxTkqFODp5hkf8KrUT/BL7xB24WCZmaAs4hYrR65WCNsPq/eAeP USzIrWBfqKTBKz5tlha23X0gsIfcc8sJQhQef5BKZ3hyibDYDY2+2Qgaak1J7RR+t32E EQHIy9161Ilknoe1pJ+rKKKh2KZgtVM7luG9eF0C6QJjmb2p+PW7Uel0QsgC1Yt313S7 A7WMbT6kjSEkdBc0Jb87Y6mmM4CEPf2wTVO5H7fwL+e668X+yC15cFPHCGj/qX4v2cb+ cW5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=QGum6WMbhgDLWXu15YSCCf+nSJoU4qkhFTooN6vMglo=; b=SCa24OF3yRWUsa9PP8hKvs5LPUW9bP7YgO78wWlZEBGdIazF0tnrthX3UZwRH+PY/w ZKZbLw0I8SKD7T4FbM6ynY/6dkAscjcK3RcaCBX6ezd2EDX/E70qh1VPijipYUwKlKF4 eihVf+1s2AtkpMxqMx/iudNfK6YunfJftr7X+FkwuY8KCDk9JcDFRl7c78oPmCmGcnHb VZ/yUM3+MgM6oN5PwvpnrmvD7UKwm8SMe8sRtOHAR2JiSxwXGD1MFhYtY4icbIZ4cO+n QLg9mAzTsfyLT2+jrzthGpB4q7J7XXAOa1zJBiykmUX4CyiUJXrOC0ddOZnx6R7qq9Oo YY/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=c7MBNBGw; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i128-v6si5005283pfg.93.2018.08.29.16.13.37; Wed, 29 Aug 2018 16:13:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=c7MBNBGw; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-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 S1727616AbeH3DMl (ORCPT + 13 others); Wed, 29 Aug 2018 23:12:41 -0400 Received: from mail-pl1-f194.google.com ([209.85.214.194]:44668 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727526AbeH3DMk (ORCPT ); Wed, 29 Aug 2018 23:12:40 -0400 Received: by mail-pl1-f194.google.com with SMTP id ba4-v6so2946523plb.11 for ; Wed, 29 Aug 2018 16:13:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=QGum6WMbhgDLWXu15YSCCf+nSJoU4qkhFTooN6vMglo=; b=c7MBNBGwa6umbaSWHub1O1fxqMTJPyrQ0uNb5l5gAFRp5ngwxVu3xOlr7yabrn/Tng MSTXZ0kSLvPNmMa/eS2tP5jlyAH7Q1F7QSsogBwKEFA+WPJJ0Hyhj7FTnPswCww7LYRk xuHqCHehWTJ95BGdqUId4PXarqS8rIZqzgPx0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=QGum6WMbhgDLWXu15YSCCf+nSJoU4qkhFTooN6vMglo=; b=s1JanEGGmlhneT0B6ZUkypJG5TtVW6d6ZH84/o5HNjlDftKTYuSc3+Ah0M6v5GyX1j mdy/9aydZF8R8O0vEWs2LMsVxlxadwhQC4KEpfKqGOfsC4YJvPVpxZo2tItVODMw7cqZ I6eKvegTG+DH8ccdx4n/1KEcpIwpAc9S4W4k3y8hTbql3Ru+7IfWv1VHLMtoQoxK9wPz nmKhUKCEcClrBy+oe2gvb2fJyuYSMR3hKswISum96ivzv0Cq+4FbfGGhINR3Xh4EIypC weE6rnOphigNj3wWuFJGNbFFuuO+lL+YCqlLLExmImUrAxPI04MrtgZ8DX/5AHkNwiiU jI3A== X-Gm-Message-State: APzg51DH4huFFB/kZ3idwKqJsY1xvBadJBeBNssz94FqzFnzKOB2i7Xg O5M3g03C0R5YSoBviChaPulstg== X-Received: by 2002:a17:902:22e:: with SMTP id 43-v6mr7821339plc.118.1535584407314; Wed, 29 Aug 2018 16:13:27 -0700 (PDT) Received: from localhost.localdomain (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id w69-v6sm14035404pgd.37.2018.08.29.16.13.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 29 Aug 2018 16:13:26 -0700 (PDT) From: Bjorn Andersson To: Rob Herring , Mark Rutland , Stephen Boyd Cc: Andy Gross , Sricharan R , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, Craig Tatlor Subject: [PATCH 1/3] dt-bindings: firmware: scm: Refactor compatibles and clocks Date: Wed, 29 Aug 2018 16:15:03 -0700 Message-Id: <20180829231505.22660-2-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180829231505.22660-1-bjorn.andersson@linaro.org> References: <20180829231505.22660-1-bjorn.andersson@linaro.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org When the binding was written all "future" platforms required three clocks, so the default compatible (qcom,scm) was defined to require this. But as history shows all "future" platforms actually lack required clocks. Given how the binding is written these compatibles have to be added as an exception to the default. Refactor the description of compatible to define that a platform compatible should be given, followed by the fallback of qcom,scm. Also refactor the description of the clocks in a way that this does not need to be updated as new platform specific compatibles are added. Signed-off-by: Bjorn Andersson --- .../devicetree/bindings/firmware/qcom,scm.txt | 31 ++++++++++++------- 1 file changed, 19 insertions(+), 12 deletions(-) -- 2.18.0 diff --git a/Documentation/devicetree/bindings/firmware/qcom,scm.txt b/Documentation/devicetree/bindings/firmware/qcom,scm.txt index fcf6979c0b6d..1c8e24530f7c 100644 --- a/Documentation/devicetree/bindings/firmware/qcom,scm.txt +++ b/Documentation/devicetree/bindings/firmware/qcom,scm.txt @@ -7,16 +7,21 @@ assorted actions. Required properties: - compatible: must contain one of the following: - * "qcom,scm-apq8064" for APQ8064 platforms - * "qcom,scm-msm8660" for MSM8660 platforms - * "qcom,scm-msm8690" for MSM8690 platforms - * "qcom,scm-msm8996" for MSM8996 platforms - * "qcom,scm-ipq4019" for IPQ4019 platforms - * "qcom,scm" for later processors (MSM8916, APQ8084, MSM8974, etc) -- clocks: One to three clocks may be required based on compatible. - * No clock required for "qcom,scm-msm8996", "qcom,scm-ipq4019" - * Only core clock required for "qcom,scm-apq8064", "qcom,scm-msm8660", and "qcom,scm-msm8960" - * Core, iface, and bus clocks required for "qcom,scm" + * "qcom,scm-apq8064" + * "qcom,scm-apq8084" + * "qcom,scm-msm8660" + * "qcom,scm-msm8916" + * "qcom,scm-msm8960" + * "qcom,scm-msm8974" + * "qcom,scm-msm8996" + * "qcom,scm-ipq4019" + and: + * "qcom,scm" +- clocks: Specifies clocks needed by the SCM interface, if any: + * core clock required for "qcom,scm-apq8064", "qcom,scm-msm8660" and + "qcom,scm-msm8960" + * core, iface and bus clocks required for "qcom,scm-apq8084", + "qcom,scm-msm8916" and "qcom,scm-msm8974" - clock-names: Must contain "core" for the core clock, "iface" for the interface clock and "bus" for the bus clock per the requirements of the compatible. - qcom,dload-mode: phandle to the TCSR hardware block and offset of the @@ -26,8 +31,10 @@ Example for MSM8916: firmware { scm { - compatible = "qcom,scm"; - clocks = <&gcc GCC_CRYPTO_CLK> , <&gcc GCC_CRYPTO_AXI_CLK>, <&gcc GCC_CRYPTO_AHB_CLK>; + compatible = "qcom,msm8916", "qcom,scm"; + clocks = <&gcc GCC_CRYPTO_CLK> , + <&gcc GCC_CRYPTO_AXI_CLK>, + <&gcc GCC_CRYPTO_AHB_CLK>; clock-names = "core", "bus", "iface"; }; };