On May 29, 2016 9:41 AM, "Emil Velikov" <emil.l.veli...@gmail.com> wrote: > > From: Emil Velikov <emil.veli...@collabora.com> > > Otherwise we'll end up setting up a device with no winsys integration.
Seems reasonable. Running headless isn't a problem but winsys failing to initialize basically only happens on out-of-memory so we should fail in that case. > Signed-off-by: Emil Velikov <emil.veli...@collabora.com> > --- > Hard-coding the rendernode name in anv_physical_device_init() is a bad > idea really. We could/should be using drmGetDevices() to get info on all > the devices (master/render/etc. node names, pci location etc.) and apply > our heuristics on top of that. Yes, we should come up with something better. Preferably that doesn't involve libdrm... 1 and 3 rb > That can come up as a follow up change. > --- > src/intel/vulkan/anv_device.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c > index da7a394..046777d 100644 > --- a/src/intel/vulkan/anv_device.c > +++ b/src/intel/vulkan/anv_device.c > @@ -150,7 +150,9 @@ anv_physical_device_init(struct anv_physical_device *device, > device->compiler->shader_debug_log = compiler_debug_log; > device->compiler->shader_perf_log = compiler_perf_log; > > - anv_init_wsi(device); > + result = anv_init_wsi(device); > + if (result != VK_SUCCESS) > + goto fail; > > /* XXX: Actually detect bit6 swizzling */ > isl_device_init(&device->isl_dev, device->info, swizzled); > -- > 2.8.2 > > _______________________________________________ > mesa-dev mailing list > mesa-dev@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/mesa-dev
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev