Skip to content

Commit c8bd9bd

Browse files
claudiubezneageertu
authored andcommitted
clk: renesas: r9a08g045: Add clock, reset and power domain support for the VBATTB IP
The Renesas RZ/G3S SoC has an IP named Battery Backup Function (VBATTB) that generates the RTC clock. Add clock, reset and power domain support for it. Signed-off-by: Claudiu Beznea <[email protected]> Reviewed-by: Geert Uytterhoeven <[email protected]> Link: https://lore.kernel.org/[email protected] Signed-off-by: Geert Uytterhoeven <[email protected]>
1 parent d6c5fc9 commit c8bd9bd

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

drivers/clk/renesas/r9a08g045-cpg.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,7 @@ static const struct rzg2l_mod_clk r9a08g045_mod_clks[] = {
215215
DEF_MOD("eth1_refclk", R9A08G045_ETH1_REFCLK, R9A08G045_CLK_HP, 0x57c, 9),
216216
DEF_MOD("scif0_clk_pck", R9A08G045_SCIF0_CLK_PCK, R9A08G045_CLK_P0, 0x584, 0),
217217
DEF_MOD("gpio_hclk", R9A08G045_GPIO_HCLK, R9A08G045_OSCCLK, 0x598, 0),
218+
DEF_MOD("vbat_bclk", R9A08G045_VBAT_BCLK, R9A08G045_OSCCLK, 0x614, 0),
218219
};
219220

220221
static const struct rzg2l_reset r9a08g045_resets[] = {
@@ -231,13 +232,15 @@ static const struct rzg2l_reset r9a08g045_resets[] = {
231232
DEF_RST(R9A08G045_GPIO_RSTN, 0x898, 0),
232233
DEF_RST(R9A08G045_GPIO_PORT_RESETN, 0x898, 1),
233234
DEF_RST(R9A08G045_GPIO_SPARE_RESETN, 0x898, 2),
235+
DEF_RST(R9A08G045_VBAT_BRESETN, 0x914, 0),
234236
};
235237

236238
static const unsigned int r9a08g045_crit_mod_clks[] __initconst = {
237239
MOD_CLK_BASE + R9A08G045_GIC600_GICCLK,
238240
MOD_CLK_BASE + R9A08G045_IA55_PCLK,
239241
MOD_CLK_BASE + R9A08G045_IA55_CLK,
240242
MOD_CLK_BASE + R9A08G045_DMAC_ACLK,
243+
MOD_CLK_BASE + R9A08G045_VBAT_BCLK,
241244
};
242245

243246
static const struct rzg2l_cpg_pm_domain_init_data r9a08g045_pm_domains[] = {
@@ -275,6 +278,9 @@ static const struct rzg2l_cpg_pm_domain_init_data r9a08g045_pm_domains[] = {
275278
DEF_PD("scif0", R9A08G045_PD_SCIF0,
276279
DEF_REG_CONF(CPG_BUS_MCPU2_MSTOP, BIT(1)),
277280
RZG2L_PD_F_NONE),
281+
DEF_PD("vbat", R9A08G045_PD_VBAT,
282+
DEF_REG_CONF(CPG_BUS_MCPU3_MSTOP, BIT(8)),
283+
RZG2L_PD_F_ALWAYS_ON),
278284
};
279285

280286
const struct rzg2l_cpg_info r9a08g045_cpg_info = {

0 commit comments

Comments
 (0)