From patchwork Mon Jan 30 23:59:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 50554 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp2463765wrn; Mon, 30 Jan 2023 16:03:48 -0800 (PST) X-Google-Smtp-Source: AK7set82D/5uH7SQLbgu94j2bvgwX9zNZU+P5xADI1Iw8UA8RAHv5sg0nDL5AymGTYKiPjY7Xjoe X-Received: by 2002:a17:907:e8c:b0:88b:af3b:2a1a with SMTP id ho12-20020a1709070e8c00b0088baf3b2a1amr1809477ejc.49.1675123428608; Mon, 30 Jan 2023 16:03:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675123428; cv=none; d=google.com; s=arc-20160816; b=S5SJd6gtfWXM20ZL4iBMLaBcI5qQf5DivycIAuorNS1L66+3649jDeyoZ0pTGer1+H te+1/bpEsNpx/zEWB6p1GDIwep9tw6/A3Upp1uRI7SGB+0qIkQ+FQx0KByo9rM1GtrPQ B1LDPPY/e+Jjh/Sjgrc4ksfWnlzv0UieJqM8x50XjSDg5hgNTDSGOdKNUjl7wWTfuUbD i8MhzO2Lb4tmlfL+0GQ59jXyBqOhkY+EgVEsxGXvl4lzbnce768FW8jIm59BpLb5TwV3 CgAEwCoCIq9CEe1EamkNz0md2nlFFOc5qOoEouYOUhw37P0pqgeF5570R2n9vvrzY9o7 bqwg== 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=jrF1u3WyVFIlENoVsyiCEOPnsRqoe0ZZXvxrVAdDpn85lQhqpmhQYrNZNBPDFcRauy fibIVrOvM7wDr9kReqAb0Fu+tQJ5f/qkWqbjbA+Q9lrVVRiZxn1eZQTLKLD1l7eVHmHA ETerG4U458WPt+iwRVHWtz+1guSAtlhAKydSt0juRUAXjNbxB14rnGxfGcHC//jKw+tV zO4kvb83bZmJVIocAsleckhALwiYnUNPG+eZQw0o0lcPLQpNfmofz5q+y4mzP93K/Fet ScMOScT7WUTKAKJRLFlar71C7lcaiQl8eAlOwgJXa+J5ym3qdfsWRVGr+XmJPgqHPQhf +20Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Lk0UQt4R; 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 jr23-20020a170906515700b00872733f3b95si15475126ejc.336.2023.01.30.16.03.14; Mon, 30 Jan 2023 16:03:48 -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=Lk0UQt4R; 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 S231373AbjA3X76 (ORCPT + 99 others); Mon, 30 Jan 2023 18:59:58 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42240 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231287AbjA3X7m (ORCPT ); Mon, 30 Jan 2023 18:59:42 -0500 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7204A241D0 for ; Mon, 30 Jan 2023 15:59:40 -0800 (PST) Received: by mail-ej1-x634.google.com with SMTP id mf7so18180479ejc.6 for ; Mon, 30 Jan 2023 15:59:40 -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=Lk0UQt4Rrn4ycn3nVPnjAtH56NWzkGwokDqAsT5h41hiez3MuaFJgGIaGh+leF84jp OgLR+zYT1AGnJ2Jzc/dL8z15GxQtubC0/VjbGHG+rVKzgPMZgwL1525/6ak6/hSGrWW8 w5n034Vr52tRKmLI7rT2g0mirRr2HfqDisx6JGahP380s0RPR/4VII+hrbyA84BWCpuK lK6ZbQdcN3CrlSmVgNFcW1yMgpR5yftw6oDRtreiUTSDFncG5IKynXYYLv1k1sHNKO1M 4FV4yk7jxOEFvbiMG+jm0I1QoICYaIegOsQD2Uphya8/dP9pZxLtOCYVD5IVOAhRLHKD hIyg== 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=u9Zau69LEraCer1KmFxtYiEUnZN0bP4M5S+lfRLpuF/MkTvnrKjIJRINIwhkCVgcjv N5x/OeJGBadMkthV62mGE3glxFluu6uwVgKEb1k98HF50zBD4MObTYqiC6xChzPTGQy4 6qVUIEV1mRgpCUbUPZbtXNsMquW+CG0wu3R4/ON0sAyBojH53z6SNX0x113LC/o21czD IGmNIhB2t2Mg8S1xjIk0261tddtaXGZ1iEfo3/5kNrvortvNvAazqvduvk0ZXppVDCrw By9+ojgC/55l4P3IiuqkOJueN7KSrZZVZ/1iAJZlS1bQQO6H5MHgkIyW4b4EMBDnomq8 SbTA== X-Gm-Message-State: AO0yUKWyqiT05gEHadmS0potGxe0Zqq8tqtvNaYRdUfNgw9IamFHEya2 p87ykXggHPAAT/rdaDyyJMOIMA== X-Received: by 2002:a17:906:168a:b0:87d:f3e2:7f4d with SMTP id s10-20020a170906168a00b0087df3e27f4dmr13709753ejd.25.1675123179035; Mon, 30 Jan 2023 15:59:39 -0800 (PST) Received: from localhost.localdomain (abyl20.neoplus.adsl.tpnet.pl. [83.9.31.20]) by smtp.gmail.com with ESMTPSA id jr23-20020a170906515700b0086f4b8f9e42sm7577751ejc.65.2023.01.30.15.59.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Jan 2023 15:59:38 -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 v4 3/8] dt-bindings: clock: Add Qcom SM6125 GPUCC Date: Tue, 31 Jan 2023 00:59:21 +0100 Message-Id: <20230130235926.2419776-4-konrad.dybcio@linaro.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230130235926.2419776-1-konrad.dybcio@linaro.org> References: <20230130235926.2419776-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?1756494224075910417?= X-GMAIL-MSGID: =?utf-8?q?1756494224075910417?= 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