[PATCH v1 11/45] clk: mediatek: mt8365: Move apmixedsys clock driver to its own file

Chen-Yu Tsai wenst at chromium.org
Tue Feb 7 01:32:08 PST 2023


On Tue, Feb 7, 2023 at 5:14 PM AngeloGioacchino Del Regno
<angelogioacchino.delregno at collabora.com> wrote:
>
> Il 07/02/23 08:12, Chen-Yu Tsai ha scritto:
> > On Mon, Feb 6, 2023 at 11:30 PM AngeloGioacchino Del Regno
> > <angelogioacchino.delregno at collabora.com> wrote:
> >>
> >> In preparation for migrating all other mt8365 clocks to the common
> >> mtk_clk_simple_probe(), move apmixedsys clocks to a different file.
> >> While at it, use the builtin_platform_driver() macro for it.
> >
> > `git diff --color-moved=dimmed-zebra --color-moved-ws=ignore-all-space`
> > agrees this is mostly a code move.
> >
> >> Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno at collabora.com>
> >> ---
> >>   drivers/clk/mediatek/Makefile                |   2 +-
> >>   drivers/clk/mediatek/clk-mt8365-apmixedsys.c | 164 +++++++++++++++++++
> >>   drivers/clk/mediatek/clk-mt8365.c            | 142 ----------------
> >
> > Reviewed-by: Chen-Yu Tsai <wenst at chromium.org>
> >
> > But see below.
> >
> >>   3 files changed, 165 insertions(+), 143 deletions(-)
> >>   create mode 100644 drivers/clk/mediatek/clk-mt8365-apmixedsys.c
> >>
> >> diff --git a/drivers/clk/mediatek/Makefile b/drivers/clk/mediatek/Makefile
> >> index 3c7dd19cdddf..b004a47026d4 100644
> >> --- a/drivers/clk/mediatek/Makefile
> >> +++ b/drivers/clk/mediatek/Makefile
> >> @@ -112,7 +112,7 @@ obj-$(CONFIG_COMMON_CLK_MT8195) += clk-mt8195-apmixedsys.o clk-mt8195-topckgen.o
> >>                                     clk-mt8195-venc.o clk-mt8195-vpp0.o clk-mt8195-vpp1.o \
> >>                                     clk-mt8195-wpe.o clk-mt8195-imp_iic_wrap.o \
> >>                                     clk-mt8195-apusys_pll.o
> >> -obj-$(CONFIG_COMMON_CLK_MT8365) += clk-mt8365.o
> >> +obj-$(CONFIG_COMMON_CLK_MT8365) += clk-mt8365.o clk-mt8365-apmixedsys.o
> >>   obj-$(CONFIG_COMMON_CLK_MT8365_APU) += clk-mt8365-apu.o
> >>   obj-$(CONFIG_COMMON_CLK_MT8365_CAM) += clk-mt8365-cam.o
> >>   obj-$(CONFIG_COMMON_CLK_MT8365_MFG) += clk-mt8365-mfg.o
> >> diff --git a/drivers/clk/mediatek/clk-mt8365-apmixedsys.c b/drivers/clk/mediatek/clk-mt8365-apmixedsys.c
> >> new file mode 100644
> >> index 000000000000..6f0fdf92bbd2
> >> --- /dev/null
> >> +++ b/drivers/clk/mediatek/clk-mt8365-apmixedsys.c
> >> @@ -0,0 +1,164 @@
> >> +// SPDX-License-Identifier: GPL-2.0-only
> >> +/*
> >> + * Copyright (c) 2022 MediaTek Inc.
> >> + * Copyright (c) 2023 Collabora Ltd.
> >> + */
> >> +
> >> +#include <dt-bindings/clock/mediatek,mt8365-clk.h>
> >> +#include <linux/clk.h>
> >
> > like in the MT2712 patch, this could be clk-provider.h .
> > Or maybe we should do a pass of header cleanup? There's a bunch left
> > over from the conversion from |struct clk| to |structk clk_hw|, and
> > then migration to mtk_clk_simple_probe.
> >
> > What do you think?
> >
>
> I'm more for a separated pass of header cleanup, honestly...

I'm OK with that. Or maybe someone notices as does drive-by cleanups.



More information about the linux-arm-kernel mailing list