From patchwork Wed Feb 8 09:13:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 54282 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp3349271wrn; Wed, 8 Feb 2023 01:16:33 -0800 (PST) X-Google-Smtp-Source: AK7set/zAFEwUPl8QssajsEMVNaETS7GjdNCUVOvccs5uXf7FMdI5rNat73H2G/oNH6oYX4cPExK X-Received: by 2002:a17:902:d4c5:b0:196:3ae3:4ffe with SMTP id o5-20020a170902d4c500b001963ae34ffemr7891001plg.41.1675847793114; Wed, 08 Feb 2023 01:16:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675847793; cv=none; d=google.com; s=arc-20160816; b=t0vBLLfvnZjjWOsnoqQPT6lJOilh8Zfy+2gyg6OrCGW2F8K1YHAfBTiE4+pHtN4fh4 sWgWNrDqX0480fEUWGc3N+xVpoCFzRKcmYbyv8vMApWAMfhlTMv+7cl3Zh2TiPikfvs7 bISSd8mqd1EnAHFx28EUd6xTZAvvyALXPoqQbl2eV++Hmfocf+cWaL783PC6GySCmA8d 49e8C5471jiCaNu+0nqmoDd9wHTNCZdAz7s8kaDZfR7u/V+hX5GL0VXZpb8iij0Kh/8y yxJBpkRUTOZlkQMBgU9YplfkgKvM6Esc2eR/vpfyUzJEsLpPx007uWSTfP+wFnw9OfKx Xk8g== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=VsZqVss/r1fgDB1F0vcdkCl/uod+C4uxkkKM1hV8pW8=; b=uYavQXjpqaKz0o5hlPz6SnIcXw20hV603Bb7jf3iF/+FRpI011yAKd8vFfLsGSUo7k ooW3FIfIt6jdE5AdopqdmQXqIMnQoUuaFSxXe8nybNMhAW8766lso7KPmF2QwdVyY+Xe Poy1ltW6wo5a2AhzVfVlRvP+SQqXIdlQlEkN7dXdBfrpisF77Zqz5ySCO2SQ568VlCE+ BH7P7GJISbXz2mJnXBSEdVgOkW2bCT/5R4GJKZggidFFE//wpfUNHPNJ1jwif4YQK3yH vTcfD4quepAiTiVA7ZIzBNnQqtN59exCW7mo7TsaIVKZ7W5w1siC+CLowcBMSWW0vvQV 9W7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kZ8CupCU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j7-20020a170902758700b001960922af15si15184720pll.239.2023.02.08.01.16.20; Wed, 08 Feb 2023 01:16:33 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kZ8CupCU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 S231401AbjBHJPx (ORCPT + 99 others); Wed, 8 Feb 2023 04:15:53 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32976 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230430AbjBHJPS (ORCPT ); Wed, 8 Feb 2023 04:15:18 -0500 Received: from mail-ej1-x62c.google.com (mail-ej1-x62c.google.com [IPv6:2a00:1450:4864:20::62c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3931746166 for ; Wed, 8 Feb 2023 01:13:56 -0800 (PST) Received: by mail-ej1-x62c.google.com with SMTP id m1so7099415ejx.7 for ; Wed, 08 Feb 2023 01:13:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; 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=VsZqVss/r1fgDB1F0vcdkCl/uod+C4uxkkKM1hV8pW8=; b=kZ8CupCUqUR7/gKzUvFjUUVm82Mu6SfLqlygMLNTfnrqRuux1/TW5YdIMlnXngaOuW JupnGJ5hMi7zqwF2y3CIWWDqZMLfPzFoc5y5C677YG2a/7IAR3O2FglpfQ6WlR1kduFJ 94QH4hkK9km0niC2C+99OG50+iAMz+yP+PzI3rExi8NgtjhHvWYbWjkPwsnPYVrAiNHC Ya+aFkzZaJGtl32/GN88xtrc96mxROZY63xP/YQaXZ2Fhgi4LaFg6xbOoax0o7wIqhxX U8pEpNfhaJMspmTPiuT6Bs5sJLFCp+KnKpudXwsTY0zQe6l4GI3hJZIQe3bcV2lU30NA DpsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=VsZqVss/r1fgDB1F0vcdkCl/uod+C4uxkkKM1hV8pW8=; b=LHTaxeiKNNclfSvQFwZ4r8QocPBBLDbnZuPl0D+LFzJ4Zl1YP1QxoqtgZfhR1hVXFx ITGjTq6hGXfc8IKeVGer6X5zol0gPkdgQc+pX9CZYq1lTl0Dq2rzGDWZxBqtqBHznS3m zp/s0ZJ4yvbtTaRPQhJs5i9W+Vxn/Jdtb8lJ69YZngdgIll9hvtQVzU6gOqr+B1IA+jt PrFDPTTR1TdjKIGIMWhLaWQxRQ4R5PRNhCsAvsu8RaOGGrhlRubBB+MhT+r4M+bd/7PV Rvlttxlb3FIcYvAFxm5Cjw7T3BAHUNs4qJLazhcYAuNBiYoES+4bnWCmmYFB5ywp46O3 rTbg== X-Gm-Message-State: AO0yUKW1LIfCg74P4GQhCI0uk/OVlwkzY3t3Rsegxj1Sk1QawW3cDL31 I2vSdaYssNhm1NX5X92+0k7bMA== X-Received: by 2002:a17:906:3888:b0:7c1:765:9cfc with SMTP id q8-20020a170906388800b007c107659cfcmr2259403ejd.34.1675847633002; Wed, 08 Feb 2023 01:13:53 -0800 (PST) Received: from localhost.localdomain (abxh117.neoplus.adsl.tpnet.pl. [83.9.1.117]) by smtp.gmail.com with ESMTPSA id z2-20020a1709064e0200b00887a23bab85sm7987279eju.220.2023.02.08.01.13.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 Feb 2023 01:13:52 -0800 (PST) From: Konrad Dybcio To: linux-arm-msm@vger.kernel.org, andersson@kernel.org, agross@kernel.org, krzysztof.kozlowski@linaro.org Cc: marijn.suijten@somainline.org, Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v6 05/10] dt-bindings: clock: Add Qcom SM6125 GPUCC Date: Wed, 8 Feb 2023 10:13:35 +0100 Message-Id: <20230208091340.124641-6-konrad.dybcio@linaro.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230208091340.124641-1-konrad.dybcio@linaro.org> References: <20230208091340.124641-1-konrad.dybcio@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757253775523863312?= X-GMAIL-MSGID: =?utf-8?q?1757253775523863312?= Add device tree bindings for graphics clock controller for Qualcomm Technology Inc's SM6125 SoCs. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Konrad Dybcio --- .../bindings/clock/qcom,sm6125-gpucc.yaml | 64 +++++++++++++++++++ include/dt-bindings/clock/qcom,sm6125-gpucc.h | 31 +++++++++ 2 files changed, 95 insertions(+) create mode 100644 Documentation/devicetree/bindings/clock/qcom,sm6125-gpucc.yaml create mode 100644 include/dt-bindings/clock/qcom,sm6125-gpucc.h diff --git a/Documentation/devicetree/bindings/clock/qcom,sm6125-gpucc.yaml b/Documentation/devicetree/bindings/clock/qcom,sm6125-gpucc.yaml new file mode 100644 index 000000000000..374a1844a159 --- /dev/null +++ b/Documentation/devicetree/bindings/clock/qcom,sm6125-gpucc.yaml @@ -0,0 +1,64 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/clock/qcom,sm6125-gpucc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm Graphics Clock & Reset Controller on SM6125 + +maintainers: + - Konrad Dybcio + +description: | + Qualcomm graphics clock control module provides clocks and power domains on + Qualcomm SoCs. + + See also:: include/dt-bindings/clock/qcom,sm6125-gpucc.h + +properties: + compatible: + enum: + - qcom,sm6125-gpucc + + clocks: + items: + - description: Board XO source + - description: GPLL0 main branch source + + '#clock-cells': + const: 1 + + '#power-domain-cells': + const: 1 + + reg: + maxItems: 1 + +required: + - compatible + - reg + - clocks + - '#clock-cells' + - '#power-domain-cells' + +additionalProperties: false + +examples: + - | + #include + #include + + soc { + #address-cells = <1>; + #size-cells = <1>; + + clock-controller@5990000 { + compatible = "qcom,sm6125-gpucc"; + reg = <0x05990000 0x9000>; + clocks = <&rpmcc RPM_SMD_XO_CLK_SRC>, + <&gcc GCC_GPU_GPLL0_CLK_SRC>; + #clock-cells = <1>; + #power-domain-cells = <1>; + }; + }; +... diff --git a/include/dt-bindings/clock/qcom,sm6125-gpucc.h b/include/dt-bindings/clock/qcom,sm6125-gpucc.h new file mode 100644 index 000000000000..ce5bd920f2c4 --- /dev/null +++ b/include/dt-bindings/clock/qcom,sm6125-gpucc.h @@ -0,0 +1,31 @@ +/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */ +/* + * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. + * Copyright (c) 2023, Linaro Limited + */ + +#ifndef _DT_BINDINGS_CLK_QCOM_GPU_CC_SM6125_H +#define _DT_BINDINGS_CLK_QCOM_GPU_CC_SM6125_H + +/* Clocks */ +#define GPU_CC_PLL0_OUT_AUX2 0 +#define GPU_CC_PLL1_OUT_AUX2 1 +#define GPU_CC_CRC_AHB_CLK 2 +#define GPU_CC_CX_APB_CLK 3 +#define GPU_CC_CX_GFX3D_CLK 4 +#define GPU_CC_CX_GMU_CLK 5 +#define GPU_CC_CX_SNOC_DVM_CLK 6 +#define GPU_CC_CXO_AON_CLK 7 +#define GPU_CC_CXO_CLK 8 +#define GPU_CC_GMU_CLK_SRC 9 +#define GPU_CC_SLEEP_CLK 10 +#define GPU_CC_GX_GFX3D_CLK 11 +#define GPU_CC_GX_GFX3D_CLK_SRC 12 +#define GPU_CC_AHB_CLK 13 +#define GPU_CC_HLOS1_VOTE_GPU_SMMU_CLK 14 + +/* GDSCs */ +#define GPU_CX_GDSC 0 +#define GPU_GX_GDSC 1 + +#endif