@@ -131,7 +131,6 @@ config ARCH_K3
select TI_SCI_PROTOCOL
select TI_SCI_INTR_IRQCHIP
select TI_SCI_INTA_IRQCHIP
- select TI_K3_SOCINFO
help
This enables support for Texas Instruments' K3 multicore SoC
architecture.
@@ -74,7 +74,8 @@ config TI_K3_RINGACC
If unsure, say N.
config TI_K3_SOCINFO
- bool
+ tristate "TI K3 SoC info driver"
+ default m
depends on ARCH_K3 || COMPILE_TEST
select SOC_BUS
select MFD_SYSCON
@@ -13,6 +13,7 @@
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/sys_soc.h>
+#include <linux/module.h>
#define CTRLMMR_WKUP_JTAGID_REG 0
/*
@@ -141,6 +142,7 @@ static const struct of_device_id k3_chipinfo_of_match[] = {
{ .compatible = "ti,am654-chipid", },
{ /* sentinel */ },
};
+MODULE_DEVICE_TABLE(of, k3_chipinfo_of_match);
static struct platform_driver k3_chipinfo_driver = {
.driver = {
@@ -151,8 +153,7 @@ static struct platform_driver k3_chipinfo_driver = {
.remove = k3_chipinfo_remove,
};
-static int __init k3_chipinfo_init(void)
-{
- return platform_driver_register(&k3_chipinfo_driver);
-}
-subsys_initcall(k3_chipinfo_init);
+module_platform_driver(k3_chipinfo_driver);
+
+MODULE_DESCRIPTION("TI K3 SoC info driver");
+MODULE_LICENSE("GPL v2");
Added module build support for the TI K3 SoC info driver. Signed-off-by: Nicolas Frayer <nfrayer@baylibre.com> --- arch/arm64/Kconfig.platforms | 1 - drivers/soc/ti/Kconfig | 3 ++- drivers/soc/ti/k3-socinfo.c | 11 ++++++----- 3 files changed, 8 insertions(+), 7 deletions(-)