From 4fd7a5f76dbde723a749ea8e9a8d68b73487b712 Mon Sep 17 00:00:00 2001 From: Abdiel Janulgue Date: Wed, 12 Jul 2017 12:06:55 +0300 Subject: tests/debugfs_test: Add a shorter timeout when reading sysfs entries This allows us to proceed gracefully without invoking the global CI-level timeout especially when opening the buggy crtc-data file descriptor. Signed-off-by: Abdiel Janulgue Reviewed-by: Arkadiusz Hiler --- tests/debugfs_test.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'tests/debugfs_test.c') diff --git a/tests/debugfs_test.c b/tests/debugfs_test.c index 287ffeb3..122f7dc8 100644 --- a/tests/debugfs_test.c +++ b/tests/debugfs_test.c @@ -50,8 +50,11 @@ static void read_and_discard_sysfs_entries(int path_fd, bool is_crc) read_and_discard_sysfs_entries(sub_fd, !strcmp(dirent->d_name, "crc")); close(sub_fd); } else { - char *buf = igt_sysfs_get(path_fd, dirent->d_name); + char *buf; + igt_set_timeout(5, "reading sysfs entry"); + buf = igt_sysfs_get(path_fd, dirent->d_name); + igt_reset_timeout(); /* * /crtc-XX/crc/data may fail with -EIO if the CRTC * is not active. -- cgit v1.2.3