linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rajendra Nayak <rnayak@codeaurora.org>
To: Taniya Das <tdas@codeaurora.org>, Stephen Boyd <sboyd@kernel.org>,
	Michael Turquette <mturquette@baylibre.com>,
	robh+dt@kernel.org
Cc: David Brown <david.brown@linaro.org>,
	linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org,
	linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org
Subject: Re: [PATCH v3 3/3] clk: qcom: Add Global Clock controller (GCC) driver for SC7180
Date: Thu, 19 Sep 2019 16:38:19 +0530	[thread overview]
Message-ID: <74643831-1a58-e279-aca3-8753f5fcbe04@codeaurora.org> (raw)
In-Reply-To: <20190918095018.17979-4-tdas@codeaurora.org>

[]..

> +static struct clk_rcg_dfs_data gcc_dfs_clocks[] = {
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap0_s0_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap0_s1_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap0_s2_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap0_s3_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap0_s4_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap0_s5_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap1_s0_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap1_s1_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap1_s2_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap1_s3_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap1_s4_clk_src),
> +	DEFINE_RCG_DFS(gcc_qupv3_wrap1_s5_clk_src),
> +};

this fails to build..

In file included from drivers/clk/qcom/gcc-sc7180.c:17:0:
drivers/clk/qcom/gcc-sc7180.c:2429:17: error: ‘gcc_qupv3_wrap0_s0_clk_src_src’ undeclared here (not in a function)
   DEFINE_RCG_DFS(gcc_qupv3_wrap0_s0_clk_src),
                  ^
drivers/clk/qcom/clk-rcg.h:171:12: note: in definition of macro ‘DEFINE_RCG_DFS’
   { .rcg = &r##_src, .init = &r##_init }
             ^
drivers/clk/qcom/gcc-sc7180.c:2430:17: error: ‘gcc_qupv3_wrap0_s1_clk_src_src’ undeclared here (not in a function)
   DEFINE_RCG_DFS(gcc_qupv3_wrap0_s1_clk_src),
                  ^
drivers/clk/qcom/clk-rcg.h:171:12: note: in definition of macro ‘DEFINE_RCG_DFS’
   { .rcg = &r##_src, .init = &r##_init }
             ^
Perhaps you should drop _src here and in the clk_init_data names.

> +
> +static const struct regmap_config gcc_sc7180_regmap_config = {
> +	.reg_bits = 32,
> +	.reg_stride = 4,
> +	.val_bits = 32,
> +	.max_register = 0x18208c,
> +	.fast_io = true,
> +};
> +
> +static const struct qcom_cc_desc gcc_sc7180_desc = {
> +	.config = &gcc_sc7180_regmap_config,
> +	.clk_hws = gcc_sc7180_hws,
> +	.num_clk_hws = ARRAY_SIZE(gcc_sc7180_hws),
> +	.clks = gcc_sc7180_clocks,
> +	.num_clks = ARRAY_SIZE(gcc_sc7180_clocks),
> +	.resets = gcc_sc7180_resets,
> +	.num_resets = ARRAY_SIZE(gcc_sc7180_resets),
> +	.gdscs = gcc_sc7180_gdscs,
> +	.num_gdscs = ARRAY_SIZE(gcc_sc7180_gdscs),
> +};
> +
> +static const struct of_device_id gcc_sc7180_match_table[] = {
> +	{ .compatible = "qcom,gcc-sc7180" },
> +	{ }
> +};
> +MODULE_DEVICE_TABLE(of, gcc_sc7180_match_table);
> +
> +static int gcc_sc7180_probe(struct platform_device *pdev)
> +{
> +	struct regmap *regmap;
> +	int ret;
> +
> +	regmap = qcom_cc_map(pdev, &gcc_sc7180_desc);
> +	if (IS_ERR(regmap))
> +		return PTR_ERR(regmap);
> +
> +	/*
> +	 * Disable the GPLL0 active input to MM blocks, NPU
> +	 * and GPU via MISC registers.
> +	 */
> +	regmap_update_bits(regmap, GCC_MMSS_MISC, 0x3, 0x3);
> +	regmap_update_bits(regmap, GCC_NPU_MISC, 0x3, 0x3);
> +	regmap_update_bits(regmap, GCC_GPU_MISC, 0x3, 0x3);
> +
> +	ret = qcom_cc_register_rcg_dfs(regmap, gcc_dfs_clocks,
> +					ARRAY_SIZE(gcc_dfs_clocks));
> +	if (ret)
> +		return ret;
> +
> +	return qcom_cc_really_probe(pdev, &gcc_sc7180_desc, regmap);
> +}
> +
> +static struct platform_driver gcc_sc7180_driver = {
> +	.probe = gcc_sc7180_probe,
> +	.driver = {
> +		.name = "gcc-sc7180",
> +		.of_match_table = gcc_sc7180_match_table,
> +	},
> +};
> +
> +static int __init gcc_sc7180_init(void)
> +{
> +	return platform_driver_register(&gcc_sc7180_driver);
> +}
> +subsys_initcall(gcc_sc7180_init);
> +
> +static void __exit gcc_sc7180_exit(void)
> +{
> +	platform_driver_unregister(&gcc_sc7180_driver);
> +}
> +module_exit(gcc_sc7180_exit);
> +
> +MODULE_DESCRIPTION("QTI GCC SC7180 Driver");
> +MODULE_LICENSE("GPL v2");
> --
> Qualcomm INDIA, on behalf of Qualcomm Innovation Center, Inc.is a member
> of the Code Aurora Forum, hosted by the  Linux Foundation.
> 

-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation

  reply	other threads:[~2019-09-19 11:08 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-18  9:50 [PATCH v3 0/3] Add Global Clock controller (GCC) driver for SC7180 Taniya Das
2019-09-18  9:50 ` [PATCH v3 1/3] clk: qcom: rcg: update the DFS macro for RCG Taniya Das
2019-09-18  9:50 ` [PATCH v3 2/3] dt-bindings: clk: qcom: Add YAML schemas for the GCC clock bindings Taniya Das
2019-09-18 17:52   ` Matthias Kaehlcke
2019-09-23  6:33     ` Taniya Das
2019-09-27 17:27   ` Rob Herring
2019-10-14 10:16     ` Taniya Das
     [not found]   ` <20190918212614.448FC20882@mail.kernel.org>
2019-10-14 10:17     ` Taniya Das
2019-09-18  9:50 ` [PATCH v3 3/3] clk: qcom: Add Global Clock controller (GCC) driver for SC7180 Taniya Das
2019-09-19 11:08   ` Rajendra Nayak [this message]
2019-09-20  4:00     ` Taniya Das
2019-09-20  4:44       ` Rajendra Nayak
     [not found]   ` <20190918213946.DC03521924@mail.kernel.org>
2019-09-23  8:01     ` Taniya Das
2019-09-24 23:12       ` Stephen Boyd
2019-09-25 11:20         ` Taniya Das
2019-09-25 13:03           ` Stephen Boyd
2019-09-27  7:37             ` Taniya Das
2019-10-01 14:38               ` Stephen Boyd
2019-10-03 10:31                 ` Taniya Das
2019-10-03 16:01                   ` Stephen Boyd
2019-10-04 17:39                     ` Taniya Das
2019-10-04 23:20                       ` Stephen Boyd
2019-10-09  9:19                         ` Taniya Das
2019-10-10  4:16                           ` Stephen Boyd
2019-10-11 10:28                             ` Taniya Das

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=74643831-1a58-e279-aca3-8753f5fcbe04@codeaurora.org \
    --to=rnayak@codeaurora.org \
    --cc=david.brown@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-soc@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=robh+dt@kernel.org \
    --cc=sboyd@kernel.org \
    --cc=tdas@codeaurora.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).