build_wl18xx: add patch mechanism and bluetooth components
[wilink8-wlan/build-utilites.git] / patches / kernel_patches / imx-3.10.53 / 0005-st_kim-allow-suspend-if-callback-is-not-registered.patch
1 From 9f77068002ef057a1e01496f612853a6b35dde00 Mon Sep 17 00:00:00 2001
2 From: Eyal Reizer <eyalr@ti.com>
3 Date: Wed, 29 Jan 2014 09:03:41 +0200
4 Subject: [PATCH 5/7] st_kim: allow suspend if callback is not registered
6 Suspend/resume was failing if callbacks were not registered.
7 As it is ok not to do anything when suspending fix this
8 so it soen't return an error and allow the system to suspend.
10 Signed-off-by: Eyal Reizer <eyalr@ti.com>
11 ---
12  drivers/misc/ti-st/st_kim.c |    4 ++--
13  1 file changed, 2 insertions(+), 2 deletions(-)
15 diff --git a/drivers/misc/ti-st/st_kim.c b/drivers/misc/ti-st/st_kim.c
16 index fbf4dfd..dbd22e3 100644
17 --- a/drivers/misc/ti-st/st_kim.c
18 +++ b/drivers/misc/ti-st/st_kim.c
19 @@ -839,7 +839,7 @@ static int kim_suspend(struct platform_device *pdev, pm_message_t state)
20         if (pdata->suspend)
21                 return pdata->suspend(pdev, state);
22  
23 -       return -EOPNOTSUPP;
24 +       return 0;
25  }
26  
27  static int kim_resume(struct platform_device *pdev)
28 @@ -849,7 +849,7 @@ static int kim_resume(struct platform_device *pdev)
29         if (pdata->resume)
30                 return pdata->resume(pdev);
31  
32 -       return -EOPNOTSUPP;
33 +       return 0;
34  }
35  
36  /**********************************************************************/
37 -- 
38 1.7.9.5