All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lubomir Rintel <lkundrak@v3.sk>
To: Stephen Boyd <sboyd@kernel.org>
Cc: Michael Turquette <mturquette@baylibre.com>,
	Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	linux-clk@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	Lubomir Rintel <lkundrak@v3.sk>
Subject: [PATCH v2 02/17] clk: mmp2: Constify some strings
Date: Mon,  9 Mar 2020 20:42:39 +0100	[thread overview]
Message-ID: <20200309194254.29009-3-lkundrak@v3.sk> (raw)
In-Reply-To: <20200309194254.29009-1-lkundrak@v3.sk>

All the parent clock names for the muxes are constant. Add const.

Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
---
 drivers/clk/mmp/clk-mix.c     |  2 +-
 drivers/clk/mmp/clk-of-mmp2.c | 13 +++++++------
 drivers/clk/mmp/clk.h         |  4 ++--
 3 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/drivers/clk/mmp/clk-mix.c b/drivers/clk/mmp/clk-mix.c
index d2cd36c54474f..7a351ec65564e 100644
--- a/drivers/clk/mmp/clk-mix.c
+++ b/drivers/clk/mmp/clk-mix.c
@@ -441,7 +441,7 @@ const struct clk_ops mmp_clk_mix_ops = {
 
 struct clk *mmp_clk_register_mix(struct device *dev,
 					const char *name,
-					const char **parent_names,
+					const char * const *parent_names,
 					u8 num_parents,
 					unsigned long flags,
 					struct mmp_clk_mix_config *config,
diff --git a/drivers/clk/mmp/clk-of-mmp2.c b/drivers/clk/mmp/clk-of-mmp2.c
index 6e71591e63a00..ee086d9714160 100644
--- a/drivers/clk/mmp/clk-of-mmp2.c
+++ b/drivers/clk/mmp/clk-of-mmp2.c
@@ -127,16 +127,16 @@ static void mmp2_pll_init(struct mmp2_clk_unit *pxa_unit)
 static DEFINE_SPINLOCK(uart0_lock);
 static DEFINE_SPINLOCK(uart1_lock);
 static DEFINE_SPINLOCK(uart2_lock);
-static const char *uart_parent_names[] = {"uart_pll", "vctcxo"};
+static const char * const uart_parent_names[] = {"uart_pll", "vctcxo"};
 
 static DEFINE_SPINLOCK(ssp0_lock);
 static DEFINE_SPINLOCK(ssp1_lock);
 static DEFINE_SPINLOCK(ssp2_lock);
 static DEFINE_SPINLOCK(ssp3_lock);
-static const char *ssp_parent_names[] = {"vctcxo_4", "vctcxo_2", "vctcxo", "pll1_16"};
+static const char * const ssp_parent_names[] = {"vctcxo_4", "vctcxo_2", "vctcxo", "pll1_16"};
 
 static DEFINE_SPINLOCK(timer_lock);
-static const char *timer_parent_names[] = {"clk32", "vctcxo_4", "vctcxo_2", "vctcxo"};
+static const char * const timer_parent_names[] = {"clk32", "vctcxo_4", "vctcxo_2", "vctcxo"};
 
 static DEFINE_SPINLOCK(reset_lock);
 
@@ -190,7 +190,7 @@ static void mmp2_apb_periph_clk_init(struct mmp2_clk_unit *pxa_unit)
 }
 
 static DEFINE_SPINLOCK(sdh_lock);
-static const char *sdh_parent_names[] = {"pll1_4", "pll2", "usb_pll", "pll1"};
+static const char * const sdh_parent_names[] = {"pll1_4", "pll2", "usb_pll", "pll1"};
 static struct mmp_clk_mix_config sdh_mix_config = {
 	.reg_info = DEFINE_MIX_REG_INFO(4, 10, 2, 8, 32),
 };
@@ -201,11 +201,12 @@ static DEFINE_SPINLOCK(usbhsic1_lock);
 
 static DEFINE_SPINLOCK(disp0_lock);
 static DEFINE_SPINLOCK(disp1_lock);
-static const char *disp_parent_names[] = {"pll1", "pll1_16", "pll2", "vctcxo"};
+static const char * const disp_parent_names[] = {"pll1", "pll1_16", "pll2", "vctcxo"};
 
 static DEFINE_SPINLOCK(ccic0_lock);
 static DEFINE_SPINLOCK(ccic1_lock);
-static const char *ccic_parent_names[] = {"pll1_2", "pll1_16", "vctcxo"};
+static const char * const ccic_parent_names[] = {"pll1_2", "pll1_16", "vctcxo"};
+
 static struct mmp_clk_mix_config ccic0_mix_config = {
 	.reg_info = DEFINE_MIX_REG_INFO(4, 17, 2, 6, 32),
 };
diff --git a/drivers/clk/mmp/clk.h b/drivers/clk/mmp/clk.h
index 5bcbced3f458e..37d1e1d7b664c 100644
--- a/drivers/clk/mmp/clk.h
+++ b/drivers/clk/mmp/clk.h
@@ -97,7 +97,7 @@ struct mmp_clk_mix {
 extern const struct clk_ops mmp_clk_mix_ops;
 extern struct clk *mmp_clk_register_mix(struct device *dev,
 					const char *name,
-					const char **parent_names,
+					const char * const *parent_names,
 					u8 num_parents,
 					unsigned long flags,
 					struct mmp_clk_mix_config *config,
@@ -193,7 +193,7 @@ void mmp_register_gate_clks(struct mmp_clk_unit *unit,
 struct mmp_param_mux_clk {
 	unsigned int id;
 	char *name;
-	const char **parent_name;
+	const char * const *parent_name;
 	u8 num_parents;
 	unsigned long flags;
 	unsigned long offset;
-- 
2.25.1


  parent reply	other threads:[~2020-03-09 19:43 UTC|newest]

Thread overview: 56+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-09 19:42 [PATCH v2 00/17] clk: mmp2: MMP2 CLK Update Lubomir Rintel
2020-03-09 19:42 ` [PATCH v2 01/17] clk: mmp2: Remove a unused prototype Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` Stephen Boyd
2020-03-09 19:42 ` Lubomir Rintel [this message]
2020-03-21  1:24   ` [PATCH v2 02/17] clk: mmp2: Constify some strings Stephen Boyd
2020-03-21  1:24     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 03/17] dt-bindings: clock: Convert marvell,mmp2-clock to json-schema Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` [PATCH v2 03/17] dt-bindings: clock: Convert marvell, mmp2-clock " Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 04/17] clk: mmp2: Add support for PLL clock sources Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` Stephen Boyd
2020-04-06 19:30   ` Guenter Roeck
2020-04-06 19:30     ` Guenter Roeck
2020-04-09  8:32     ` Stephen Boyd
2020-04-09  8:32       ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 05/17] clk: mmp2: Stop pretending PLL outputs are constant Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 06/17] dt-bindings: clock: Add MMP3 compatible string Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 07/17] clk: mmp2: Check for MMP3 Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 08/17] dt-bindings: marvell,mmp2: Add clock ids for MMP3 PLLs Lubomir Rintel
2020-03-21  1:24   ` Stephen Boyd
2020-03-21  1:24     ` [PATCH v2 08/17] dt-bindings: marvell, mmp2: " Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 09/17] clk: mmp2: Add PLLs that are available on MMP3 Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 10/17] ARM: dts: mmp3: Use the MMP3 compatible string for /clocks Lubomir Rintel
2020-03-21  1:20   ` Stephen Boyd
2020-03-21  1:20     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 11/17] dt-bindings: marvell,mmp2: Add clock ids for the GPU clocks Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` [PATCH v2 11/17] dt-bindings: marvell, mmp2: " Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 12/17] clk: mmp2: add " Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 13/17] dt-bindings: marvell,mmp2: Add clock ids for the thermal sensors Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` [PATCH v2 13/17] dt-bindings: marvell, mmp2: " Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 14/17] clk: mmp2: Add clocks " Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 15/17] dt-bindings: marvell,mmp2: Add clock id for the fifth SD HCI on MMP3 Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` [PATCH v2 15/17] dt-bindings: marvell, mmp2: " Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 16/17] clk: mmp2: Add clock for " Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` Stephen Boyd
2020-03-09 19:42 ` [PATCH v2 17/17] clk: mmp2: Fix bit masks for LCDC I/O and pixel clocks Lubomir Rintel
2020-03-21  1:25   ` Stephen Boyd
2020-03-21  1:25     ` Stephen Boyd

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=20200309194254.29009-3-lkundrak@v3.sk \
    --to=lkundrak@v3.sk \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mturquette@baylibre.com \
    --cc=robh+dt@kernel.org \
    --cc=sboyd@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.