summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/gem_flink.c2
-rw-r--r--tests/gem_mmap.c2
-rw-r--r--tests/gem_readwrite.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/tests/gem_flink.c b/tests/gem_flink.c
index ff999d2e..8dc88320 100644
--- a/tests/gem_flink.c
+++ b/tests/gem_flink.c
@@ -96,7 +96,7 @@ test_bad_flink(int fd)
flink.handle = 0x10101010;
ret = ioctl(fd, DRM_IOCTL_GEM_FLINK, &flink);
- assert(ret == -1 && errno == EBADF);
+ assert(ret == -1 && errno == ENOENT);
}
static void
diff --git a/tests/gem_mmap.c b/tests/gem_mmap.c
index d24005ba..2239789f 100644
--- a/tests/gem_mmap.c
+++ b/tests/gem_mmap.c
@@ -93,7 +93,7 @@ int main(int argc, char **argv)
mmap.size = 4096;
printf("Testing mmaping of bad object.\n");
ret = ioctl(fd, DRM_IOCTL_I915_GEM_MMAP, &mmap);
- assert(ret == -1 && errno == EBADF);
+ assert(ret == -1 && errno == ENOENT);
memset(&create, 0, sizeof(create));
create.size = OBJECT_SIZE;
diff --git a/tests/gem_readwrite.c b/tests/gem_readwrite.c
index 4f5cde6c..07dc853a 100644
--- a/tests/gem_readwrite.c
+++ b/tests/gem_readwrite.c
@@ -127,11 +127,11 @@ int main(int argc, char **argv)
printf("Testing read of bad buffer handle\n");
ret = do_read(fd, 1234, buf, 0, 1024);
- assert(ret == -1 && errno == EBADF);
+ assert(ret == -1 && errno == ENOENT);
printf("Testing write of bad buffer handle\n");
ret = do_write(fd, 1234, buf, 0, 1024);
- assert(ret == -1 && errno == EBADF);
+ assert(ret == -1 && errno == ENOENT);
close(fd);