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

Michel Dänzer michel at daenzer.net
Mon Dec 5 09:39:18 UTC 2016


On 03/12/16 01:32 AM, Emil Velikov wrote:
> From: Emil Velikov <emil.velikov at collabora.com>
> 
> Pass along DRM_DEVICE_GET_PCI_REVISION only when the individual nodes
> are opened and update the printed messages accordingly.
> 
> v2: Attribute for the flag rename, call drmGetDevices2 w/o the flag.
> 
> Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
> Reviewed-by: Michel Dänzer <michel.daenzer at amd.com>

[...]

> diff --git a/xf86drm.c b/xf86drm.c
> index 52e9b9f..a886768 100644
> --- a/xf86drm.c
> +++ b/xf86drm.c
> @@ -3019,7 +3019,7 @@ static int drmParsePciDeviceInfo(int maj, int min,
>                                   uint32_t flags)
>  {
>  #ifdef __linux__
> -    if (flags & DRM_DEVICE_GET_PCI_REVISION == 0)
> +    if (!(flags & DRM_DEVICE_GET_PCI_REVISION))
>          return parse_separate_sysfs_files(maj, min, device, true);
>  
>      if (parse_separate_sysfs_files(maj, min, device, false))
> 

Please squash this hunk into patch 4 before pushing.


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the dri-devel mailing list