Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

clk: mediatek: mt8186: Join top_adj_div and top_muxes

Like done for MT8192, join the two to register them in one shot, as
there's no point in doing that separately from one another.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20230120092053.182923-17-angelogioacchino.delregno@collabora.com
Tested-by: Mingming Su <mingming.su@mediatek.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>

authored by

AngeloGioacchino Del Regno and committed by
Stephen Boyd
66c8773b 8bc0ed9d

+2 -14
+2 -14
drivers/clk/mediatek/clk-mt8186-topckgen.c
··· 669 669 MUX(CLK_TOP_APLL_I2S4_MCK_SEL, "apll_i2s4_mck_sel", apll_mck_parents, 0x0320, 19, 1), 670 670 MUX(CLK_TOP_APLL_TDMOUT_MCK_SEL, "apll_tdmout_mck_sel", apll_mck_parents, 671 671 0x0320, 20, 1), 672 - }; 673 - 674 - static const struct mtk_composite top_adj_divs[] = { 675 672 DIV_GATE(CLK_TOP_APLL12_CK_DIV0, "apll12_div0", "apll_i2s0_mck_sel", 676 673 0x0320, 0, 0x0328, 8, 0), 677 674 DIV_GATE(CLK_TOP_APLL12_CK_DIV1, "apll12_div1", "apll_i2s1_mck_sel", ··· 746 749 if (r) 747 750 goto unregister_muxes; 748 751 749 - r = mtk_clk_register_composites(&pdev->dev, top_adj_divs, 750 - ARRAY_SIZE(top_adj_divs), base, 751 - &mt8186_clk_lock, clk_data); 752 - if (r) 753 - goto unregister_composite_muxes; 754 - 755 752 r = clk_mt8186_reg_mfg_mux_notifier(&pdev->dev, 756 753 clk_data->hws[CLK_TOP_MFG]->clk); 757 754 if (r) 758 - goto unregister_composite_divs; 755 + goto unregister_composite_muxes; 759 756 760 757 r = of_clk_add_hw_provider(node, of_clk_hw_onecell_get, clk_data); 761 758 if (r) 762 - goto unregister_composite_divs; 759 + goto unregister_composite_muxes; 763 760 764 761 platform_set_drvdata(pdev, clk_data); 765 762 766 763 return r; 767 764 768 - unregister_composite_divs: 769 - mtk_clk_unregister_composites(top_adj_divs, ARRAY_SIZE(top_adj_divs), clk_data); 770 765 unregister_composite_muxes: 771 766 mtk_clk_unregister_composites(top_muxes, ARRAY_SIZE(top_muxes), clk_data); 772 767 unregister_muxes: ··· 778 789 struct device_node *node = pdev->dev.of_node; 779 790 780 791 of_clk_del_provider(node); 781 - mtk_clk_unregister_composites(top_adj_divs, ARRAY_SIZE(top_adj_divs), clk_data); 782 792 mtk_clk_unregister_composites(top_muxes, ARRAY_SIZE(top_muxes), clk_data); 783 793 mtk_clk_unregister_muxes(top_mtk_muxes, ARRAY_SIZE(top_mtk_muxes), clk_data); 784 794 mtk_clk_unregister_factors(top_divs, ARRAY_SIZE(top_divs), clk_data);