]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
CBUS: Manage bias voltage in retu-headset suspend/resume code
authorJarkko Nikula <jarkko.nikula@nokia.com>
Wed, 31 Oct 2007 12:04:41 +0000 (14:04 +0200)
committerTony Lindgren <tony@atomide.com>
Thu, 1 Nov 2007 09:03:12 +0000 (02:03 -0700)
Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
drivers/cbus/retu-headset.c

index ac21394251375c1035dae08a8c770d1d0573df2e..7f3f808bb55c3b7e7c3c1a3cc8e7ef0ca400085d 100644 (file)
@@ -288,11 +288,21 @@ static int retu_headset_remove(struct platform_device *pdev)
 static int retu_headset_suspend(struct platform_device *pdev,
                                pm_message_t mesg)
 {
+       struct retu_headset *hs = platform_get_drvdata(pdev);
+
+       if (hs->bias_enabled)
+               retu_headset_set_bias(0);
+
        return 0;
 }
 
 static int retu_headset_resume(struct platform_device *pdev)
 {
+       struct retu_headset *hs = platform_get_drvdata(pdev);
+
+       if (hs->bias_enabled)
+               retu_headset_set_bias(1);
+
        return 0;
 }