All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tero Kristo <t-kristo@ti.com>
To: <linux-clk@vger.kernel.org>, <tony@atomide.com>,
	<mturquette@baylibre.com>, <sboyd@codeaurora.org>,
	<linux-omap@vger.kernel.org>
Cc: <linux-arm-kernel@lists.infradead.org>
Subject: [PATCHv2 07/15] clk: ti: enforce const types on string arrays
Date: Sat, 11 Mar 2017 14:49:58 +0200	[thread overview]
Message-ID: <1489236606-24023-8-git-send-email-t-kristo@ti.com> (raw)
In-Reply-To: <1489236606-24023-1-git-send-email-t-kristo@ti.com>

Constant string arrays should use const char * const instead of just
const char *. Change the implementations using these to proper type.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
---
 drivers/clk/ti/clock.h     | 2 +-
 drivers/clk/ti/composite.c | 2 +-
 drivers/clk/ti/mux.c       | 8 ++++----
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/clk/ti/clock.h b/drivers/clk/ti/clock.h
index ecf82d8..cb906a1 100644
--- a/drivers/clk/ti/clock.h
+++ b/drivers/clk/ti/clock.h
@@ -86,7 +86,7 @@ struct ti_clk_mux {
 	int num_parents;
 	u16 reg;
 	u8 module;
-	const char **parents;
+	const char * const *parents;
 	u16 flags;
 };
 
diff --git a/drivers/clk/ti/composite.c b/drivers/clk/ti/composite.c
index 3f60f99..beea894 100644
--- a/drivers/clk/ti/composite.c
+++ b/drivers/clk/ti/composite.c
@@ -124,7 +124,7 @@ struct clk *ti_clk_register_composite(struct ti_clk *setup)
 	struct clk_hw *mux;
 	struct clk_hw *div;
 	int num_parents = 1;
-	const char **parent_names = NULL;
+	const char * const *parent_names = NULL;
 	struct clk *clk;
 	int ret;
 
diff --git a/drivers/clk/ti/mux.c b/drivers/clk/ti/mux.c
index 0da149e..3cc6db4 100644
--- a/drivers/clk/ti/mux.c
+++ b/drivers/clk/ti/mux.c
@@ -97,10 +97,10 @@ static int ti_clk_mux_set_parent(struct clk_hw *hw, u8 index)
 };
 
 static struct clk *_register_mux(struct device *dev, const char *name,
-				 const char **parent_names, u8 num_parents,
-				 unsigned long flags, void __iomem *reg,
-				 u8 shift, u32 mask, u8 clk_mux_flags,
-				 u32 *table)
+				 const char * const *parent_names,
+				 u8 num_parents, unsigned long flags,
+				 void __iomem *reg, u8 shift, u32 mask,
+				 u8 clk_mux_flags, u32 *table)
 {
 	struct clk_mux *mux;
 	struct clk *clk;
-- 
1.9.1

WARNING: multiple messages have this Message-ID (diff)
From: Tero Kristo <t-kristo@ti.com>
To: linux-clk@vger.kernel.org, tony@atomide.com,
	mturquette@baylibre.com, sboyd@codeaurora.org,
	linux-omap@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv2 07/15] clk: ti: enforce const types on string arrays
Date: Sat, 11 Mar 2017 14:49:58 +0200	[thread overview]
Message-ID: <1489236606-24023-8-git-send-email-t-kristo@ti.com> (raw)
In-Reply-To: <1489236606-24023-1-git-send-email-t-kristo@ti.com>

Constant string arrays should use const char * const instead of just
const char *. Change the implementations using these to proper type.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
---
 drivers/clk/ti/clock.h     | 2 +-
 drivers/clk/ti/composite.c | 2 +-
 drivers/clk/ti/mux.c       | 8 ++++----
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/clk/ti/clock.h b/drivers/clk/ti/clock.h
index ecf82d8..cb906a1 100644
--- a/drivers/clk/ti/clock.h
+++ b/drivers/clk/ti/clock.h
@@ -86,7 +86,7 @@ struct ti_clk_mux {
 	int num_parents;
 	u16 reg;
 	u8 module;
-	const char **parents;
+	const char * const *parents;
 	u16 flags;
 };
 
diff --git a/drivers/clk/ti/composite.c b/drivers/clk/ti/composite.c
index 3f60f99..beea894 100644
--- a/drivers/clk/ti/composite.c
+++ b/drivers/clk/ti/composite.c
@@ -124,7 +124,7 @@ struct clk *ti_clk_register_composite(struct ti_clk *setup)
 	struct clk_hw *mux;
 	struct clk_hw *div;
 	int num_parents = 1;
-	const char **parent_names = NULL;
+	const char * const *parent_names = NULL;
 	struct clk *clk;
 	int ret;
 
diff --git a/drivers/clk/ti/mux.c b/drivers/clk/ti/mux.c
index 0da149e..3cc6db4 100644
--- a/drivers/clk/ti/mux.c
+++ b/drivers/clk/ti/mux.c
@@ -97,10 +97,10 @@ static int ti_clk_mux_set_parent(struct clk_hw *hw, u8 index)
 };
 
 static struct clk *_register_mux(struct device *dev, const char *name,
-				 const char **parent_names, u8 num_parents,
-				 unsigned long flags, void __iomem *reg,
-				 u8 shift, u32 mask, u8 clk_mux_flags,
-				 u32 *table)
+				 const char * const *parent_names,
+				 u8 num_parents, unsigned long flags,
+				 void __iomem *reg, u8 shift, u32 mask,
+				 u8 clk_mux_flags, u32 *table)
 {
 	struct clk_mux *mux;
 	struct clk *clk;
-- 
1.9.1


WARNING: multiple messages have this Message-ID (diff)
From: t-kristo@ti.com (Tero Kristo)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv2 07/15] clk: ti: enforce const types on string arrays
Date: Sat, 11 Mar 2017 14:49:58 +0200	[thread overview]
Message-ID: <1489236606-24023-8-git-send-email-t-kristo@ti.com> (raw)
In-Reply-To: <1489236606-24023-1-git-send-email-t-kristo@ti.com>

Constant string arrays should use const char * const instead of just
const char *. Change the implementations using these to proper type.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
---
 drivers/clk/ti/clock.h     | 2 +-
 drivers/clk/ti/composite.c | 2 +-
 drivers/clk/ti/mux.c       | 8 ++++----
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/clk/ti/clock.h b/drivers/clk/ti/clock.h
index ecf82d8..cb906a1 100644
--- a/drivers/clk/ti/clock.h
+++ b/drivers/clk/ti/clock.h
@@ -86,7 +86,7 @@ struct ti_clk_mux {
 	int num_parents;
 	u16 reg;
 	u8 module;
-	const char **parents;
+	const char * const *parents;
 	u16 flags;
 };
 
diff --git a/drivers/clk/ti/composite.c b/drivers/clk/ti/composite.c
index 3f60f99..beea894 100644
--- a/drivers/clk/ti/composite.c
+++ b/drivers/clk/ti/composite.c
@@ -124,7 +124,7 @@ struct clk *ti_clk_register_composite(struct ti_clk *setup)
 	struct clk_hw *mux;
 	struct clk_hw *div;
 	int num_parents = 1;
-	const char **parent_names = NULL;
+	const char * const *parent_names = NULL;
 	struct clk *clk;
 	int ret;
 
diff --git a/drivers/clk/ti/mux.c b/drivers/clk/ti/mux.c
index 0da149e..3cc6db4 100644
--- a/drivers/clk/ti/mux.c
+++ b/drivers/clk/ti/mux.c
@@ -97,10 +97,10 @@ static int ti_clk_mux_set_parent(struct clk_hw *hw, u8 index)
 };
 
 static struct clk *_register_mux(struct device *dev, const char *name,
-				 const char **parent_names, u8 num_parents,
-				 unsigned long flags, void __iomem *reg,
-				 u8 shift, u32 mask, u8 clk_mux_flags,
-				 u32 *table)
+				 const char * const *parent_names,
+				 u8 num_parents, unsigned long flags,
+				 void __iomem *reg, u8 shift, u32 mask,
+				 u8 clk_mux_flags, u32 *table)
 {
 	struct clk_mux *mux;
 	struct clk *clk;
-- 
1.9.1

  parent reply	other threads:[~2017-03-11 12:49 UTC|newest]

Thread overview: 81+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-11 12:49 [PATCHv2 00/15] clk: ti: cleanups for 4.12 merge window Tero Kristo
2017-03-11 12:49 ` Tero Kristo
2017-03-11 12:49 ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 01/15] clk: ti: remove un-used definitions from public clk_hw_omap struct Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 02/15] clk: ti: add support for automatic clock alias generation Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 03/15] clk: ti: add API for creating aliases automatically for simple clock types Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 04/15] clk: ti: use automatic clock alias generation framework Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 05/15] clk: ti: add clkdm_lookup to the exported functions Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 06/15] clk: ti: move omap2_init_clk_clkdm under TI clock driver Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` Tero Kristo [this message]
2017-03-11 12:49   ` [PATCHv2 07/15] clk: ti: enforce const types on string arrays Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49 ` [PATCHv2 08/15] clk: ti: omap4: cleanup unnecessary clock aliases Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:49   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 09/15] clk: ti: drop unnecessary MEMMAP_ADDRESSING flag Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 10/15] clk: ti: mux: convert TI mux clock to use its internal data representation Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 11/15] clk: ti: divider: convert TI divider clock to use its own " Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 12/15] clk: ti: divider: add driver internal API for parsing divider data Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 13/15] clk: ti: gate: export gate_clk_ops locally Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 14/15] clk: ti: dpll44xx: fix clksel register initialization Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50 ` [PATCHv2 15/15] clk: ti: convert to use proper register definition for all accesses Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2017-03-11 12:50   ` Tero Kristo
2018-01-17 13:27   ` Adam Ford
2018-01-17 13:27     ` Adam Ford
2018-01-17 14:02     ` Tero Kristo
2018-01-17 14:02       ` Tero Kristo
2018-01-17 14:02       ` Tero Kristo
2018-01-17 15:15       ` Adam Ford
2018-01-17 15:15         ` Adam Ford
2018-01-17 15:15         ` Adam Ford
2018-01-17 15:33         ` Adam Ford
2018-01-17 15:33           ` Adam Ford
2018-01-17 21:19         ` Tony Lindgren
2018-01-17 21:19           ` Tony Lindgren
2018-01-17 21:44           ` Adam Ford
2018-01-17 21:44             ` Adam Ford
2018-01-18  7:34             ` Tero Kristo
2018-01-18  7:34               ` Tero Kristo
2018-01-18  7:34               ` Tero Kristo
2018-01-18 13:26               ` Adam Ford
2018-01-18 13:26                 ` Adam Ford
2018-01-18 13:29                 ` Tero Kristo
2018-01-18 13:29                   ` Tero Kristo
2018-01-18 13:29                   ` Tero Kristo
2018-01-18 14:12                   ` Adam Ford
2018-01-18 14:12                     ` Adam Ford
2018-01-19  9:42                     ` Tero Kristo
2018-01-19  9:42                       ` Tero Kristo
2018-01-19  9:42                       ` Tero Kristo
2018-01-19 16:43                       ` Adam Ford
2018-01-19 16:43                         ` Adam Ford
2018-01-19 16:43                         ` Adam Ford
2018-01-22  7:07                         ` Tero Kristo
2018-01-22  7:07                           ` Tero Kristo
2018-01-22  7:07                           ` Tero Kristo

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=1489236606-24023-8-git-send-email-t-kristo@ti.com \
    --to=t-kristo@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=sboyd@codeaurora.org \
    --cc=tony@atomide.com \
    /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.