FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu Kernel Team

 
 
LinkBack Thread Tools
 
Old 03-18-2010, 02:38 AM
Bryan Wu
 
Default leds-mc13892: fix suspend/resume

From: Jeremy Kerr <jeremy.kerr@canonical.com>

BugLink: http://bugs.launchpad.net/bugs/537083

The workqueue update for the leds-mc13892 driver introduced a regression
where machine would no longer suspend and resume, as the wrong type was
being retrieved from the platform drvdata.

This change updates the suspend and resume functions to use the struct
mc13892_led type.

Signed-off-by: Jeremy Kerr <jeremy.kerr@canonical.com>
Signed-off-by: Bryan Wu <bryan.wu@canonical.com>
---
drivers/leds/leds-mc13892.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/leds/leds-mc13892.c b/drivers/leds/leds-mc13892.c
index 464bec9..02e7c9d 100644
--- a/drivers/leds/leds-mc13892.c
+++ b/drivers/leds/leds-mc13892.c
@@ -121,17 +121,17 @@ err_free:
#ifdef CONFIG_PM
static int mc13892_led_suspend(struct platform_device *dev, pm_message_t state)
{
- struct led_classdev *led_cdev = platform_get_drvdata(dev);
+ struct mc13892_led *led = platform_get_drvdata(dev);

- led_classdev_suspend(led_cdev);
+ led_classdev_suspend(&led->cdev);
return 0;
}

static int mc13892_led_resume(struct platform_device *dev)
{
- struct led_classdev *led_cdev = platform_get_drvdata(dev);
+ struct mc13892_led *led = platform_get_drvdata(dev);

- led_classdev_resume(led_cdev);
+ led_classdev_resume(&led->cdev);
return 0;
}
#else
--
1.7.0


--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 
Old 03-19-2010, 02:49 PM
Andy Whitcroft
 
Default leds-mc13892: fix suspend/resume

On Thu, Mar 18, 2010 at 11:38:15AM +0800, Bryan Wu wrote:
> From: Jeremy Kerr <jeremy.kerr@canonical.com>
>
> BugLink: http://bugs.launchpad.net/bugs/537083
>
> The workqueue update for the leds-mc13892 driver introduced a regression
> where machine would no longer suspend and resume, as the wrong type was
> being retrieved from the platform drvdata.
>
> This change updates the suspend and resume functions to use the struct
> mc13892_led type.
>
> Signed-off-by: Jeremy Kerr <jeremy.kerr@canonical.com>
> Signed-off-by: Bryan Wu <bryan.wu@canonical.com>
> ---
> drivers/leds/leds-mc13892.c | 8 ++++----
> 1 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/leds/leds-mc13892.c b/drivers/leds/leds-mc13892.c
> index 464bec9..02e7c9d 100644
> --- a/drivers/leds/leds-mc13892.c
> +++ b/drivers/leds/leds-mc13892.c
> @@ -121,17 +121,17 @@ err_free:
> #ifdef CONFIG_PM
> static int mc13892_led_suspend(struct platform_device *dev, pm_message_t state)
> {
> - struct led_classdev *led_cdev = platform_get_drvdata(dev);
> + struct mc13892_led *led = platform_get_drvdata(dev);
>
> - led_classdev_suspend(led_cdev);
> + led_classdev_suspend(&led->cdev);
> return 0;
> }
>
> static int mc13892_led_resume(struct platform_device *dev)
> {
> - struct led_classdev *led_cdev = platform_get_drvdata(dev);
> + struct mc13892_led *led = platform_get_drvdata(dev);
>
> - led_classdev_resume(led_cdev);
> + led_classdev_resume(&led->cdev);
> return 0;
> }
> #else

Looks reasonable.

Acked-by: Andy Whitcroft <apw@canonical.com>

-apw

--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 
Old 03-19-2010, 03:17 PM
Andy Whitcroft
 
Default leds-mc13892: fix suspend/resume

Applied to Lucid.

-apw

--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 

Thread Tools




All times are GMT. The time now is 10:06 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org