From patchwork Tue Jul 5 20:28:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 587455 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B7E9ACCA481 for ; Tue, 5 Jul 2022 20:56:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230419AbiGEU4I (ORCPT ); Tue, 5 Jul 2022 16:56:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33586 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230320AbiGEU4F (ORCPT ); Tue, 5 Jul 2022 16:56:05 -0400 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 DFF4B14011; Tue, 5 Jul 2022 13:56:02 -0700 (PDT) Received: by mail-ej1-x62c.google.com with SMTP id sb34so23654680ejc.11; Tue, 05 Jul 2022 13:56:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=yEYQM6TR6Lv5Jiw6nCrjGX8nWRViVOLatITa68KGyzE=; b=gzL6Mbkzc4j3EWv61fLpJlmcDxBJIO8hqhOB+bJsuXPSK4Bqxj8tYYGbBoO645Uqas +x1pMYiFy3Tu048BxzRuxsAGMy14Gk3DcbxtSBX/tvHFDWPcZiAWJ/+yr+nXAH9jz1vt eH6+BD55goyEDuWHEKMSg07OnEFtpMVUuNrdjZiG+g+c0TB+JYmu/Uxx2+kAjJFPUsq+ Ds59aPmNvxEmh4L6/YLssYqH3HgMx33Fwyfu1/krOnkxzRNurqjEZRYfygZxa6D55PZl QmezTQT/G2pIV2zO1xWuT77CA+z4lnwlKCE8XUJQLuhPVgNxQG5wGduj0zCw/xn4ir0B c7Rg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=yEYQM6TR6Lv5Jiw6nCrjGX8nWRViVOLatITa68KGyzE=; b=KQfE4vGlhU5bwRtEt0izqIEXD3DURP8DHCF/TVRnCgjkn8i/IWLMPCMxdXZXgBvVgw yrhVJGqO20qAeClRFOaOsLpq3mq6LQ8/6Cgkuf5aaZWzlf/NdxgdveXCEiRXgI39S6iB LotH4qTru0oAZZF7oeGCPHaEFDv4rIRN3UCny7neUN7/BID70uOPNCFVJxVdDnBVno2m ybDsror9dw5PQatGSaiNveWpVr2x0lYIUT7jbcpYr9bEhPcZG6U5rLGHVpfV0XvRDphR 96IQ/SodPzGiPm13rN7c7IzROIjnKOfl2j3iQoc8GRWiqvEptc8L3J81dzvpiv7Kav/k l6EQ== X-Gm-Message-State: AJIora/ZJJF9avNFcmWGwA8TJXNChVIG92e4MhUwv7zS2vUdOpGDlnEf U9aFdJ2nYWTWZlQRcOyq+63n78exh+8= X-Google-Smtp-Source: AGRyM1sj9anNe408c+d34oQAg9RdUzXXWOiVmT1Z1YMcvhx9ubFksw3/p50z5ViQ9pCUFqafeGbmlA== X-Received: by 2002:a17:907:7636:b0:72a:9297:37d1 with SMTP id jy22-20020a170907763600b0072a929737d1mr23263427ejc.349.1657054561319; Tue, 05 Jul 2022 13:56:01 -0700 (PDT) Received: from localhost.localdomain (93-42-70-190.ip85.fastwebnet.it. [93.42.70.190]) by smtp.googlemail.com with ESMTPSA id dm3-20020a05640222c300b0043a70c51470sm3836956edb.55.2022.07.05.13.56.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 13:56:00 -0700 (PDT) From: Christian Marangi To: Bjorn Andersson , Andy Gross , Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Christian Marangi Subject: [PATCH 1/5] dt-bindings: clock: fix wrong clock documentation for qcom,rpmcc Date: Tue, 5 Jul 2022 22:28:33 +0200 Message-Id: <20220705202837.667-2-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220705202837.667-1-ansuelsmth@gmail.com> References: <20220705202837.667-1-ansuelsmth@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org qcom,rpmcc describe 2 different kind of device. Currently we have definition for rpm-smd based device but we lack Documentation for simple rpm based device. Add the missing clk for ipq806x, apq8060, msm8660 and apq8064 and provide and additional example. Signed-off-by: Christian Marangi --- .../devicetree/bindings/clock/qcom,rpmcc.yaml | 77 ++++++++++++++++++- 1 file changed, 73 insertions(+), 4 deletions(-) diff --git a/Documentation/devicetree/bindings/clock/qcom,rpmcc.yaml b/Documentation/devicetree/bindings/clock/qcom,rpmcc.yaml index 9d296b89a8d0..028eb0277495 100644 --- a/Documentation/devicetree/bindings/clock/qcom,rpmcc.yaml +++ b/Documentation/devicetree/bindings/clock/qcom,rpmcc.yaml @@ -48,16 +48,65 @@ properties: '#clock-cells': const: 1 - clocks: - maxItems: 1 + clocks: true - clock-names: - const: xo + clock-names: true required: - compatible - '#clock-cells' +if: + properties: + compatible: + contains: + enum: + - qcom,rpmcc-apq8060 + - qcom,rpmcc-ipq806x + - qcom,rpmcc-msm8660 + +then: + properties: + clocks: + description: pxo clock + + clock-names: + const: pxo + + required: + - clocks + - clock-names + +else: + if: + properties: + compatible: + contains: + const: qcom,rpmcc-apq8064 + then: + properties: + clocks: + items: + - description: pxo clock + - description: cxo clock + + clock-names: + items: + - const: pxo + - const: cxo + + required: + - clocks + - clock-names + + else: + properties: + clocks: + description: xo clock + + clock-names: + const: xo + additionalProperties: false examples: @@ -73,3 +122,23 @@ examples: }; }; }; + + - | + rpm { + clock-controller { + compatible = "qcom,rpmcc-ipq806x", "qcom,rpmcc"; + #clock-cells = <1>; + clocks = <&pxo_board>; + clock-names = "pxo"; + }; + }; + + - | + rpm { + clock-controller { + compatible = "qcom,rpmcc-apq8064", "qcom,rpmcc"; + #clock-cells = <1>; + clocks = <&pxo_board>, <&cxo_board>; + clock-names = "pxo", "cxo"; + }; + }; From patchwork Tue Jul 5 20:28:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 587804 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9AECDCCA47C for ; Tue, 5 Jul 2022 20:56:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231448AbiGEU4H (ORCPT ); Tue, 5 Jul 2022 16:56:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33564 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230126AbiGEU4E (ORCPT ); Tue, 5 Jul 2022 16:56:04 -0400 Received: from mail-ed1-x532.google.com (mail-ed1-x532.google.com [IPv6:2a00:1450:4864:20::532]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C8924140AA; Tue, 5 Jul 2022 13:56:03 -0700 (PDT) Received: by mail-ed1-x532.google.com with SMTP id r6so5417360edd.7; Tue, 05 Jul 2022 13:56:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=jhCunu7o7fyLkxoFCy5X4R/JUxZNFSkDzNenHSRMMQQ=; b=dEV8et8Zf+CrYW5SJ80XB/rtAajkrIHXkxnP8cMbcFsm7Ife6JrWfcLYiDGxdSMdbT 2NqW3fQOD4EDYbx9uVckHzVb1uacBsfCqv8W46W+HgywDj63JZ6/y2s5uFWn5wzdqe6D y5OxyzydFnwgT3dD7FdBqXn7K8A/eRzAB5nxUjr38LBCp6TLOMtdwDqFX+VKa6wLR0Ht wD8s0HVFXYVT+oIPj251fQwkwmvO3fYHNcg3Qzj21Gf9E5AzVpvwCl+5yMrs9sStJ3TL kaEnjubSGUD2+R0vZXzgB6taqRHbhSz+q4U/BsQ9TNFEpX+6LXqBSJ2VbsesUKR/w2so 7vuA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=jhCunu7o7fyLkxoFCy5X4R/JUxZNFSkDzNenHSRMMQQ=; b=V137ikr7KZ2rzEgPLRATtvzqH53K6hfD9vK5TFWxZH81Wl9Poyh/aaTro6hr3NuURn mbAxphTxya9XxnQ4Dhr7w/lXr6GZBnFARBRYMukh32tR5iwOnqIPFMY1wI79STWwdUfv S2w4baSLJURLyxZBjwxhkz6LUfJYjXh0I3S1yUhxSxIRjbx/dY/gGzj/nDmLyY593xUj 8azyl4ucl51c7Q6IAqXFe7Ag/1wngb/7jd5jdaE0MpFsc14DjpGjmCLLa8Cjpm7ZGHox 7NP7CUcoax3ArQMrKB0JKZZjPrWiRC8iMuyqiThpXAktXC3X3L+zy2KGLyOCWtKL4PL4 IKPQ== X-Gm-Message-State: AJIora9t/bYWhDtvvwoU1mOOCQiPzZo6SjLnS8O/95rspTnrxxBm4T82 qO1XEbosA6KoQpHDIpgozrg= X-Google-Smtp-Source: AGRyM1tG2k/YpJN2FtkeEhUTabwe/2KLJDr/j982j5/jouqXLOKmkjFBIMDOPLtvpKixtVoYOKIdMA== X-Received: by 2002:aa7:df12:0:b0:43a:4991:1725 with SMTP id c18-20020aa7df12000000b0043a49911725mr19304594edy.55.1657054562369; Tue, 05 Jul 2022 13:56:02 -0700 (PDT) Received: from localhost.localdomain (93-42-70-190.ip85.fastwebnet.it. [93.42.70.190]) by smtp.googlemail.com with ESMTPSA id dm3-20020a05640222c300b0043a70c51470sm3836956edb.55.2022.07.05.13.56.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 13:56:01 -0700 (PDT) From: Christian Marangi To: Bjorn Andersson , Andy Gross , Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Christian Marangi Subject: [PATCH 2/5] ARM: DTS: qcom: fix dtbs_check warning with new rpmcc clocks Date: Tue, 5 Jul 2022 22:28:34 +0200 Message-Id: <20220705202837.667-3-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220705202837.667-1-ansuelsmth@gmail.com> References: <20220705202837.667-1-ansuelsmth@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Fix dtbs_check warning for new rpmcc Documentation changes and add the required clocks. Signed-off-by: Christian Marangi Reviewed-by: Dmitry Baryshkov --- arch/arm/boot/dts/qcom-apq8064.dtsi | 2 ++ arch/arm/boot/dts/qcom-ipq8064.dtsi | 2 ++ arch/arm/boot/dts/qcom-msm8660.dtsi | 4 +++- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/qcom-apq8064.dtsi b/arch/arm/boot/dts/qcom-apq8064.dtsi index 91adcbd54b17..6a88e616ea01 100644 --- a/arch/arm/boot/dts/qcom-apq8064.dtsi +++ b/arch/arm/boot/dts/qcom-apq8064.dtsi @@ -853,6 +853,8 @@ rpm@108000 { rpmcc: clock-controller { compatible = "qcom,rpmcc-apq8064", "qcom,rpmcc"; #clock-cells = <1>; + clocks = <&pxo_board>, <&cxo_board>; + clock-names = "pxo", "cxo"; }; regulators { diff --git a/arch/arm/boot/dts/qcom-ipq8064.dtsi b/arch/arm/boot/dts/qcom-ipq8064.dtsi index 4b475d98343c..1425a4e4283f 100644 --- a/arch/arm/boot/dts/qcom-ipq8064.dtsi +++ b/arch/arm/boot/dts/qcom-ipq8064.dtsi @@ -773,6 +773,8 @@ rpm: rpm@108000 { rpmcc: clock-controller { compatible = "qcom,rpmcc-ipq806x", "qcom,rpmcc"; #clock-cells = <1>; + clocks = <&pxo_board>; + clock-names = "pxo"; }; }; diff --git a/arch/arm/boot/dts/qcom-msm8660.dtsi b/arch/arm/boot/dts/qcom-msm8660.dtsi index b9cded35b1cc..63a501c63cf8 100644 --- a/arch/arm/boot/dts/qcom-msm8660.dtsi +++ b/arch/arm/boot/dts/qcom-msm8660.dtsi @@ -56,7 +56,7 @@ cxo_board { clock-frequency = <19200000>; }; - pxo_board { + pxo_board: pxo_board { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <27000000>; @@ -411,6 +411,8 @@ rpm: rpm@104000 { rpmcc: clock-controller { compatible = "qcom,rpmcc-msm8660", "qcom,rpmcc"; #clock-cells = <1>; + clocks = <&pxo_board>; + clock-names = "pxo"; }; pm8901-regulators { From patchwork Tue Jul 5 20:28:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 587454 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7C6BCCCA47B for ; Tue, 5 Jul 2022 20:56:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231728AbiGEU4J (ORCPT ); Tue, 5 Jul 2022 16:56:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33622 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231151AbiGEU4F (ORCPT ); Tue, 5 Jul 2022 16:56:05 -0400 Received: from mail-ej1-x632.google.com (mail-ej1-x632.google.com [IPv6:2a00:1450:4864:20::632]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DBF3514D3D; Tue, 5 Jul 2022 13:56:04 -0700 (PDT) Received: by mail-ej1-x632.google.com with SMTP id f26so812344ejl.4; Tue, 05 Jul 2022 13:56:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=+pxGLgqzAqc2l8/ddgANBnUDCCoY1u5ohBwZ73O4BlQ=; b=LioSRr8uLOdD4wJfnGoyW7I38zarpcZSYK6pbWcurbClBkdAY1FNnzqJ6UslL8WOkk jO+MD20ygtas4RPU+rU6pZ4x7AT++xpFViRA4e4kA3nlqpYPJThum0AO3whwsaETXSUp VEGf5DelS++fbMSQizieo155t1BsiSYH1o0eH+puiwrG87T5dYC8tereZv+7WjzPFUnz MsliTk9rvzGqn/5VscyIx5uqFO8i8w+brmbvBPIiTw1n3s5EoV39lrrCZdqKsmoyJN60 +TDlin0PvEpOfpfrlZ0bLdWTaEmoww9U5T/+SGIBu1ilAJ72ip0jU4IEs0J2jAFIXGfl qqsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=+pxGLgqzAqc2l8/ddgANBnUDCCoY1u5ohBwZ73O4BlQ=; b=Oa12XZteV4hfJMgSM1XQXuhAbFGTNoqVBo1eM5etg1hogjAFFDpXUWoXkhb5waZO68 WSP2Ftqjk/SqbbfpWT+Uh3g2E2mgLoMV0PsUtNzCdU8jJhh3hCk63mK5/tBOMi35qBwS Pya35EPwMPsJmNuGF2e+zeGOdXyRRp9FTKypPxN+oQz+31J2MVfl3X9Og0PNbyose3sy OeYplRePCowGixXC7JBgBhmZyNYYtu32AiOvc2svTgQ71KkmPIzIi9Mh5DZfwz/ZAMfB bMVUezJ5fYYeJY59/C8H3kVQKiaNZMQCLar0tNPzKiu9VCIUhZ912IUDpsBH0n42zM71 MLag== X-Gm-Message-State: AJIora84RcOb724xW25imaoKbln0+E9D3yqwFx9PsvOKme1hCRQbqW8u FCJs2M/LSCpRzsmky9TnPO0= X-Google-Smtp-Source: AGRyM1sbftGN1BJPGRPcnZkK9dHdSsBdkzB+AOczKdOp05PVuXAhxpHsPDU80I4FNtO80u166bBjJw== X-Received: by 2002:a17:906:478e:b0:722:f84d:159f with SMTP id cw14-20020a170906478e00b00722f84d159fmr36093911ejc.182.1657054563348; Tue, 05 Jul 2022 13:56:03 -0700 (PDT) Received: from localhost.localdomain (93-42-70-190.ip85.fastwebnet.it. [93.42.70.190]) by smtp.googlemail.com with ESMTPSA id dm3-20020a05640222c300b0043a70c51470sm3836956edb.55.2022.07.05.13.56.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 13:56:03 -0700 (PDT) From: Christian Marangi To: Bjorn Andersson , Andy Gross , Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Christian Marangi Subject: [PATCH 3/5] clk: qcom: clk-rpm: convert to parent_data API Date: Tue, 5 Jul 2022 22:28:35 +0200 Message-Id: <20220705202837.667-4-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220705202837.667-1-ansuelsmth@gmail.com> References: <20220705202837.667-1-ansuelsmth@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Convert clk-rpm driver to parent_data API and change parent names to cxo and pxo instead of the board variant as pxo_board is an ancient name and pxo should be used instead. Signed-off-by: Christian Marangi --- drivers/clk/qcom/clk-rpm.c | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/drivers/clk/qcom/clk-rpm.c b/drivers/clk/qcom/clk-rpm.c index a18811c38018..d45a8b0fc97c 100644 --- a/drivers/clk/qcom/clk-rpm.c +++ b/drivers/clk/qcom/clk-rpm.c @@ -23,6 +23,14 @@ #define QCOM_RPM_SCALING_ENABLE_ID 0x2 #define QCOM_RPM_XO_MODE_ON 0x2 +static const struct clk_parent_data gcc_pxo[] = { + { .fw_name = "pxo", .name = "pxo" }, +}; + +static const struct clk_parent_data gcc_cxo[] = { + { .fw_name = "cxo", .name = "cxo" }, +}; + #define DEFINE_CLK_RPM(_platform, _name, _active, r_id) \ static struct clk_rpm _platform##_##_active; \ static struct clk_rpm _platform##_##_name = { \ @@ -32,8 +40,8 @@ .hw.init = &(struct clk_init_data){ \ .ops = &clk_rpm_ops, \ .name = #_name, \ - .parent_names = (const char *[]){ "pxo_board" }, \ - .num_parents = 1, \ + .parent_data = gcc_pxo, \ + .num_parents = ARRAY_SIZE(gcc_pxo), \ }, \ }; \ static struct clk_rpm _platform##_##_active = { \ @@ -44,8 +52,8 @@ .hw.init = &(struct clk_init_data){ \ .ops = &clk_rpm_ops, \ .name = #_active, \ - .parent_names = (const char *[]){ "pxo_board" }, \ - .num_parents = 1, \ + .parent_data = gcc_pxo, \ + .num_parents = ARRAY_SIZE(gcc_pxo), \ }, \ } @@ -56,8 +64,8 @@ .hw.init = &(struct clk_init_data){ \ .ops = &clk_rpm_xo_ops, \ .name = #_name, \ - .parent_names = (const char *[]){ "cxo_board" }, \ - .num_parents = 1, \ + .parent_data = gcc_cxo, \ + .num_parents = ARRAY_SIZE(gcc_cxo), \ }, \ } @@ -68,8 +76,8 @@ .hw.init = &(struct clk_init_data){ \ .ops = &clk_rpm_fixed_ops, \ .name = #_name, \ - .parent_names = (const char *[]){ "pxo" }, \ - .num_parents = 1, \ + .parent_data = gcc_pxo, \ + .num_parents = ARRAY_SIZE(gcc_pxo), \ }, \ } From patchwork Tue Jul 5 20:28:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 587802 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EBA10CCA47C for ; Tue, 5 Jul 2022 20:56:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229582AbiGEU4L (ORCPT ); Tue, 5 Jul 2022 16:56:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33664 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231238AbiGEU4H (ORCPT ); Tue, 5 Jul 2022 16:56:07 -0400 Received: from mail-ed1-x533.google.com (mail-ed1-x533.google.com [IPv6:2a00:1450:4864:20::533]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DDF0915A09; Tue, 5 Jul 2022 13:56:05 -0700 (PDT) Received: by mail-ed1-x533.google.com with SMTP id x10so9489390edd.13; Tue, 05 Jul 2022 13:56:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=n1pkrcMQjBz/FRxe7ar3hA0ekF4WVND5LanMRiZumKU=; b=Cktgf5jOYaT0/fJ4U/vliL1vCroasJ1MYYEkoQjd5JUv8UDT+EFyINLQQctotsDc1Z Gzxgy5nbB+HS2Wft2gk1d+MLm4L0iZwFV/I3LFZ/mvXr8o/X2ioqeMMLtEo/yQMcNikU dtLBLeebRJpyTZ5M+GeHMgJJ2acji1jHpTo1tUobdA54W17LdnBo6/jyBd1e+PfA21gv yBC+Ogj5PB0L5p923hExgZ2aJMsGGCjMEApbK7gnvBGCYZrccHl0w+7s+7j0WNuUZ4gA 3Eg3leVDbQimeyeqtTk4zVHh+ljUaienm86hw98jPxPctMn9FESF6rNl5/77mCSH8V0f uuTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=n1pkrcMQjBz/FRxe7ar3hA0ekF4WVND5LanMRiZumKU=; b=F8PHBdHybxXbSRWfdZkQdwJzEde6rJsavadmU/Mf6mT0y8ZfNisCxmH9aJjWcghR2C 9B/sLyMjcHgTllwchtGyJFVvQdJ9uwBROtlENQrXVbRbDwtIpRk4O8PqDPEGho5pLVWX xgBE8rKROvHcEU/zkFa5htZLYCsshfJYPG98DZ73v2m2VX71tazS+eONVQtD4fBzGik8 jt2ER2MaAyT1LG3GNFaF7mqmfZckhOm/XMo+OITMhD68mmLIL+gHP2r8PGrSrXcjGvLK dS4onD0/vhFMFE0oJG848X12N0+liEfMC8DLEASUUqbyM0ucJDpOAR/Mubx772hVFIba 6Zbg== X-Gm-Message-State: AJIora9yKsJKvqfIoFtl3OPsWRy3fJ8/8xw7HUYe5EniI+Rllf9oGPkA SmSpf/3aNP+WPVAaD9r5hN3ptIxYlyg= X-Google-Smtp-Source: AGRyM1tLFqjqxPY+jlqMoptKtwWGGw2zkxjJbSsgeRR7luOINLMKNJPz3To1K/2QbVw6uV+coOAZsA== X-Received: by 2002:aa7:d542:0:b0:43a:875:64d3 with SMTP id u2-20020aa7d542000000b0043a087564d3mr24938401edr.139.1657054564380; Tue, 05 Jul 2022 13:56:04 -0700 (PDT) Received: from localhost.localdomain (93-42-70-190.ip85.fastwebnet.it. [93.42.70.190]) by smtp.googlemail.com with ESMTPSA id dm3-20020a05640222c300b0043a70c51470sm3836956edb.55.2022.07.05.13.56.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 13:56:04 -0700 (PDT) From: Christian Marangi To: Bjorn Andersson , Andy Gross , Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Christian Marangi Subject: [PATCH 4/5] ARM: dts: qcom: add pxo/cxo clock-output-names for ipq8064 Date: Tue, 5 Jul 2022 22:28:36 +0200 Message-Id: <20220705202837.667-5-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220705202837.667-1-ansuelsmth@gmail.com> References: <20220705202837.667-1-ansuelsmth@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Drivers expect to call pxo/cxo_board clock as pxo/cxo. Use clock-output-names to set the correct naming for these fixed clock to save drivers that are migrating to parent_data and still use parent_names. Signed-off-by: Christian Marangi --- arch/arm/boot/dts/qcom-ipq8064.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/boot/dts/qcom-ipq8064.dtsi b/arch/arm/boot/dts/qcom-ipq8064.dtsi index 1425a4e4283f..720e27e29627 100644 --- a/arch/arm/boot/dts/qcom-ipq8064.dtsi +++ b/arch/arm/boot/dts/qcom-ipq8064.dtsi @@ -302,12 +302,14 @@ cxo_board: cxo_board { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <25000000>; + clock-output-names = "cxo"; }; pxo_board: pxo_board { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <25000000>; + clock-output-names = "pxo"; }; sleep_clk: sleep_clk { From patchwork Tue Jul 5 20:28:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 587803 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D9715CCA481 for ; Tue, 5 Jul 2022 20:56:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231908AbiGEU4K (ORCPT ); Tue, 5 Jul 2022 16:56:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231351AbiGEU4H (ORCPT ); Tue, 5 Jul 2022 16:56:07 -0400 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 DDFDE15A0B; Tue, 5 Jul 2022 13:56:05 -0700 (PDT) Received: by mail-ej1-x62c.google.com with SMTP id sb34so23654933ejc.11; Tue, 05 Jul 2022 13:56:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=kUlxRQ1of3eu4XW5c6JjZr01Kt72atQDrgao/HtGT8o=; b=miyLqZVDr95MvsZByIU18n/yp0Ra7HJ0BNVK4mKXeV8tRMGr3ngt0Y9Hnl+pOI+2D7 cWXICRa2OW2HyJYaHu6HORU/kZ3WqTdG7miqXV21G2vsxwnX/R3nyi1XaPIq2bKA8QXy Bg3zeqnHhbw/ItfO6WAKVAZhFXtkF0kZMQD8CRPZH95jrc/m0eRzIXKZZ/vDePGkXxLK roWoSfLaGK0KMGDHH03HaUiWlReh+SRdtbDTr0iEITBUEnPcZMi4JDY7TP6MNJaYDfrb vyTQ1QxIEkMorAiI9PcV2VZamL8+/oaljcHWnN3ebCazzKpEqeUWFADs6ed7LbELLTZq Suuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=kUlxRQ1of3eu4XW5c6JjZr01Kt72atQDrgao/HtGT8o=; b=JotKsZ+z+OAvR+uzXg+HWeU8Y4b9e8lpo2v8K1AilGkZtqZNnCsWkYcqfU6+3KCKcE qvqURq/Euk/RFkWo0NYEjQA8NRPOHRoKcZK8P+cuwcWrM0fMF1PCksJ1WfhyBgAljXXe WN3YtOyRQWzQvIfbVjsGeoonam73V3Qex6gZd2/MR12SU/MY7zIR5FX9+9pd/SAdT2Fa A2Sn+pA0s5KPDEEkNRutKVD1s3BaHTCXepbHpK/nmozjh97ZN3gEnfkAc1P/9JA12XAy PBt8uY5Bx6oE3iDYr7HUOnxEYBdmce+M7z8Q5UzYWN02iATY39zwlSJDvLRilvsxEkBS aJyg== X-Gm-Message-State: AJIora/H+E3+6Lc6cXa3Q4h8U8+jfsCl9fw9soPJw6jZlZpRPWUqe5x6 pY41tWYv8TFXmhfgP6iyAbg= X-Google-Smtp-Source: AGRyM1tkrgcFjXCiCX34Lg+Lnqb+x2ssJiae/UJXSnmXTeK4u1T3oF/r+ctDrKsKTu5KdSyy0vKxdw== X-Received: by 2002:a17:906:5189:b0:722:dc81:222a with SMTP id y9-20020a170906518900b00722dc81222amr35711482ejk.502.1657054565390; Tue, 05 Jul 2022 13:56:05 -0700 (PDT) Received: from localhost.localdomain (93-42-70-190.ip85.fastwebnet.it. [93.42.70.190]) by smtp.googlemail.com with ESMTPSA id dm3-20020a05640222c300b0043a70c51470sm3836956edb.55.2022.07.05.13.56.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 13:56:05 -0700 (PDT) From: Christian Marangi To: Bjorn Andersson , Andy Gross , Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Christian Marangi Subject: [PATCH 5/5] clk: qcom: gcc-ipq806x: remove cc_register_board for pxo and cxo Date: Tue, 5 Jul 2022 22:28:37 +0200 Message-Id: <20220705202837.667-6-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220705202837.667-1-ansuelsmth@gmail.com> References: <20220705202837.667-1-ansuelsmth@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Now that these clock are defined as fixed clk in dts, we can drop the register_board_clk for cxo_board and pxo_board in gcc_ipq806x_probe. Signed-off-by: Christian Marangi --- drivers/clk/qcom/gcc-ipq806x.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/clk/qcom/gcc-ipq806x.c b/drivers/clk/qcom/gcc-ipq806x.c index 718de17a1e60..883629de2751 100644 --- a/drivers/clk/qcom/gcc-ipq806x.c +++ b/drivers/clk/qcom/gcc-ipq806x.c @@ -3384,14 +3384,6 @@ static int gcc_ipq806x_probe(struct platform_device *pdev) struct regmap *regmap; int ret; - ret = qcom_cc_register_board_clk(dev, "cxo_board", "cxo", 25000000); - if (ret) - return ret; - - ret = qcom_cc_register_board_clk(dev, "pxo_board", "pxo", 25000000); - if (ret) - return ret; - if (of_machine_is_compatible("qcom,ipq8065")) { ubi32_core1_src_clk.freq_tbl = clk_tbl_nss_ipq8065; ubi32_core2_src_clk.freq_tbl = clk_tbl_nss_ipq8065;