Skip to contentSkip to conversation

reset: qcom-aoss: Allow CONFIG_RESET_QCOM_AOSS to be a tristate

PATCH Applied John Stultz 3 participants 3 messages Jan 8, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 reset: qcom-aoss: Allow CONFIG_RESET_QCOM_AOSS to be a tristate

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() and adds a MODULE_DEVICE_TABLE() entry.

Cc Todd Kjos <[email protected]>
Cc Alistair Delva <[email protected]>
Cc Bjorn Andersson <[email protected]>
Cc Amit Pundir <[email protected]>
Cc Philipp Zabel <[email protected]>

---
v2: Fix builtin_platform_driver line in driver code
v3: Add MODULE_DEVICE_TABLE() as suggested by Bjorn

---
 drivers/reset/Kconfig           | 2 +-
 drivers/reset/reset-qcom-aoss.c | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)
drivers/reset/Kconfig +1 -1
index 3ad7817ce1f0..45e70524af36 100644
@@ -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
drivers/reset/reset-qcom-aoss.c +2 -1
index 36db96750450..9333b923dda0 100644
@@ -118,6 +118,7 @@ static const struct of_device_id qcom_aoss_reset_of_match[] = {
 	{ .compatible = "qcom,sdm845-aoss-cc", .data = &sdm845_aoss_desc },
 	{}
 };
+MODULE_DEVICE_TABLE(of, qcom_aoss_reset_of_match);
 
 static struct platform_driver qcom_aoss_reset_driver = {
 	.probe = qcom_aoss_reset_probe,
@@ -127,7 +128,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");
Signature · 1 line
2.17.1
Reviewed-by on v3 1/1
#1 lore raw
Quoted 6 lines · John Stultz

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() and adds a MODULE_DEVICE_TABLE() entry.

Quoted 6 lines
Cc Todd Kjos <[email protected]>
Cc Alistair Delva <[email protected]>
Cc Bjorn Andersson <[email protected]>
Cc Amit Pundir <[email protected]>
Cc Philipp Zabel <[email protected]>
Quoted 45 lines

---
v2: Fix builtin_platform_driver line in driver code
v3: Add MODULE_DEVICE_TABLE() as suggested by Bjorn

---
 drivers/reset/Kconfig           | 2 +-
 drivers/reset/reset-qcom-aoss.c | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)
drivers/reset/Kconfig +1 -1
index 3ad7817ce1f0..45e70524af36 100644
@@ -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
drivers/reset/reset-qcom-aoss.c +2 -1
index 36db96750450..9333b923dda0 100644
@@ -118,6 +118,7 @@ static const struct of_device_id qcom_aoss_reset_of_match[] = {
 	{ .compatible = "qcom,sdm845-aoss-cc", .data = &sdm845_aoss_desc },
 	{}
 };
+MODULE_DEVICE_TABLE(of, qcom_aoss_reset_of_match);
 
 static struct platform_driver qcom_aoss_reset_driver = {
 	.probe = qcom_aoss_reset_probe,
@@ -127,7 +128,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");
Signature · 1 line
2.17.1
maintainer Applied
#2 lore raw

Hi John, Bjorn,

Quoted 8 lines · Bjorn Andersson
Quoted 6 lines · John Stultz

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() and adds a MODULE_DEVICE_TABLE() entry.

Quoted 8 lines
Quoted 6 lines
Cc Todd Kjos <[email protected]>
Cc Alistair Delva <[email protected]>
Cc Bjorn Andersson <[email protected]>
Cc Amit Pundir <[email protected]>
Cc Philipp Zabel <[email protected]>

Thank you, applied to reset/next.

regards
Philipp