2015-07-10 06:38:15

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH] vfio: Drop owner assignment from platform_driver

platform_driver does not need to set an owner because
platform_driver_register() will set it.

Signed-off-by: Krzysztof Kozlowski <[email protected]>

---

The coccinelle script which generated the patch was sent here:
http://www.spinics.net/lists/kernel/msg2029903.html
---
drivers/vfio/platform/vfio_platform.c | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/vfio/platform/vfio_platform.c b/drivers/vfio/platform/vfio_platform.c
index cef645c83996..09a8caa4eda9 100644
--- a/drivers/vfio/platform/vfio_platform.c
+++ b/drivers/vfio/platform/vfio_platform.c
@@ -91,7 +91,6 @@ static struct platform_driver vfio_platform_driver = {
.remove = vfio_platform_remove,
.driver = {
.name = "vfio-platform",
- .owner = THIS_MODULE,
},
};

--
1.9.1


2015-07-10 08:05:09

by Baptiste Reynal

[permalink] [raw]
Subject: Re: [PATCH] vfio: Drop owner assignment from platform_driver

Thanks for the point Krzysztof.

Acked-by: Baptiste Reynal <[email protected]>

On Fri, Jul 10, 2015 at 8:37 AM, Krzysztof Kozlowski
<[email protected]> wrote:
> platform_driver does not need to set an owner because
> platform_driver_register() will set it.
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>
>
> ---
>
> The coccinelle script which generated the patch was sent here:
> http://www.spinics.net/lists/kernel/msg2029903.html
> ---
> drivers/vfio/platform/vfio_platform.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/vfio/platform/vfio_platform.c b/drivers/vfio/platform/vfio_platform.c
> index cef645c83996..09a8caa4eda9 100644
> --- a/drivers/vfio/platform/vfio_platform.c
> +++ b/drivers/vfio/platform/vfio_platform.c
> @@ -91,7 +91,6 @@ static struct platform_driver vfio_platform_driver = {
> .remove = vfio_platform_remove,
> .driver = {
> .name = "vfio-platform",
> - .owner = THIS_MODULE,
> },
> };
>
> --
> 1.9.1
>