* [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove
@ 2012-07-02 8:40 Devendra Naga
2012-07-02 13:53 ` Bryan Wu
0 siblings, 1 reply; 5+ messages in thread
From: Devendra Naga @ 2012-07-02 8:40 UTC (permalink / raw)
To: Bryan Wu, Richard Purdie, linux-leds, linux-kernel; +Cc: Devendra Naga
the platform_set_drvdata (pdev, NULL) to be set at the remove of the
driver, as we have set the platform data to led at probe.
Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
---
drivers/leds/leds-mc13783.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/leds/leds-mc13783.c b/drivers/leds/leds-mc13783.c
index 4cc6a2e..6515c11 100644
--- a/drivers/leds/leds-mc13783.c
+++ b/drivers/leds/leds-mc13783.c
@@ -372,6 +372,7 @@ static int __devexit mc13783_led_remove(struct platform_device *pdev)
mc13xxx_unlock(dev);
+ platform_set_drvdata(pdev, NULL);
kfree(led);
return 0;
}
--
1.7.9.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove
2012-07-02 8:40 [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove Devendra Naga
@ 2012-07-02 13:53 ` Bryan Wu
2012-07-02 15:56 ` devendra.aaru
0 siblings, 1 reply; 5+ messages in thread
From: Bryan Wu @ 2012-07-02 13:53 UTC (permalink / raw)
To: Devendra Naga; +Cc: Richard Purdie, linux-leds, linux-kernel
On Mon, Jul 2, 2012 at 4:40 PM, Devendra Naga <devendra.aaru@gmail.com> wrote:
> the platform_set_drvdata (pdev, NULL) to be set at the remove of the
> driver, as we have set the platform data to led at probe.
>
> Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Nice catch. I applied this patch in my for-next branch.
But I also find the same issue in other LED drivers, are you
interested in fixing them?
Thanks,
-Bryan
> ---
> drivers/leds/leds-mc13783.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/leds/leds-mc13783.c b/drivers/leds/leds-mc13783.c
> index 4cc6a2e..6515c11 100644
> --- a/drivers/leds/leds-mc13783.c
> +++ b/drivers/leds/leds-mc13783.c
> @@ -372,6 +372,7 @@ static int __devexit mc13783_led_remove(struct platform_device *pdev)
>
> mc13xxx_unlock(dev);
>
> + platform_set_drvdata(pdev, NULL);
> kfree(led);
> return 0;
> }
> --
> 1.7.9.5
>
--
Bryan Wu <bryan.wu@canonical.com>
Kernel Developer +86.186-168-78255 Mobile
Canonical Ltd. www.canonical.com
Ubuntu - Linux for human beings | www.ubuntu.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove
2012-07-02 13:53 ` Bryan Wu
@ 2012-07-02 15:56 ` devendra.aaru
2012-07-02 18:10 ` devendra.aaru
0 siblings, 1 reply; 5+ messages in thread
From: devendra.aaru @ 2012-07-02 15:56 UTC (permalink / raw)
To: Bryan Wu; +Cc: Richard Purdie, linux-leds, linux-kernel
On Mon, Jul 2, 2012 at 7:23 PM, Bryan Wu <bryan.wu@canonical.com> wrote:
> On Mon, Jul 2, 2012 at 4:40 PM, Devendra Naga <devendra.aaru@gmail.com> wrote:
>> the platform_set_drvdata (pdev, NULL) to be set at the remove of the
>> driver, as we have set the platform data to led at probe.
>>
>> Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
>
> Nice catch. I applied this patch in my for-next branch.
>
> But I also find the same issue in other LED drivers, are you
> interested in fixing them?
>
Yes, i will do those.
I will send out changes...
> Thanks,
> -Bryan
>
Thanks
>> ---
>> drivers/leds/leds-mc13783.c | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/drivers/leds/leds-mc13783.c b/drivers/leds/leds-mc13783.c
>> index 4cc6a2e..6515c11 100644
>> --- a/drivers/leds/leds-mc13783.c
>> +++ b/drivers/leds/leds-mc13783.c
>> @@ -372,6 +372,7 @@ static int __devexit mc13783_led_remove(struct platform_device *pdev)
>>
>> mc13xxx_unlock(dev);
>>
>> + platform_set_drvdata(pdev, NULL);
>> kfree(led);
>> return 0;
>> }
>> --
>> 1.7.9.5
>>
>
>
>
> --
> Bryan Wu <bryan.wu@canonical.com>
> Kernel Developer +86.186-168-78255 Mobile
> Canonical Ltd. www.canonical.com
> Ubuntu - Linux for human beings | www.ubuntu.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove
2012-07-02 15:56 ` devendra.aaru
@ 2012-07-02 18:10 ` devendra.aaru
2012-07-03 2:28 ` Bryan Wu
0 siblings, 1 reply; 5+ messages in thread
From: devendra.aaru @ 2012-07-02 18:10 UTC (permalink / raw)
To: Bryan Wu; +Cc: Richard Purdie, linux-leds, linux-kernel
Hi Bryan,
I Made all the necessary changes, and it touched 21 drivers overall,
and i compile tested all except leds-sunfire as i dont have a
cross-toolchain for that.
all patches are compile tested with
gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3, ( my machine's)
arm-linux-gnueabihf-gcc (crosstool-NG linaro-1.13.1-2012.05-20120523 -
Linaro GCC 2012.05) 4.7.1 20120514 (prerelease) (ARM toolchain's)
at each cross-compile of a driver i selected the defconfig of each
machine, fox ex. for leds-netxbig i chose kirkwood-defconfig, and for
leds-s3c24xx i chose s3c2410_defconfig.
Now i have only 1 question in mind :).
do i need to submit all in a single patch? or patch per driver?
Thanks,
Devendra.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove
2012-07-02 18:10 ` devendra.aaru
@ 2012-07-03 2:28 ` Bryan Wu
0 siblings, 0 replies; 5+ messages in thread
From: Bryan Wu @ 2012-07-03 2:28 UTC (permalink / raw)
To: devendra.aaru; +Cc: Richard Purdie, linux-leds, linux-kernel
On Tue, Jul 3, 2012 at 2:10 AM, devendra.aaru <devendra.aaru@gmail.com> wrote:
> Hi Bryan,
>
> I Made all the necessary changes, and it touched 21 drivers overall,
> and i compile tested all except leds-sunfire as i dont have a
> cross-toolchain for that.
> all patches are compile tested with
>
> gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3, ( my machine's)
> arm-linux-gnueabihf-gcc (crosstool-NG linaro-1.13.1-2012.05-20120523 -
> Linaro GCC 2012.05) 4.7.1 20120514 (prerelease) (ARM toolchain's)
>
> at each cross-compile of a driver i selected the defconfig of each
> machine, fox ex. for leds-netxbig i chose kirkwood-defconfig, and for
> leds-s3c24xx i chose s3c2410_defconfig.
>
Very good, thanks a lot.
> Now i have only 1 question in mind :).
>
> do i need to submit all in a single patch? or patch per driver?
>
I prefer to one patch per driver and please add the driver maintainers
in you Cc list of each patch.
-Bryan
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-07-03 2:28 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-02 8:40 [PATCH] leds-mc13783: set platform data to NULL at mc13783_led_remove Devendra Naga
2012-07-02 13:53 ` Bryan Wu
2012-07-02 15:56 ` devendra.aaru
2012-07-02 18:10 ` devendra.aaru
2012-07-03 2:28 ` Bryan Wu
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.