[PATCH RFT v2 08/14] clk: qcom: smd-rpm: Separate out a macro for defining an AO clock

Konrad Dybcio
2023-03-08T21:36:18Z

To declare a keepalive variant of a bus clock, it will be useful to
have a reusable macro which will ease defining a keepalive variant
of an AO clock with an IS_CRITICAL flag. Introduce it.

Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
drivers/clk/qcom/clk-smd-rpm.c | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/drivers/clk/qcom/clk-smd-rpm.c b/drivers/clk/qcom/clk-smd-rpm.c
index ddb4268ba2a5..eb7781e5c8c1 100644
--- a/drivers/clk/qcom/clk-smd-rpm.c
+++ b/drivers/clk/qcom/clk-smd-rpm.c
@@ -44,6 +44,11 @@
.num_parents = 1, \
}, \
}; \
+ __DEFINE_CLK_SMD_RPM_AO_PREFIX(_prefix, _name, _active, type, \
+ r_id, key, ao_flags)
+
+#define __DEFINE_CLK_SMD_RPM_AO_PREFIX(_prefix, _name, _active, \
+ type, r_id, key, ao_flags) \
static struct clk_smd_rpm clk_smd_rpm_##_prefix##_active = { \
.rpm_res_type = (type), \
.rpm_clk_id = (r_id), \

--
2.39.2