Skip to content

Commit 8d27b14

Browse files
committed
Merge tag 'v5.16-rockchip-clk-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into clk-rockchip
Pull Rockchip clk driver updates from Heiko Stuebner: - Move to use module_platform_probe - Enable usage of Coresight-related clocks on rk3399 * tag 'v5.16-rockchip-clk-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: clk: rockchip: use module_platform_driver_probe clk: rockchip: rk3399: expose PCLK_COREDBG_{B,L} clk: rockchip: rk3399: make CPU clocks critical
2 parents 6880fa6 + 1da80da commit 8d27b14

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

drivers/clk/rockchip/clk-rk3399.c

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,7 @@ static struct rockchip_clk_branch rk3399_clk_branches[] __initdata = {
481481
COMPOSITE_NOMUX(0, "atclk_core_l", "armclkl", CLK_IGNORE_UNUSED,
482482
RK3399_CLKSEL_CON(1), 0, 5, DFLAGS | CLK_DIVIDER_READ_ONLY,
483483
RK3399_CLKGATE_CON(0), 5, GFLAGS),
484-
COMPOSITE_NOMUX(0, "pclk_dbg_core_l", "armclkl", CLK_IGNORE_UNUSED,
484+
COMPOSITE_NOMUX(PCLK_COREDBG_L, "pclk_dbg_core_l", "armclkl", CLK_IGNORE_UNUSED,
485485
RK3399_CLKSEL_CON(1), 8, 5, DFLAGS | CLK_DIVIDER_READ_ONLY,
486486
RK3399_CLKGATE_CON(0), 6, GFLAGS),
487487

@@ -531,7 +531,7 @@ static struct rockchip_clk_branch rk3399_clk_branches[] __initdata = {
531531
GATE(ACLK_GIC_ADB400_CORE_B_2_GIC, "aclk_core_adb400_core_b_2_gic", "armclkb", CLK_IGNORE_UNUSED,
532532
RK3399_CLKGATE_CON(14), 4, GFLAGS),
533533

534-
DIV(0, "pclken_dbg_core_b", "pclk_dbg_core_b", CLK_IGNORE_UNUSED,
534+
DIV(PCLK_COREDBG_B, "pclken_dbg_core_b", "pclk_dbg_core_b", CLK_IGNORE_UNUSED,
535535
RK3399_CLKSEL_CON(3), 13, 2, DFLAGS | CLK_DIVIDER_READ_ONLY),
536536

537537
GATE(0, "pclk_dbg_cxcs_pd_core_b", "pclk_dbg_core_b", CLK_IGNORE_UNUSED,
@@ -1514,7 +1514,10 @@ static const char *const rk3399_cru_critical_clocks[] __initconst = {
15141514
"aclk_vio_noc",
15151515

15161516
/* ddrc */
1517-
"sclk_ddrc"
1517+
"sclk_ddrc",
1518+
1519+
"armclkl",
1520+
"armclkb",
15181521
};
15191522

15201523
static const char *const rk3399_pmucru_critical_clocks[] __initconst = {
@@ -1549,9 +1552,6 @@ static void __init rk3399_clk_init(struct device_node *np)
15491552
rockchip_clk_register_branches(ctx, rk3399_clk_branches,
15501553
ARRAY_SIZE(rk3399_clk_branches));
15511554

1552-
rockchip_clk_protect_critical(rk3399_cru_critical_clocks,
1553-
ARRAY_SIZE(rk3399_cru_critical_clocks));
1554-
15551555
rockchip_clk_register_armclk(ctx, ARMCLKL, "armclkl",
15561556
mux_armclkl_p, ARRAY_SIZE(mux_armclkl_p),
15571557
&rk3399_cpuclkl_data, rk3399_cpuclkl_rates,
@@ -1562,6 +1562,9 @@ static void __init rk3399_clk_init(struct device_node *np)
15621562
&rk3399_cpuclkb_data, rk3399_cpuclkb_rates,
15631563
ARRAY_SIZE(rk3399_cpuclkb_rates));
15641564

1565+
rockchip_clk_protect_critical(rk3399_cru_critical_clocks,
1566+
ARRAY_SIZE(rk3399_cru_critical_clocks));
1567+
15651568
rockchip_register_softrst(np, 21, reg_base + RK3399_SOFTRST_CON(0),
15661569
ROCKCHIP_SOFTRST_HIWORD_MASK);
15671570

@@ -1653,7 +1656,7 @@ static struct platform_driver clk_rk3399_driver = {
16531656
.suppress_bind_attrs = true,
16541657
},
16551658
};
1656-
builtin_platform_driver_probe(clk_rk3399_driver, clk_rk3399_probe);
1659+
module_platform_driver_probe(clk_rk3399_driver, clk_rk3399_probe);
16571660

16581661
MODULE_DESCRIPTION("Rockchip RK3399 Clock Driver");
16591662
MODULE_LICENSE("GPL");

drivers/clk/rockchip/clk-rk3568.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1719,7 +1719,7 @@ static struct platform_driver clk_rk3568_driver = {
17191719
.suppress_bind_attrs = true,
17201720
},
17211721
};
1722-
builtin_platform_driver_probe(clk_rk3568_driver, clk_rk3568_probe);
1722+
module_platform_driver_probe(clk_rk3568_driver, clk_rk3568_probe);
17231723

17241724
MODULE_DESCRIPTION("Rockchip RK3568 Clock Driver");
17251725
MODULE_LICENSE("GPL");

0 commit comments

Comments
 (0)