linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "周琰杰 (Zhou Yanjie)" <zhouyanjie@wanyeetech.com>
To: daniel.lezcano@linaro.org, tglx@linutronix.de
Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org,
	dongsheng.qiu@ingenic.com, aric.pzqi@ingenic.com,
	rick.tyliu@ingenic.com, sihui.liu@ingenic.com,
	jun.jiang@ingenic.com, sernia.zhou@foxmail.com,
	paul@crapouillou.net
Subject: [PATCH v2 1/2] clocksource: Ingenic: Rename unreasonable array names.
Date: Sat,  5 Jun 2021 00:31:45 +0800	[thread overview]
Message-ID: <1622824306-30987-2-git-send-email-zhouyanjie@wanyeetech.com> (raw)
In-Reply-To: <1622824306-30987-1-git-send-email-zhouyanjie@wanyeetech.com>

1.Rename the "ingenic_ost_clk_info[]" to "x1000_ost_clk_info[]"
  to facilitate the addition of OST support for X2000 SoC in a
  later commit.
2.When the OST support for X2000 SoC is added, there will be two
  compatible strings, so renaming "ingenic_ost_of_match[]" to
  "ingenic_ost_of_matches[]" is more reasonable.
3.Remove the unnecessary comma in "ingenic_ost_of_matches[]" to
  reduce code size as much as possible.

Signed-off-by: 周琰杰 (Zhou Yanjie) <zhouyanjie@wanyeetech.com>
---

Notes:
    v2:
    New patch.

 drivers/clocksource/ingenic-sysost.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/clocksource/ingenic-sysost.c b/drivers/clocksource/ingenic-sysost.c
index e77d584..a129840 100644
--- a/drivers/clocksource/ingenic-sysost.c
+++ b/drivers/clocksource/ingenic-sysost.c
@@ -186,7 +186,7 @@ static const struct clk_ops ingenic_ost_global_timer_ops = {
 
 static const char * const ingenic_ost_clk_parents[] = { "ext" };
 
-static const struct ingenic_ost_clk_info ingenic_ost_clk_info[] = {
+static const struct ingenic_ost_clk_info x1000_ost_clk_info[] = {
 	[OST_CLK_PERCPU_TIMER] = {
 		.init_data = {
 			.name = "percpu timer",
@@ -414,14 +414,14 @@ static const struct ingenic_soc_info x1000_soc_info = {
 	.num_channels = 2,
 };
 
-static const struct of_device_id __maybe_unused ingenic_ost_of_match[] __initconst = {
-	{ .compatible = "ingenic,x1000-ost", .data = &x1000_soc_info, },
+static const struct of_device_id __maybe_unused ingenic_ost_of_matches[] __initconst = {
+	{ .compatible = "ingenic,x1000-ost", .data = &x1000_soc_info },
 	{ /* sentinel */ }
 };
 
 static int __init ingenic_ost_probe(struct device_node *np)
 {
-	const struct of_device_id *id = of_match_node(ingenic_ost_of_match, np);
+	const struct of_device_id *id = of_match_node(ingenic_ost_of_matches, np);
 	struct ingenic_ost *ost;
 	unsigned int i;
 	int ret;
@@ -462,7 +462,7 @@ static int __init ingenic_ost_probe(struct device_node *np)
 	ost->clocks->num = ost->soc_info->num_channels;
 
 	for (i = 0; i < ost->clocks->num; i++) {
-		ret = ingenic_ost_register_clock(ost, i, &ingenic_ost_clk_info[i], ost->clocks);
+		ret = ingenic_ost_register_clock(ost, i, &x1000_ost_clk_info[i], ost->clocks);
 		if (ret) {
 			pr_crit("%s: Cannot register clock %d\n", __func__, i);
 			goto err_unregister_ost_clocks;
-- 
2.7.4


  reply	other threads:[~2021-06-04 16:32 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-04 16:31 Add SMP/SMT support for sysost driver 周琰杰 (Zhou Yanjie)
2021-06-04 16:31 ` 周琰杰 (Zhou Yanjie) [this message]
2021-06-16 13:56   ` [PATCH v2 1/2] clocksource: Ingenic: Rename unreasonable array names Daniel Lezcano
2021-06-18 16:03   ` [tip: timers/core] clocksource/drivers/ingenic: " tip-bot2 for 周琰杰
2021-06-04 16:31 ` [PATCH v2 2/2] clocksource: Ingenic: Add SMP/SMT support for sysost driver 周琰杰 (Zhou Yanjie)
2021-06-10 15:30   ` Paul Cercueil
2021-06-11 15:31     ` Zhou Yanjie
2021-06-11 15:44       ` Paul Cercueil
2021-06-12 15:48         ` 周琰杰
2021-06-14 16:42           ` Paul Cercueil
2021-06-16 14:57             ` Daniel Lezcano

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=1622824306-30987-2-git-send-email-zhouyanjie@wanyeetech.com \
    --to=zhouyanjie@wanyeetech.com \
    --cc=aric.pzqi@ingenic.com \
    --cc=daniel.lezcano@linaro.org \
    --cc=dongsheng.qiu@ingenic.com \
    --cc=jun.jiang@ingenic.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=paul@crapouillou.net \
    --cc=rick.tyliu@ingenic.com \
    --cc=sernia.zhou@foxmail.com \
    --cc=sihui.liu@ingenic.com \
    --cc=tglx@linutronix.de \
    /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).