Source
81
81
ret = ioctl(fd, DRM_IOCTL_I915_GEM_CREATE, &create);
82
82
assert(ret == 0);
83
83
84
84
close(fd);
85
85
}
86
86
87
87
int main(int argc, char **argv)
88
88
{
89
89
int fd;
90
90
91
-
fd = drm_open_any();
91
+
fd = drm_open_matching("8086:*", 0);
92
+
if (fd < 0) {
93
+
fprintf(stderr, "failed to open intel drm device\n");
94
+
return 0;
95
+
}
92
96
93
97
test_bad_close(fd);
94
98
test_create_close(fd);
95
99
test_create_fd_close(fd);
96
100
97
101
return 0;
98
102
}