[PATCH v2] reset: qcom-aoss: Allow CONFIG_RESET_QCOM_AOSS to be a tristate

From: John Stultz
Date: Tue Jan 07 2020 - 14:13:35 EST


Allow CONFIG_RESET_QCOM_AOSS to be set as as =m
to allow for the driver to be loaded from a modules.

Also replaces the builtin_platform_driver() line with
module_platform_driver()

Cc: Todd Kjos <tkjos@xxxxxxxxxx>
Cc: Alistair Delva <adelva@xxxxxxxxxx>
Cc: Bjorn Andersson <bjorn.andersson@xxxxxxxxxx>
Cc: Amit Pundir <amit.pundir@xxxxxxxxxx>
Cc: Philipp Zabel <p.zabel@xxxxxxxxxxxxxx>
Signed-off-by: John Stultz <john.stultz@xxxxxxxxxx>
---
v2: Fix builtin_platform_driver line in driver code
---
drivers/reset/Kconfig | 2 +-
drivers/reset/reset-qcom-aoss.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/reset/Kconfig b/drivers/reset/Kconfig
index 3ad7817ce1f0..45e70524af36 100644
--- a/drivers/reset/Kconfig
+++ b/drivers/reset/Kconfig
@@ -99,7 +99,7 @@ config RESET_PISTACHIO
This enables the reset driver for ImgTec Pistachio SoCs.

config RESET_QCOM_AOSS
- bool "Qcom AOSS Reset Driver"
+ tristate "Qcom AOSS Reset Driver"
depends on ARCH_QCOM || COMPILE_TEST
help
This enables the AOSS (always on subsystem) reset driver
diff --git a/drivers/reset/reset-qcom-aoss.c b/drivers/reset/reset-qcom-aoss.c
index 36db96750450..76367f17fc73 100644
--- a/drivers/reset/reset-qcom-aoss.c
+++ b/drivers/reset/reset-qcom-aoss.c
@@ -127,7 +127,7 @@ static struct platform_driver qcom_aoss_reset_driver = {
},
};

-builtin_platform_driver(qcom_aoss_reset_driver);
+module_platform_driver(qcom_aoss_reset_driver);

MODULE_DESCRIPTION("Qualcomm AOSS Reset Driver");
MODULE_LICENSE("GPL v2");
--
2.17.1