Add helper macro for mtk_gate, the same way, there are macros for
FIXED_CLK, MUX and FACTOR.

Signed-off-by: Julien Stephan <[email protected]>
---
 drivers/clk/mediatek/clk-mtk.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/clk/mediatek/clk-mtk.h b/drivers/clk/mediatek/clk-mtk.h
index e618e982e8b..f3d2377aee4 100644
--- a/drivers/clk/mediatek/clk-mtk.h
+++ b/drivers/clk/mediatek/clk-mtk.h
@@ -243,6 +243,14 @@ struct mtk_gate {
        u32 flags;
 };
 
+#define GATE_FLAGS(_id, _parent, _regs, _shift, _flags) {      \
+               .id = _id,                                      \
+               .parent = _parent,                              \
+               .regs = _regs,                                  \
+               .shift = _shift,                                \
+               .flags = _flags,                                \
+       }
+
 /* struct mtk_clk_tree - clock tree */
 struct mtk_clk_tree {
        unsigned long xtal_rate;

-- 
2.52.0

Reply via email to