linux/tools/testing/selftests/cpufreq
Nícolas F. R. A. Prado bf3cbf2805 kselftest: cpufreq: Get rid of double suspend in rtcwake case
[ Upstream commit 23b88515a3 ]

Commit 0b631ed3ce ("kselftest: cpufreq: Add RTC wakeup alarm") added
support for automatic wakeup in the suspend routine of the cpufreq
kselftest by using rtcwake, however it left the manual power state
change in the common path. The end result is that when running the
cpufreq kselftest with '-t suspend_rtc' or '-t hibernate_rtc', the
system will go to sleep and be woken up by the RTC, but then immediately
go to sleep again with no wakeup programmed, so it will sleep forever in
an automated testing setup.

Fix this by moving the manual power state change so that it only happens
when not using rtcwake.

Link: https://lore.kernel.org/r/20250430-ksft-cpufreq-suspend-rtc-double-fix-v1-1-dc17a729c5a7@collabora.com
Fixes: 0b631ed3ce ("kselftest: cpufreq: Add RTC wakeup alarm")
Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
History 2025-06-19 15:31:28 +02:00
..
config selftests/cpufreq: Don't enable generic lock debugging options 2023-06-12 16:39:11 -06:00
cpu.sh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
cpufreq.sh kselftest: cpufreq: Get rid of double suspend in rtcwake case 2025-06-19 15:31:28 +02:00
governor.sh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
main.sh kselftest: cpufreq: Add RTC wakeup alarm 2024-07-31 11:42:36 -06:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
module.sh selftests: cpufreq: conform test to TAP 2024-05-06 13:57:20 -06:00
special-tests.sh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00