[PATCH libdrm 5/5] tests/drmdevice: use drmGetDevice[s]2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Emil Velikov <emil.velikov@xxxxxxxxxxxxx>

... alongside the DRM_DEVICE_IGNORE_PCI_REVISION flag.

Signed-off-by: Emil Velikov <emil.velikov@xxxxxxxxxxxxx>
---
 tests/drmdevice.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tests/drmdevice.c b/tests/drmdevice.c
index 72e7066..dcad527 100644
--- a/tests/drmdevice.c
+++ b/tests/drmdevice.c
@@ -70,7 +70,7 @@ main(void)
     drmDevicePtr device;
     int fd, ret, max_devices;
 
-    max_devices = drmGetDevices(NULL, 0);
+    max_devices = drmGetDevices2(DRM_DEVICE_IGNORE_PCI_REVISION, NULL, 0);
 
     if (max_devices <= 0) {
         printf("drmGetDevices() has returned %d\n", max_devices);
@@ -83,7 +83,7 @@ main(void)
         return -1;
     }
 
-    ret = drmGetDevices(devices, max_devices);
+    ret = drmGetDevices2(DRM_DEVICE_IGNORE_PCI_REVISION, devices, max_devices);
     if (ret < 0) {
         printf("drmGetDevices() returned an error %d\n", ret);
         free(devices);
@@ -102,7 +102,7 @@ main(void)
                     continue;
                 }
 
-                if (drmGetDevice(fd, &device) == 0) {
+                if (drmGetDevice2(fd, DRM_DEVICE_IGNORE_PCI_REVISION, &device) == 0) {
                     print_device_info(device, i);
                     drmFreeDevice(&device);
                 }
-- 
2.10.2

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux