Skip to contentSkip to conversation

clk: imx: drop redundant initialization

PATCH Applied Anson Huang 3 participants 3 messages Feb 12, 2020 – Feb 17, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 clk: imx: drop redundant initialization

No need to initialize flags as 0, remove the initialization.

---
 drivers/clk/imx/clk-composite-8m.c | 2 +-
 drivers/clk/imx/clk-fixup-div.c    | 2 +-
 drivers/clk/imx/clk-fixup-mux.c    | 2 +-
 drivers/clk/imx/clk-gate2.c        | 6 +++---
 4 files changed, 6 insertions(+), 6 deletions(-)
drivers/clk/imx/clk-composite-8m.c +1 -1
index 20f7c91..a35407b 100644
@@ -91,7 +91,7 @@ static int imx8m_clk_composite_divider_set_rate(struct clk_hw *hw,
 					unsigned long parent_rate)
 {
 	struct clk_divider *divider = to_clk_divider(hw);
-	unsigned long flags = 0;
+	unsigned long flags;
 	int prediv_value;
 	int div_value;
 	int ret;
drivers/clk/imx/clk-fixup-div.c +1 -1
index 4b17b91..100ca82 100644
@@ -55,7 +55,7 @@ static int clk_fixup_div_set_rate(struct clk_hw *hw, unsigned long rate,
 	struct clk_fixup_div *fixup_div = to_clk_fixup_div(hw);
 	struct clk_divider *div = to_clk_divider(hw);
 	unsigned int divider, value;
-	unsigned long flags = 0;
+	unsigned long flags;
 	u32 val;
 
 	divider = parent_rate / rate;
drivers/clk/imx/clk-fixup-mux.c +1 -1
index b569d91..58a6763 100644
@@ -42,7 +42,7 @@ static int clk_fixup_mux_set_parent(struct clk_hw *hw, u8 index)
 {
 	struct clk_fixup_mux *fixup_mux = to_clk_fixup_mux(hw);
 	struct clk_mux *mux = to_clk_mux(hw);
-	unsigned long flags = 0;
+	unsigned long flags;
 	u32 val;
 
 	spin_lock_irqsave(mux->lock, flags);
drivers/clk/imx/clk-gate2.c +3 -3
index 7d44ce8..72a7698 100644
@@ -40,7 +40,7 @@ static int clk_gate2_enable(struct clk_hw *hw)
 {
 	struct clk_gate2 *gate = to_clk_gate2(hw);
 	u32 reg;
-	unsigned long flags = 0;
+	unsigned long flags;
 
 	spin_lock_irqsave(gate->lock, flags);
 
@@ -62,7 +62,7 @@ static void clk_gate2_disable(struct clk_hw *hw)
 {
 	struct clk_gate2 *gate = to_clk_gate2(hw);
 	u32 reg;
-	unsigned long flags = 0;
+	unsigned long flags;
 
 	spin_lock_irqsave(gate->lock, flags);
 
@@ -101,7 +101,7 @@ static int clk_gate2_is_enabled(struct clk_hw *hw)
 static void clk_gate2_disable_unused(struct clk_hw *hw)
 {
 	struct clk_gate2 *gate = to_clk_gate2(hw);
-	unsigned long flags = 0;
+	unsigned long flags;
 	u32 reg;
 
 	spin_lock_irqsave(gate->lock, flags);
Signature · 1 line
2.7.4