diff options
Diffstat (limited to 'extras/recipes-kernel/linux/linux-omap-2.6.39/pm/linux-omap-2.6.39-ti-pm/0011-OMAP3-SR-enable-disable-SR-only-on-need.patch')
-rw-r--r-- | extras/recipes-kernel/linux/linux-omap-2.6.39/pm/linux-omap-2.6.39-ti-pm/0011-OMAP3-SR-enable-disable-SR-only-on-need.patch | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/extras/recipes-kernel/linux/linux-omap-2.6.39/pm/linux-omap-2.6.39-ti-pm/0011-OMAP3-SR-enable-disable-SR-only-on-need.patch b/extras/recipes-kernel/linux/linux-omap-2.6.39/pm/linux-omap-2.6.39-ti-pm/0011-OMAP3-SR-enable-disable-SR-only-on-need.patch new file mode 100644 index 00000000..b96682ea --- /dev/null +++ b/extras/recipes-kernel/linux/linux-omap-2.6.39/pm/linux-omap-2.6.39-ti-pm/0011-OMAP3-SR-enable-disable-SR-only-on-need.patch | |||
@@ -0,0 +1,41 @@ | |||
1 | From 4aa67e94d6b13905abcf3e95cb66ea7be9c2e8dd Mon Sep 17 00:00:00 2001 | ||
2 | From: Nishanth Menon <nm@ti.com> | ||
3 | Date: Mon, 14 Feb 2011 21:14:17 +0530 | ||
4 | Subject: [PATCH 11/12] OMAP3+: SR: enable/disable SR only on need | ||
5 | |||
6 | Since we already know the state of the autocomp enablement, we can | ||
7 | see if the requested state is different from the current state and | ||
8 | enable/disable SR only on the need basis. | ||
9 | |||
10 | Signed-off-by: Nishanth Menon <nm@ti.com> | ||
11 | Signed-off-by: Kevin Hilman <khilman@ti.com> | ||
12 | Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> | ||
13 | --- | ||
14 | arch/arm/mach-omap2/smartreflex.c | 11 +++++++---- | ||
15 | 1 files changed, 7 insertions(+), 4 deletions(-) | ||
16 | |||
17 | diff --git a/arch/arm/mach-omap2/smartreflex.c b/arch/arm/mach-omap2/smartreflex.c | ||
18 | index 616ef62..3bd9fac 100644 | ||
19 | --- a/arch/arm/mach-omap2/smartreflex.c | ||
20 | +++ b/arch/arm/mach-omap2/smartreflex.c | ||
21 | @@ -807,10 +807,13 @@ static int omap_sr_autocomp_store(void *data, u64 val) | ||
22 | return -EINVAL; | ||
23 | } | ||
24 | |||
25 | - if (!val) | ||
26 | - sr_stop_vddautocomp(sr_info); | ||
27 | - else | ||
28 | - sr_start_vddautocomp(sr_info); | ||
29 | + /* control enable/disable only if there is a delta in value */ | ||
30 | + if (sr_info->autocomp_active != val) { | ||
31 | + if (!val) | ||
32 | + sr_stop_vddautocomp(sr_info); | ||
33 | + else | ||
34 | + sr_start_vddautocomp(sr_info); | ||
35 | + } | ||
36 | |||
37 | return 0; | ||
38 | } | ||
39 | -- | ||
40 | 1.6.6.1 | ||
41 | |||