drm: Branch 'master' - 2 commits
[email protected] (Emil Velikov) Thu, 20 Jul 2017 11:31:17 +0000 (UTC)
| Newsgroups | gmane.comp.video.dri.patches |
|---|---|
| Message-ID | <[email protected]> |
xf86drm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) New commits: commit 3876bc246a07070a6043159cd7623d4def9bbd4c Author: Emil Velikov <[email protected]> Date: Thu Jul 20 12:25:27 2017 +0100 xf86drm: continue with next device if drmProcessUsbDevice fails Analogous to previous commit (and the rest of the codebase), simply discard the device if we cannot parse it. Fixes: f8484ccbd12 ("xf86drm: Add USB support") Signed-off-by: Emil Velikov <[email protected]> diff --git a/xf86drm.c b/xf86drm.c index f306c9b7..6ea01129 100644 --- a/xf86drm.c +++ b/xf86drm.c @@ -3989,7 +3989,7 @@ int drmGetDevices2(uint32_t flags, drmDevicePtr devices[], int max_devices) ret = drmProcessUsbDevice(&device, node, node_type, maj, min, devices != NULL, flags); if (ret) - goto free_devices; + continue; break; commit 5226b52773e0a9972cd1e0dade55cb9ae869941c Author: Gurchetan Singh <[email protected]> Date: Wed Jul 19 08:37:06 2017 -0700 xf86drm: continue after drmProcessPlatformDevice failure On ChromeOS devices, readdir() processes the directory in the following order: -NAME- -TYPE- . n/a .. n/a vgem n/a card1 DRM_BUS_PLATFORM renderD129 DRM_BUS_PLATFORM card0 DRM_BUS_PCI renderD128 DRM_BUS_PCI controlD64 DRM_BUS_PCI In drmGetDevices2, after drmProcessPlatformDevice fails for /dev/dri/card1, we don't process the remaining directory entries. As such, Vulkan fails to initialize since Mesa uses drmGetDevices2. To fix this, continue if drmProcessPlatformDevice fails. Fixes: 7b1f37f474d ("xf86drm: Add platform and host1x bus support") Reviewed-by: Emil Velikov <[email protected]> [Emil: correct the host1x platforms as well] Signed-off-by: Emil Velikov <[email protected]> diff --git a/xf86drm.c b/xf86drm.c index 879f85b6..f306c9b7 100644 --- a/xf86drm.c +++ b/xf86drm.c @@ -3997,7 +3997,7 @@ int drmGetDevices2(uint32_t flags, drmDevicePtr devices[], int max_devices) ret = drmProcessPlatformDevice(&device, node, node_type, maj, min, devices != NULL, flags); if (ret) - goto free_devices; + continue; break; @@ -4005,7 +4005,7 @@ int drmGetDevices2(uint32_t flags, drmDevicePtr devices[], int max_devices) ret = drmProcessHost1xDevice(&device, node, node_type, maj, min, devices != NULL, flags); if (ret) - goto free_devices; + continue; break; ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot --