diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2016-01-11 19:11:03 -0500 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2016-01-11 19:11:03 -0500 |
commit | a7da4813429cf36abd042e6da72cc6641767d52f (patch) | |
tree | a7552f1e89ae6afb3ebb7051bbac86452a8684f0 | |
parent | 92266e1de4324a23359fe71678cb521987fea0c5 (diff) | |
parent | 84599238ea78d98136fc6f6239a14083128ecf8b (diff) |
Merge branch 'pm-cpuidle'
* pm-cpuidle:
drivers/cpuidle: make cpuidle-exynos.c explicitly non-modular
drivers/cpuidle: make cpuidle-ux500.c explicitly non-modular
drivers/cpuidle: make cpuidle-clps711x.c explicitly non-modular
cpuidle,menu: smooth out measured_us calculation
cpuidle,menu: use interactivity_req to disable polling
cpuidle,x86: increase forced cut-off for polling to 20us
-rw-r--r-- | drivers/cpuidle/cpuidle-clps711x.c | 8 | ||||
-rw-r--r-- | drivers/cpuidle/cpuidle-exynos.c | 5 | ||||
-rw-r--r-- | drivers/cpuidle/cpuidle-ux500.c | 5 | ||||
-rw-r--r-- | drivers/cpuidle/governors/menu.c | 6 |
4 files changed, 10 insertions, 14 deletions
diff --git a/drivers/cpuidle/cpuidle-clps711x.c b/drivers/cpuidle/cpuidle-clps711x.c index 18a7f7380508..66a9f231ec41 100644 --- a/drivers/cpuidle/cpuidle-clps711x.c +++ b/drivers/cpuidle/cpuidle-clps711x.c | |||
@@ -12,7 +12,7 @@ | |||
12 | #include <linux/cpuidle.h> | 12 | #include <linux/cpuidle.h> |
13 | #include <linux/err.h> | 13 | #include <linux/err.h> |
14 | #include <linux/io.h> | 14 | #include <linux/io.h> |
15 | #include <linux/module.h> | 15 | #include <linux/init.h> |
16 | #include <linux/platform_device.h> | 16 | #include <linux/platform_device.h> |
17 | 17 | ||
18 | #define CLPS711X_CPUIDLE_NAME "clps711x-cpuidle" | 18 | #define CLPS711X_CPUIDLE_NAME "clps711x-cpuidle" |
@@ -56,8 +56,4 @@ static struct platform_driver clps711x_cpuidle_driver = { | |||
56 | .name = CLPS711X_CPUIDLE_NAME, | 56 | .name = CLPS711X_CPUIDLE_NAME, |
57 | }, | 57 | }, |
58 | }; | 58 | }; |
59 | module_platform_driver_probe(clps711x_cpuidle_driver, clps711x_cpuidle_probe); | 59 | builtin_platform_driver_probe(clps711x_cpuidle_driver, clps711x_cpuidle_probe); |
60 | |||
61 | MODULE_AUTHOR("Alexander Shiyan <shc_work@mail.ru>"); | ||
62 | MODULE_DESCRIPTION("CLPS711X CPU idle driver"); | ||
63 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/cpuidle/cpuidle-exynos.c b/drivers/cpuidle/cpuidle-exynos.c index b5f0a9cc8185..00cd129b10a4 100644 --- a/drivers/cpuidle/cpuidle-exynos.c +++ b/drivers/cpuidle/cpuidle-exynos.c | |||
@@ -14,7 +14,7 @@ | |||
14 | #include <linux/cpuidle.h> | 14 | #include <linux/cpuidle.h> |
15 | #include <linux/cpu_pm.h> | 15 | #include <linux/cpu_pm.h> |
16 | #include <linux/export.h> | 16 | #include <linux/export.h> |
17 | #include <linux/module.h> | 17 | #include <linux/init.h> |
18 | #include <linux/platform_device.h> | 18 | #include <linux/platform_device.h> |
19 | #include <linux/of.h> | 19 | #include <linux/of.h> |
20 | #include <linux/platform_data/cpuidle-exynos.h> | 20 | #include <linux/platform_data/cpuidle-exynos.h> |
@@ -142,5 +142,4 @@ static struct platform_driver exynos_cpuidle_driver = { | |||
142 | .name = "exynos_cpuidle", | 142 | .name = "exynos_cpuidle", |
143 | }, | 143 | }, |
144 | }; | 144 | }; |
145 | 145 | builtin_platform_driver(exynos_cpuidle_driver); | |
146 | module_platform_driver(exynos_cpuidle_driver); | ||
diff --git a/drivers/cpuidle/cpuidle-ux500.c b/drivers/cpuidle/cpuidle-ux500.c index 8bf895c0017d..7941a090bea6 100644 --- a/drivers/cpuidle/cpuidle-ux500.c +++ b/drivers/cpuidle/cpuidle-ux500.c | |||
@@ -9,7 +9,7 @@ | |||
9 | * published by the Free Software Foundation. | 9 | * published by the Free Software Foundation. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/module.h> | 12 | #include <linux/init.h> |
13 | #include <linux/cpuidle.h> | 13 | #include <linux/cpuidle.h> |
14 | #include <linux/spinlock.h> | 14 | #include <linux/spinlock.h> |
15 | #include <linux/atomic.h> | 15 | #include <linux/atomic.h> |
@@ -124,5 +124,4 @@ static struct platform_driver dbx500_cpuidle_plat_driver = { | |||
124 | }, | 124 | }, |
125 | .probe = dbx500_cpuidle_probe, | 125 | .probe = dbx500_cpuidle_probe, |
126 | }; | 126 | }; |
127 | 127 | builtin_platform_driver(dbx500_cpuidle_plat_driver); | |
128 | module_platform_driver(dbx500_cpuidle_plat_driver); | ||
diff --git a/drivers/cpuidle/governors/menu.c b/drivers/cpuidle/governors/menu.c index 22e4463d1787..7b0971d97cc3 100644 --- a/drivers/cpuidle/governors/menu.c +++ b/drivers/cpuidle/governors/menu.c | |||
@@ -330,7 +330,7 @@ static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev) | |||
330 | * We want to default to C1 (hlt), not to busy polling | 330 | * We want to default to C1 (hlt), not to busy polling |
331 | * unless the timer is happening really really soon. | 331 | * unless the timer is happening really really soon. |
332 | */ | 332 | */ |
333 | if (data->next_timer_us > 5 && | 333 | if (interactivity_req > 20 && |
334 | !drv->states[CPUIDLE_DRIVER_STATE_START].disabled && | 334 | !drv->states[CPUIDLE_DRIVER_STATE_START].disabled && |
335 | dev->states_usage[CPUIDLE_DRIVER_STATE_START].disable == 0) | 335 | dev->states_usage[CPUIDLE_DRIVER_STATE_START].disable == 0) |
336 | data->last_state_idx = CPUIDLE_DRIVER_STATE_START; | 336 | data->last_state_idx = CPUIDLE_DRIVER_STATE_START; |
@@ -404,8 +404,10 @@ static void menu_update(struct cpuidle_driver *drv, struct cpuidle_device *dev) | |||
404 | measured_us = cpuidle_get_last_residency(dev); | 404 | measured_us = cpuidle_get_last_residency(dev); |
405 | 405 | ||
406 | /* Deduct exit latency */ | 406 | /* Deduct exit latency */ |
407 | if (measured_us > target->exit_latency) | 407 | if (measured_us > 2 * target->exit_latency) |
408 | measured_us -= target->exit_latency; | 408 | measured_us -= target->exit_latency; |
409 | else | ||
410 | measured_us /= 2; | ||
409 | 411 | ||
410 | /* Make sure our coefficients do not exceed unity */ | 412 | /* Make sure our coefficients do not exceed unity */ |
411 | if (measured_us > data->next_timer_us) | 413 | if (measured_us > data->next_timer_us) |