mirror of
https://github.com/tiagovignatti/intel-gpu-tools.git
synced 2025-06-20 06:16:13 +00:00
lib/core: add interactive debug point to igt_fail
Useful for inspecting the screen state in kms tests when they fail. Also move the screen clearing in kms_cursor_crc to the bottom. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
This commit is contained in:
parent
e7d26df419
commit
4fec18e5e0
@ -918,6 +918,8 @@ void igt_fail(int exitcode)
|
|||||||
{
|
{
|
||||||
assert(exitcode != IGT_EXIT_SUCCESS && exitcode != IGT_EXIT_SKIP);
|
assert(exitcode != IGT_EXIT_SUCCESS && exitcode != IGT_EXIT_SKIP);
|
||||||
|
|
||||||
|
igt_debug_wait_for_keypress("failure");
|
||||||
|
|
||||||
if (!failed_one)
|
if (!failed_one)
|
||||||
igt_exitcode = exitcode;
|
igt_exitcode = exitcode;
|
||||||
|
|
||||||
|
@ -130,13 +130,14 @@ static void do_single_test(data_t *data, int x, int y)
|
|||||||
/* Now render the same in software and collect crc */
|
/* Now render the same in software and collect crc */
|
||||||
draw_cursor(cr, x, y, data->curw, data->curh);
|
draw_cursor(cr, x, y, data->curw, data->curh);
|
||||||
igt_display_commit(display);
|
igt_display_commit(display);
|
||||||
|
|
||||||
igt_wait_for_vblank(data->drm_fd, data->pipe);
|
igt_wait_for_vblank(data->drm_fd, data->pipe);
|
||||||
igt_pipe_crc_collect_crc(pipe_crc, &ref_crc);
|
igt_pipe_crc_collect_crc(pipe_crc, &ref_crc);
|
||||||
/* Clear screen afterwards */
|
/* Clear screen afterwards */
|
||||||
|
igt_assert(igt_crc_equal(&crc, &ref_crc));
|
||||||
|
|
||||||
igt_paint_color(cr, 0, 0, data->screenw, data->screenh,
|
igt_paint_color(cr, 0, 0, data->screenw, data->screenh,
|
||||||
0.0, 0.0, 0.0);
|
0.0, 0.0, 0.0);
|
||||||
|
|
||||||
igt_assert(igt_crc_equal(&crc, &ref_crc));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void do_fail_test(data_t *data, int x, int y, int expect)
|
static void do_fail_test(data_t *data, int x, int y, int expect)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user