[PATCH 4/7] clk: gate: underscore-prefix barebox-specific parent member
Ahmad Fatoum
a.fatoum at pengutronix.de
Tue Apr 22 00:56:34 PDT 2025
From: Ahmad Fatoum <a.fatoum at barebox.org>
The parent member is barebox-specific and is set internally on
registration, so make this clearer by making it "private".
Signed-off-by: Ahmad Fatoum <a.fatoum at barebox.org>
---
drivers/clk/clk-gate.c | 4 ++--
include/linux/clk.h | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/clk/clk-gate.c b/drivers/clk/clk-gate.c
index d31920fd0bfe..1de9791499d9 100644
--- a/drivers/clk/clk-gate.c
+++ b/drivers/clk/clk-gate.c
@@ -72,13 +72,13 @@ struct clk *clk_gate_alloc(const char *name, const char *parent,
{
struct clk_gate *g = xzalloc(sizeof(*g));
- g->parent = parent;
+ g->_parent = parent;
g->reg = reg;
g->shift = shift;
g->hw.clk.ops = &clk_gate_ops;
g->hw.clk.name = name;
g->hw.clk.flags = flags;
- g->hw.clk.parent_names = &g->parent;
+ g->hw.clk.parent_names = &g->_parent;
g->hw.clk.num_parents = 1;
g->flags = clk_gate_flags;
diff --git a/include/linux/clk.h b/include/linux/clk.h
index 74802fde4572..9f4e97d37a3a 100644
--- a/include/linux/clk.h
+++ b/include/linux/clk.h
@@ -689,9 +689,9 @@ struct clk_gate {
struct clk_hw hw;
void __iomem *reg;
int shift;
- const char *parent;
unsigned flags;
spinlock_t *lock;
+ const char *_parent;
};
int clk_gate_is_enabled(struct clk_hw *hw);
--
2.39.5
More information about the barebox
mailing list