Commit b30d95f3 authored by Daniel Vetter's avatar Daniel Vetter

tests: s/exit(77)/igt_skip()/

Signed-off-by: Daniel Vetter's avatarDaniel Vetter <daniel.vetter@ffwll.ch>
parent c9d03782
......@@ -54,7 +54,7 @@ static uint32_t context_create(int fd)
ret = drmIoctl(fd, CONTEXT_CREATE_IOCTL, &create);
if (ret == -1 && (errno == ENODEV || errno == EINVAL))
exit(77);
igt_skip();
else if (ret)
abort();
......
......@@ -60,7 +60,7 @@ static uint32_t context_create(int fd)
ret = drmIoctl(fd, CONTEXT_CREATE_IOCTL, &create);
if (ret == -1 && (errno == ENODEV || errno == EINVAL)) {
exit(77);
igt_skip();
} else if (ret) {
abort();
}
......
......@@ -53,7 +53,7 @@ int main(int argc, char *argv[])
if (ret != 0 && (errno == ENODEV || errno == EINVAL)) {
printf("Kernel is too old, or contexts not supported: %s\n",
strerror(errno));
exit(77);
igt_skip();
} else if (ret != 0) {
fprintf(stderr, "%s\n", strerror(errno));
igt_fail(1);
......
......@@ -65,7 +65,7 @@ static uint32_t context_create(int fd)
ret = drmIoctl(fd, CONTEXT_CREATE_IOCTL, &create);
if (ret == -1 && (errno == ENODEV || errno == EINVAL))
exit(77);
igt_skip();
else if (ret)
abort();
......
......@@ -371,7 +371,7 @@ static int dfs_open(int mode)
fprintf(stderr,
"error %d opening '%s/%d/%s'. too old kernel?\n",
errno, dfs_base, card_index, dfs_entry);
exit(77);
igt_skip();
}
return fh;
......
......@@ -79,7 +79,7 @@ int main(int argc, char *argv[])
file = fopen(path, "r");
if (!file) {
printf("kernel too old or rc6 not supported on this platform.\n");
exit(77);
igt_skip();
}
/* claim success if no rc6 enabled. */
......
......@@ -150,7 +150,7 @@ int main(int argc, char *argv[])
junk->filp = fopen(path, junk->mode);
if (junk->filp == NULL) {
printf("Kernel is too old. GTFO\n");
exit(77);
igt_skip();
}
val = readval(junk->filp);
igt_assert(val >= 0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment