From: Gigi Joseph Date: Fri, 9 Jan 2015 03:46:24 +0000 (+0000) Subject: st_kim: allow suspend if callback is not registered X-Git-Tag: firefly_0821_release~176^2~2322^2~82 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4b4aa3ab982e1e6f22a3df12a368803576b73ccf;p=firefly-linux-kernel-4.4.55.git st_kim: allow suspend if callback is not registered Suspend/resume was failing if callbacks were not registered. As it is ok not to do anything when suspending fix this so it soen't return an error and allow the system to suspend. Signed-off-by: Eyal Reizer Signed-off-by: Gigi Joseph Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/misc/ti-st/st_kim.c b/drivers/misc/ti-st/st_kim.c index 68a0b582d81a..f2c1071e54c9 100644 --- a/drivers/misc/ti-st/st_kim.c +++ b/drivers/misc/ti-st/st_kim.c @@ -908,7 +908,7 @@ static int kim_suspend(struct platform_device *pdev, pm_message_t state) if (pdata->suspend) return pdata->suspend(pdev, state); - return -EOPNOTSUPP; + return 0; } static int kim_resume(struct platform_device *pdev) @@ -925,7 +925,7 @@ static int kim_resume(struct platform_device *pdev) if (pdata->resume) return pdata->resume(pdev); - return -EOPNOTSUPP; + return 0; } /**********************************************************************/