Skip to contentSkip to conversation

Revert "tests/kms_psr_sink_crc: Wait 2 vblanks before grabing the new crc."

PATCH New Rodrigo Vivi 1 participant 2 messages Oct 13, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 Revert "tests/kms_psr_sink_crc: Wait 2 vblanks before grabing the new crc."

This reverts
commit d190a1f9668680c7a429110c91f8faa27949b220.
Author: Rodrigo Vivi <[email protected]>
Date: Wed Sep 3 21:26:29 2014 -0400

tests/kms_psr_sink_crc: Wait 2 vblanks before grabing the new crc.

Sink CRC is fixed on kernel to wait as many vblanks as needed. It was fixed by:
commit ad9dc91b6e21266bfc6f466db4b95e10211f31ee
Author: Rodrigo Vivi <[email protected]>
Date: Tue Sep 16 19:18:12 2014 -0400

drm/i915: Fix Sink CRC

This this fix in place we don't need this extra 2 vblanks on test case itself.

---
 tests/kms_psr_sink_crc.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
tests/kms_psr_sink_crc.c +1 -4
index ad7ab97..c22c16e 100644
@@ -243,9 +243,6 @@ static void get_sink_crc(data_t *data, char *crc) {
 	int ret;
 	FILE *file;
 
-	igt_wait_for_vblank(data->drm_fd, 0);
-	igt_wait_for_vblank(data->drm_fd, 0);
-
 	file = igt_debugfs_fopen("i915_sink_crc_eDP1", "r");
 	igt_require(file);
 
@@ -417,7 +414,7 @@ static void run_test(data_t *data)
 		    c->connection != DRM_MODE_CONNECTED)
 			continue;
 
-		igt_output_set_pipe(output, 0);
+		igt_output_set_pipe(output, PIPE_ANY);
 		data->crtc_id = output->config.crtc->crtc_id;
 
 		mode = igt_output_get_mode(output);
Signature · 1 line
1.9.3
#1 lore raw

PATCH 2/2 Revert "tests/kms_sink_crc_basic: Wait 2 vblanks before grabing the new crc."

This reverts
commit d92fbc23138b1014e8574daf29dbb06b8c81aa7a.
Author: Rodrigo Vivi <[email protected]>
Date: Tue Sep 9 12:25:47 2014 -0400

tests/kms_sink_crc_basic: Wait 2 vblanks before grabing the new crc.

Sink CRC is fixed on kernel to wait as many vblanks as needed. It was fixed b
commit ad9dc91b6e21266bfc6f466db4b95e10211f31ee
Author: Rodrigo Vivi <[email protected]>
Date: Tue Sep 16 19:18:12 2014 -0400

drm/i915: Fix Sink CRC

This this fix in place we don't need this extra 2 vblanks on test case itself

---
 tests/kms_sink_crc_basic.c | 16 +++++-----------
 1 file changed, 5 insertions(+), 11 deletions(-)
tests/kms_sink_crc_basic.c +5 -11
index f02a950..5fb27d9 100644
@@ -48,15 +48,9 @@ typedef struct {
 	igt_plane_t *primary;
 } data_t;
 
-static void get_crc(data_t *data, char *crc) {
+static void get_crc(char *crc) {
 	int ret;
-	FILE *file;
-
-	igt_wait_for_vblank(data->drm_fd, 0);
-	igt_wait_for_vblank(data->drm_fd, 0);
-
-	file = igt_debugfs_fopen("i915_sink_crc_eDP1", "r");
-
+	FILE *file = fopen("/sys/kernel/debug/dri/0/i915_sink_crc_eDP1", "r");
 	igt_require(file);
 
 	ret = fscanf(file, "%s\n", crc);
@@ -117,7 +111,7 @@ static void basic_sink_crc_check(data_t *data)
 	igt_display_commit(&data->display);
 
 	/* It should be Green */
-	get_crc(data, crc);
+	get_crc(crc);
 	assert_color(crc, GREEN);
 
 	/* Go Red */
@@ -125,7 +119,7 @@ static void basic_sink_crc_check(data_t *data)
 	igt_display_commit(&data->display);
 
 	/* It should be Red */
-	get_crc(data, crc);
+	get_crc(crc);
 	assert_color(crc, RED);
 }
 
@@ -142,7 +136,7 @@ static void run_test(data_t *data)
 		    c->connection != DRM_MODE_CONNECTED)
 			continue;
 
-		igt_output_set_pipe(output, 0);
+		igt_output_set_pipe(output, PIPE_ANY);
 
 		mode = igt_output_get_mode(output);
 
Signature · 1 line
1.9.3