Thread (19 messages) 19 messages, 4 authors, 2016-01-08

[PATCH 4/4] soc: mediatek: Add MT2701/MT7623 scpsys driver

From: James Liao <hidden>
Date: 2015-12-30 10:18:20
Also in: linux-devicetree, linux-mediatek, lkml

Hi Daniel,

On Wed, 2015-12-30 at 17:01 +0800, Daniel Kurtz wrote:
On Wed, Dec 30, 2015 at 2:41 PM, James Liao [off-list ref] wrote:
quoted
From: Shunli Wang <redacted>

Add scpsys driver for MT2701 and MT7623.

Signed-off-by: Shunli Wang <redacted>
Signed-off-by: James Liao <redacted>
---
 drivers/soc/mediatek/Kconfig             |  11 +++
 drivers/soc/mediatek/Makefile            |   1 +
 drivers/soc/mediatek/mtk-scpsys-mt2701.c | 161 +++++++++++++++++++++++++++++++
 3 files changed, 173 insertions(+)
 create mode 100644 drivers/soc/mediatek/mtk-scpsys-mt2701.c
diff --git a/drivers/soc/mediatek/Kconfig b/drivers/soc/mediatek/Kconfig
index eca6fb7..92cf838 100644
--- a/drivers/soc/mediatek/Kconfig
+++ b/drivers/soc/mediatek/Kconfig
@@ -39,3 +39,14 @@ config MTK_SCPSYS_MT8173
          driver.
          The System Control Processor System (SCPSYS) has several power
          management related tasks in the system.
+
+config MTK_SCPSYS_MT2701
+       bool "SCPSYS Support MediaTek MT2701 and MT7623"
+       depends on ARCH_MEDIATEK || COMPILE_TEST
+       select MTK_SCPSYS
+       default ARCH_MEDIATEK
+       help
+         Say yes here to add support for the MT2701/MT7623 SCPSYS power
+         domain driver.
+         The System Control Processor System (SCPSYS) has several power
+         management related tasks in the system.
I don't think we really want different drivers and Kconfig options.

Can we just use different compatibles to select the appropriate scp_domain_data?
Yes, we can. All scpsys drivers are built-in by default, and they will
be activate by specific compatible string.

But some projects don't want to build unused drivers into kernel to save
code size. Use different Kconfig options for each SoC so that these
projects can disable unused drivers.


Best regards,

James
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help