diff options
author | John Stultz <[email protected]> | 2020-03-26 22:44:57 +0000 |
---|---|---|
committer | Bjorn Andersson <[email protected]> | 2020-04-14 15:39:56 -0700 |
commit | f29808b2fb85a7ff2d4830aa1cb736c8c9b986f4 (patch) | |
tree | ae52cfa93a11e7a08a19e3c0d711fd6f307be416 | |
parent | d4889ec1fc6ac6321cc1e8b35bb656f970926a09 (diff) |
soc: qcom: rpmpd: Allow RPMPD driver to be loaded as a module
This patch allow the rpmpd driver to be loaded as a permenent
module. Meaning it can be loaded from a module, but then cannot
be unloaded.
Ideally, it would include a remove hook and related logic, but
apparently the genpd code isn't able to track usage and cleaning
things up? (See: https://lkml.org/lkml/2019/1/24/38)
So making it a permenent module at least improves things slightly
over requiring it to be a built in driver.
Cc: Todd Kjos <[email protected]>
Cc: Saravana Kannan <[email protected]>
Cc: Andy Gross <[email protected]>
Cc: Bjorn Andersson <[email protected]>
Cc: Rajendra Nayak <[email protected]>
Cc: [email protected]
Acked-by: Saravana Kannan <[email protected]>
Tested-by: Bjorn Andersson <[email protected]>
Reviewed-by: Bjorn Andersson <[email protected]>
Signed-off-by: John Stultz <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Bjorn Andersson <[email protected]>
-rw-r--r-- | drivers/soc/qcom/Kconfig | 4 | ||||
-rw-r--r-- | drivers/soc/qcom/rpmpd.c | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/drivers/soc/qcom/Kconfig b/drivers/soc/qcom/Kconfig index c2a8fcdb24b9..0d0123f6ec0a 100644 --- a/drivers/soc/qcom/Kconfig +++ b/drivers/soc/qcom/Kconfig @@ -126,8 +126,8 @@ config QCOM_RPMHPD for the voltage rail. config QCOM_RPMPD - bool "Qualcomm RPM Power domain driver" - depends on QCOM_SMD_RPM=y + tristate "Qualcomm RPM Power domain driver" + depends on QCOM_SMD_RPM help QCOM RPM Power domain driver to support power-domains with performance states. The driver communicates a performance state diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c index 2b1834c5609a..f2168e4259b2 100644 --- a/drivers/soc/qcom/rpmpd.c +++ b/drivers/soc/qcom/rpmpd.c @@ -4,6 +4,7 @@ #include <linux/err.h> #include <linux/init.h> #include <linux/kernel.h> +#include <linux/module.h> #include <linux/mutex.h> #include <linux/pm_domain.h> #include <linux/of.h> @@ -226,6 +227,7 @@ static const struct of_device_id rpmpd_match_table[] = { { .compatible = "qcom,qcs404-rpmpd", .data = &qcs404_desc }, { } }; +MODULE_DEVICE_TABLE(of, rpmpd_match_table); static int rpmpd_send_enable(struct rpmpd *pd, bool enable) { @@ -422,3 +424,6 @@ static int __init rpmpd_init(void) return platform_driver_register(&rpmpd_driver); } core_initcall(rpmpd_init); + +MODULE_DESCRIPTION("Qualcomm Technologies, Inc. RPM Power Domain Driver"); +MODULE_LICENSE("GPL v2"); |