Skip to contentSkip to conversation

clk: imx: Fix wrong flags assignment clk-composite-8m

PATCH Applied Michael Trimarchi 2 participants 3 messages Jul 2, 2024 – Jul 6, 2024

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

PATCH 1/2 clk: imx: Fix wrong flags assignment clk-composite-8m

The mux flags (u8), div flags (u8), and gate flags (u8) are not the clk flags (unsigned long). They have different meanings

---
 drivers/clk/imx/clk-composite-8m.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/clk/imx/clk-composite-8m.c +1 -3
index 494156751da..560d74aac80 100644
@@ -135,7 +135,6 @@ struct clk *imx8m_clk_composite_flags(const char *name,
 	mux->shift = PCG_PCS_SHIFT;
 	mux->mask = PCG_PCS_MASK;
 	mux->num_parents = num_parents;
-	mux->flags = flags;
 	mux->parent_names = parent_names;
 
 	div = kzalloc(sizeof(*div), GFP_KERNEL);
@@ -145,7 +144,7 @@ struct clk *imx8m_clk_composite_flags(const char *name,
 	div->reg = reg;
 	div->shift = PCG_PREDIV_SHIFT;
 	div->width = PCG_PREDIV_WIDTH;
-	div->flags = CLK_DIVIDER_ROUND_CLOSEST | flags;
+	div->flags = CLK_DIVIDER_ROUND_CLOSEST;
 
 	gate = kzalloc(sizeof(*gate), GFP_KERNEL);
 	if (!gate)
@@ -153,7 +152,6 @@ struct clk *imx8m_clk_composite_flags(const char *name,
 
 	gate->reg = reg;
 	gate->bit_idx = PCG_CGC_SHIFT;
-	gate->flags = flags;
 
 	clk = clk_register_composite(NULL, name,
 				     parent_names, num_parents,
Signature · 1 line
2.43.0
#1 lore raw

PATCH 2/2 clk: imx: Fix wrong flags assignment clk-composite-93

The mux flags (u8), div flags (u8), and gate flags (u8) are not the clk flags (unsigned long). They have different meanings

---
 drivers/clk/imx/clk-composite-93.c | 2 --
 1 file changed, 2 deletions(-)
drivers/clk/imx/clk-composite-93.c +0 -2
index 6d71c0c03ff..34026c5e42f 100644
@@ -103,7 +103,6 @@ struct clk *imx93_clk_composite_flags(const char *name,
 	mux->mask = CCM_MUX_MASK;
 	mux->num_parents = num_parents;
 	mux->parent_names = parent_names;
-	mux->flags = flags;
 
 	div = kzalloc(sizeof(*div), GFP_KERNEL);
 	if (!div)
@@ -120,7 +119,6 @@ struct clk *imx93_clk_composite_flags(const char *name,
 
 	gate->reg = reg;
 	gate->bit_idx = CCM_OFF_SHIFT;
-	gate->flags = flags;
 
 	clk = clk_register_composite(NULL, name,
 				     parent_names, num_parents,
Signature · 1 line
2.43.0