lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230727053156.13587-28-claudiu.beznea@tuxon.dev>
Date:   Thu, 27 Jul 2023 08:31:41 +0300
From:   Claudiu Beznea <claudiu.beznea@...on.dev>
To:     mturquette@...libre.com, sboyd@...nel.org,
        nicolas.ferre@...rochip.com, alexandre.belloni@...tlin.com,
        mripard@...nel.org
Cc:     linux-clk@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        linux-kernel@...r.kernel.org, varshini.rajendran@...rochip.com,
        Claudiu Beznea <claudiu.beznea@...on.dev>
Subject: [PATCH 27/42] clk: at91: clk-audio-pll: remove parent_names support

Remove parent_names support as parent_hw support is now available on all
platforms using clk-audio-pll.

Signed-off-by: Claudiu Beznea <claudiu.beznea@...on.dev>
---
 drivers/clk/at91/clk-audio-pll.c | 21 ++++++---------------
 drivers/clk/at91/dt-compat.c     |  6 +++---
 drivers/clk/at91/pmc.h           |  6 +++---
 drivers/clk/at91/sama5d2.c       |  6 +++---
 4 files changed, 15 insertions(+), 24 deletions(-)

diff --git a/drivers/clk/at91/clk-audio-pll.c b/drivers/clk/at91/clk-audio-pll.c
index 7a13af95d628..fc08ca53bfad 100644
--- a/drivers/clk/at91/clk-audio-pll.c
+++ b/drivers/clk/at91/clk-audio-pll.c
@@ -450,7 +450,7 @@ static const struct clk_ops audio_pll_pmc_ops = {
 
 struct clk_hw * __init
 at91_clk_register_audio_pll_frac(struct regmap *regmap, const char *name,
-				 const char *parent_name, struct clk_hw *parent_hw)
+				 struct clk_hw *parent_hw)
 {
 	struct clk_audio_frac *frac_ck;
 	struct clk_init_data init = {};
@@ -462,10 +462,7 @@ at91_clk_register_audio_pll_frac(struct regmap *regmap, const char *name,
 
 	init.name = name;
 	init.ops = &audio_pll_frac_ops;
-	if (parent_hw)
-		init.parent_hws = (const struct clk_hw **)&parent_hw;
-	else
-		init.parent_names = &parent_name;
+	init.parent_hws = (const struct clk_hw **)&parent_hw;
 	init.num_parents = 1;
 	init.flags = CLK_SET_RATE_GATE;
 
@@ -483,7 +480,7 @@ at91_clk_register_audio_pll_frac(struct regmap *regmap, const char *name,
 
 struct clk_hw * __init
 at91_clk_register_audio_pll_pad(struct regmap *regmap, const char *name,
-				const char *parent_name, struct clk_hw *parent_hw)
+				struct clk_hw *parent_hw)
 {
 	struct clk_audio_pad *apad_ck;
 	struct clk_init_data init = {};
@@ -495,10 +492,7 @@ at91_clk_register_audio_pll_pad(struct regmap *regmap, const char *name,
 
 	init.name = name;
 	init.ops = &audio_pll_pad_ops;
-	if (parent_hw)
-		init.parent_hws = (const struct clk_hw **)&parent_hw;
-	else
-		init.parent_names = &parent_name;
+	init.parent_hws = (const struct clk_hw **)&parent_hw;
 	init.num_parents = 1;
 	init.flags = CLK_SET_RATE_GATE | CLK_SET_PARENT_GATE |
 		CLK_SET_RATE_PARENT;
@@ -517,7 +511,7 @@ at91_clk_register_audio_pll_pad(struct regmap *regmap, const char *name,
 
 struct clk_hw * __init
 at91_clk_register_audio_pll_pmc(struct regmap *regmap, const char *name,
-				const char *parent_name, struct clk_hw *parent_hw)
+				struct clk_hw *parent_hw)
 {
 	struct clk_audio_pmc *apmc_ck;
 	struct clk_init_data init = {};
@@ -529,10 +523,7 @@ at91_clk_register_audio_pll_pmc(struct regmap *regmap, const char *name,
 
 	init.name = name;
 	init.ops = &audio_pll_pmc_ops;
-	if (parent_hw)
-		init.parent_hws = (const struct clk_hw **)&parent_hw;
-	else
-		init.parent_names = &parent_name;
+	init.parent_hws = (const struct clk_hw **)&parent_hw;
 	init.num_parents = 1;
 	init.flags = CLK_SET_RATE_GATE | CLK_SET_PARENT_GATE |
 		CLK_SET_RATE_PARENT;
diff --git a/drivers/clk/at91/dt-compat.c b/drivers/clk/at91/dt-compat.c
index 044e1fc821e2..91bc2fada6ec 100644
--- a/drivers/clk/at91/dt-compat.c
+++ b/drivers/clk/at91/dt-compat.c
@@ -50,7 +50,7 @@ static void __init of_sama5d2_clk_audio_pll_frac_setup(struct device_node *np)
 	if (!parent_hw)
 		return;
 
-	hw = at91_clk_register_audio_pll_frac(regmap, name, NULL, parent_hw);
+	hw = at91_clk_register_audio_pll_frac(regmap, name, parent_hw);
 	if (IS_ERR(hw))
 		return;
 
@@ -82,7 +82,7 @@ static void __init of_sama5d2_clk_audio_pll_pad_setup(struct device_node *np)
 	if (!parent_hw)
 		return;
 
-	hw = at91_clk_register_audio_pll_pad(regmap, name, NULL, parent_hw);
+	hw = at91_clk_register_audio_pll_pad(regmap, name, parent_hw);
 	if (IS_ERR(hw))
 		return;
 
@@ -114,7 +114,7 @@ static void __init of_sama5d2_clk_audio_pll_pmc_setup(struct device_node *np)
 	if (!parent_hw)
 		return;
 
-	hw = at91_clk_register_audio_pll_pmc(regmap, name, NULL, parent_hw);
+	hw = at91_clk_register_audio_pll_pmc(regmap, name, parent_hw);
 	if (IS_ERR(hw))
 		return;
 
diff --git a/drivers/clk/at91/pmc.h b/drivers/clk/at91/pmc.h
index 6816e350d6d6..711b55a6b0ab 100644
--- a/drivers/clk/at91/pmc.h
+++ b/drivers/clk/at91/pmc.h
@@ -130,15 +130,15 @@ struct clk_hw *of_clk_hw_pmc_get(struct of_phandle_args *clkspec, void *data);
 
 struct clk_hw * __init
 at91_clk_register_audio_pll_frac(struct regmap *regmap, const char *name,
-				 const char *parent_name, struct clk_hw *parent_hw);
+				 struct clk_hw *parent_hw);
 
 struct clk_hw * __init
 at91_clk_register_audio_pll_pad(struct regmap *regmap, const char *name,
-				const char *parent_name, struct clk_hw *parent_hw);
+				struct clk_hw *parent_hw);
 
 struct clk_hw * __init
 at91_clk_register_audio_pll_pmc(struct regmap *regmap, const char *name,
-				const char *parent_name, struct clk_hw *parent_hw);
+				struct clk_hw *parent_hw);
 
 struct clk_hw * __init
 at91_clk_register_generated(struct regmap *regmap, spinlock_t *lock,
diff --git a/drivers/clk/at91/sama5d2.c b/drivers/clk/at91/sama5d2.c
index cdb578059449..3920de445eca 100644
--- a/drivers/clk/at91/sama5d2.c
+++ b/drivers/clk/at91/sama5d2.c
@@ -233,17 +233,17 @@ static void __init sama5d2_pmc_setup(struct device_node *np)
 	sama5d2_pmc->chws[PMC_PLLACK] = hw;
 
 	audio_fracck_hw = at91_clk_register_audio_pll_frac(regmap, "audiopll_fracck",
-							   NULL, sama5d2_pmc->chws[PMC_MAIN]);
+							   sama5d2_pmc->chws[PMC_MAIN]);
 	if (IS_ERR(audio_fracck_hw))
 		goto err_free;
 
-	hw = at91_clk_register_audio_pll_pad(regmap, "audiopll_padck", NULL, audio_fracck_hw);
+	hw = at91_clk_register_audio_pll_pad(regmap, "audiopll_padck", audio_fracck_hw);
 	if (IS_ERR(hw))
 		goto err_free;
 
 	sama5d2_pmc->chws[PMC_AUDIOPINCK] = hw;
 
-	hw = at91_clk_register_audio_pll_pmc(regmap, "audiopll_pmcck", NULL, audio_fracck_hw);
+	hw = at91_clk_register_audio_pll_pmc(regmap, "audiopll_pmcck", audio_fracck_hw);
 	if (IS_ERR(hw))
 		goto err_free;
 
-- 
2.39.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ