[i-g-t,04/10] lib/psr: Only care about DEEP_SLEEP state for PSR2

Submitted by Souza, Jose on Jan. 12, 2019, 1:46 a.m.

Details

Message ID 20190112014607.13446-4-jose.souza@intel.com
State Accepted
Commit 12e31ff245bb62a2b8c500cac9f8dcaa2015f6ca
Headers show
Series "Series without cover letter" ( rev: 1 ) in IGT

Not browsing as part of any series.

Commit Message

Souza, Jose Jan. 12, 2019, 1:46 a.m.
To check if PSR is active it search for SRDENT for PSR1 and it was
searching for SLEEP for PSR2 but it should really seach for
DEEP_SLEEP as in this state display block is actualy saving a
substancial amount of power.

Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
---
 lib/igt_psr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/lib/igt_psr.c b/lib/igt_psr.c
index a59ff94e..83c5b986 100644
--- a/lib/igt_psr.c
+++ b/lib/igt_psr.c
@@ -33,7 +33,7 @@  static bool psr_active(int debugfs_fd, bool check_active)
 	igt_debugfs_simple_read(debugfs_fd, "i915_edp_psr_status", buf,
 				sizeof(buf));
 
-	active = strstr(buf, "SRDENT") || strstr(buf, "SLEEP");
+	active = strstr(buf, "SRDENT") || strstr(buf, "DEEP_SLEEP");
 	return check_active ? active : !active;
 }