summaryrefslogtreecommitdiff
path: root/tests/gem_readwrite.c
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2009-04-06 17:13:01 -0400
committerKristian Høgsberg <krh@redhat.com>2009-04-06 17:13:01 -0400
commite9d6116e5bd30639d6333ef95462fe300f47ccd5 (patch)
treef704c598394685cffea66bf6bdccf88a1b6ea96e /tests/gem_readwrite.c
parent51d6346f9f3c425f49e57d185530c6bcaeb94f5e (diff)
Use libudev in test case to only run gem tests for intel devices.
Diffstat (limited to 'tests/gem_readwrite.c')
-rw-r--r--tests/gem_readwrite.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/gem_readwrite.c b/tests/gem_readwrite.c
index bd1d232b..4f5cde6c 100644
--- a/tests/gem_readwrite.c
+++ b/tests/gem_readwrite.c
@@ -78,7 +78,11 @@ int main(int argc, char **argv)
int ret;
int handle;
- fd = drm_open_any();
+ fd = drm_open_matching("8086:*", 0);
+ if (fd < 0) {
+ fprintf(stderr, "failed to open intel drm device, skipping\n");
+ return 0;
+ }
memset(&create, 0, sizeof(create));
create.size = OBJECT_SIZE;