mirror of
https://github.com/tiagovignatti/intel-gpu-tools.git
synced 2026-08-21 21:32:56 +00:00
lib: Add a GPU error detector
If we listen to the uevents from the kernel, we can detect when the GPU hangs. This requires us to fork a helper process to do so and send a signal back to the parent. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
@@ -368,6 +368,8 @@ igt_main
|
||||
igt_fixture
|
||||
fd = drm_open_driver_master(DRIVER_INTEL);
|
||||
|
||||
igt_fork_hang_detector(fd);
|
||||
|
||||
for (const struct mode *m = modes; m->name; m++)
|
||||
igt_subtest_f("%s", *m->name ? m->name : "basic")
|
||||
whisper(fd, -1, m->flags);
|
||||
@@ -382,6 +384,8 @@ igt_main
|
||||
whisper(fd, e->exec_id | e->flags, m->flags);
|
||||
}
|
||||
|
||||
igt_stop_hang_detector();
|
||||
|
||||
igt_fixture
|
||||
close(fd);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user