Thread (72 messages) 72 messages, 2 authors, 2023-02-21

Re: [PATCH v3 39/55] clk: mediatek: Split MT8195 clock drivers and allow module build

From: Chen-Yu Tsai <wenst@chromium.org>
Date: 2023-02-21 03:54:14
Also in: linux-clk, linux-mediatek, lkml

On Mon, Feb 20, 2023 at 11:02 PM AngeloGioacchino Del Regno
[off-list ref] wrote:
quoted hunk ↗ jump to hunk
MT8195 clock drivers were encapsulated in one single (and big) Kconfig
option: there's no reason to do that, as it is totally unnecessary to
build in all or none of them.

Split them out: keep boot-critical clocks as bool and allow choosing
non critical clocks as tristate.

As a note, the dependencies of VDEC/VENCSYS and CAM/IMG/IPE/WPESYS
are not for build-time but rather for runtime, as clocks registered
by those have runtime dependencies on either or both VPP and IMGSYS.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
---
 drivers/clk/mediatek/Kconfig  | 100 ++++++++++++++++++++++++++++++++++
 drivers/clk/mediatek/Makefile |  20 ++++---
 2 files changed, 113 insertions(+), 7 deletions(-)
diff --git a/drivers/clk/mediatek/Kconfig b/drivers/clk/mediatek/Kconfig
index 45b7aea7648d..49919da2be26 100644
--- a/drivers/clk/mediatek/Kconfig
+++ b/drivers/clk/mediatek/Kconfig
@@ -692,6 +692,106 @@ config COMMON_CLK_MT8195
         help
           This driver supports MediaTek MT8195 clocks.

+config COMMON_CLK_MT8195_APUSYS
+       tristate "Clock driver for MediaTek MT8195 apusys"
+       depends on COMMON_CLK_MT8195
+       default COMMON_CLK_MT8195
+       help
+         This driver supports MediaTek MT8195 AI Processor Unit System clocks.
+
+config COMMON_CLK_MT8195_AUDSYS
+       tristate "Clock driver for MediaTek MT8195 audsys"
+       depends on COMMON_CLK_MT8195
+       default COMMON_CLK_MT8195
+       help
+         This driver supports MediaTek MT8195 audsys clocks.
+
+config COMMON_CLK_MT8195_IMP_IIC_WRAP
+       tristate "Clock driver for MediaTek MT8195 imp_iic_wrap"
+       depends on COMMON_CLK_MT8195
+       default COMMON_CLK_MT8195
+       help
+         This driver supports MediaTek MT8195 I2C/I3C clocks.
+
+config COMMON_CLK_MT8195_IPESYS
+       tristate "Clock driver for MediaTek MT8195 ipesys"
+       depends on COMMON_CLK_MT8195_IMGSYS
This should also be moved to just after IMGSYS.
This is the only one that is not ordered right, so after it is fixed,

Reviewed-by: Chen-Yu Tsai <wenst@chromium.org>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help