diff mbox series

coresight: Remove unnecessary THIS_MODULE of funnel and replicator driver

Message ID 1604409708-12400-1-git-send-email-liuqi115@huawei.com (mailing list archive)
State New, archived
Headers show
Series coresight: Remove unnecessary THIS_MODULE of funnel and replicator driver | expand

Commit Message

liuqi (BA) Nov. 3, 2020, 1:21 p.m. UTC
As THIS_MODULE has been set in platform_driver_register(), so remove it
from static funnel driver and static replicator driver to avoid set it
twice.

Signed-off-by: Qi Liu <liuqi115@huawei.com>
---
 drivers/hwtracing/coresight/coresight-funnel.c     | 2 +-
 drivers/hwtracing/coresight/coresight-replicator.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

--
2.8.1

Comments

Mathieu Poirier Nov. 3, 2020, 4:12 p.m. UTC | #1
On Tue, Nov 03, 2020 at 09:21:48PM +0800, Qi Liu wrote:
> As THIS_MODULE has been set in platform_driver_register(), so remove it
> from static funnel driver and static replicator driver to avoid set it
> twice.
> 
> Signed-off-by: Qi Liu <liuqi115@huawei.com>
> ---
>  drivers/hwtracing/coresight/coresight-funnel.c     | 2 +-
>  drivers/hwtracing/coresight/coresight-replicator.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/hwtracing/coresight/coresight-funnel.c b/drivers/hwtracing/coresight/coresight-funnel.c
> index af40814..39be46b 100644
> --- a/drivers/hwtracing/coresight/coresight-funnel.c
> +++ b/drivers/hwtracing/coresight/coresight-funnel.c
> @@ -356,7 +356,7 @@ static struct platform_driver static_funnel_driver = {
>  	.remove          = static_funnel_remove,
>  	.driver         = {
>  		.name   = "coresight-static-funnel",
> -		.owner	= THIS_MODULE,
> +		/* THIS_MODULE is taken care of by platform_driver_register() */
>  		.of_match_table = static_funnel_match,
>  		.acpi_match_table = ACPI_PTR(static_funnel_ids),
>  		.pm	= &funnel_dev_pm_ops,
> diff --git a/drivers/hwtracing/coresight/coresight-replicator.c b/drivers/hwtracing/coresight/coresight-replicator.c
> index 62afdde..6772f23 100644
> --- a/drivers/hwtracing/coresight/coresight-replicator.c
> +++ b/drivers/hwtracing/coresight/coresight-replicator.c
> @@ -374,7 +374,7 @@ static struct platform_driver static_replicator_driver = {
>  	.remove         = static_replicator_remove,
>  	.driver         = {
>  		.name   = "coresight-static-replicator",
> -		.owner	= THIS_MODULE,
> +		/* THIS_MODULE is taken care of by platform_driver_register() */

I have applied your patch.  Next time please version you revisions.

Thanks,
Mathieu

>  		.of_match_table = of_match_ptr(static_replicator_match),
>  		.acpi_match_table = ACPI_PTR(static_replicator_acpi_ids),
>  		.pm	= &replicator_dev_pm_ops,
> --
> 2.8.1
>
diff mbox series

Patch

diff --git a/drivers/hwtracing/coresight/coresight-funnel.c b/drivers/hwtracing/coresight/coresight-funnel.c
index af40814..39be46b 100644
--- a/drivers/hwtracing/coresight/coresight-funnel.c
+++ b/drivers/hwtracing/coresight/coresight-funnel.c
@@ -356,7 +356,7 @@  static struct platform_driver static_funnel_driver = {
 	.remove          = static_funnel_remove,
 	.driver         = {
 		.name   = "coresight-static-funnel",
-		.owner	= THIS_MODULE,
+		/* THIS_MODULE is taken care of by platform_driver_register() */
 		.of_match_table = static_funnel_match,
 		.acpi_match_table = ACPI_PTR(static_funnel_ids),
 		.pm	= &funnel_dev_pm_ops,
diff --git a/drivers/hwtracing/coresight/coresight-replicator.c b/drivers/hwtracing/coresight/coresight-replicator.c
index 62afdde..6772f23 100644
--- a/drivers/hwtracing/coresight/coresight-replicator.c
+++ b/drivers/hwtracing/coresight/coresight-replicator.c
@@ -374,7 +374,7 @@  static struct platform_driver static_replicator_driver = {
 	.remove         = static_replicator_remove,
 	.driver         = {
 		.name   = "coresight-static-replicator",
-		.owner	= THIS_MODULE,
+		/* THIS_MODULE is taken care of by platform_driver_register() */
 		.of_match_table = of_match_ptr(static_replicator_match),
 		.acpi_match_table = ACPI_PTR(static_replicator_acpi_ids),
 		.pm	= &replicator_dev_pm_ops,