kernel_optimize_test/drivers/base/power
Rafael J. Wysocki 0cc2b4e5a0 PM / QoS: Fix device resume latency PM QoS
The special value of 0 for device resume latency PM QoS means
"no restriction", but there are two problems with that.

First, device resume latency PM QoS requests with 0 as the
value are always put in front of requests with positive
values in the priority lists used internally by the PM QoS
framework, causing 0 to be chosen as an effective constraint
value.  However, that 0 is then interpreted as "no restriction"
effectively overriding the other requests with specific
restrictions which is incorrect.

Second, the users of device resume latency PM QoS have no
way to specify that *any* resume latency at all should be
avoided, which is an artificial limitation in general.

To address these issues, modify device resume latency PM QoS to
use S32_MAX as the "no constraint" value and 0 as the "no
latency at all" one and rework its users (the cpuidle menu
governor, the genpd QoS governor and the runtime PM framework)
to follow these changes.

Also add a special "n/a" value to the corresponding user space I/F
to allow user space to indicate that it cannot accept any resume
latencies at all for the given device.

Fixes: 85dc0b8a40 (PM / QoS: Make it possible to expose PM QoS latency constraints)
Link: https://bugzilla.kernel.org/show_bug.cgi?id=197323
Reported-by: Reinette Chatre <reinette.chatre@intel.com>
Tested-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Alex Shi <alex.shi@linaro.org>
Cc: All applicable <stable@vger.kernel.org>
2017-10-24 15:20:45 +02:00
..
opp PM / OPP: Call notifier without holding opp_table->lock 2017-09-26 00:44:32 +02:00
clock_ops.c
common.c
domain_governor.c PM / QoS: Fix device resume latency PM QoS 2017-10-24 15:20:45 +02:00
domain.c PM / Domains: Convert to using %pOF instead of full_name 2017-08-25 01:19:36 +02:00
generic_ops.c
main.c PM: core: Fix device_pm_check_callbacks() 2017-09-19 22:58:27 +02:00
Makefile
power.h
qos.c PM / QoS: Fix device resume latency PM QoS 2017-10-24 15:20:45 +02:00
runtime.c PM / QoS: Fix device resume latency PM QoS 2017-10-24 15:20:45 +02:00
sysfs.c PM / QoS: Fix device resume latency PM QoS 2017-10-24 15:20:45 +02:00
trace.c
wakeirq.c PM / wakeirq: report a wakeup_event on dedicated wekup irq 2017-02-13 22:29:30 +01:00
wakeup.c Merge branch 'pm-sleep' 2017-09-04 00:06:02 +02:00