venus: no supported device is not an error
Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Reviewed-by: Ryan Neph <ryanneph@google.com> Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12653>
This commit is contained in:
parent
fc74233363
commit
7dfac808b0
|
@ -1336,16 +1336,20 @@ vn_instance_enumerate_physical_devices(struct vn_instance *instance)
|
||||||
}
|
}
|
||||||
|
|
||||||
count = supported_count;
|
count = supported_count;
|
||||||
if (!count)
|
if (count) {
|
||||||
goto out;
|
result = vn_instance_enumerate_physical_device_groups_locked(
|
||||||
|
instance, physical_devs, count);
|
||||||
result = vn_instance_enumerate_physical_device_groups_locked(
|
if (result != VK_SUCCESS) {
|
||||||
instance, physical_devs, count);
|
for (uint32_t i = 0; i < count; i++)
|
||||||
if (result != VK_SUCCESS) {
|
vn_physical_device_fini(&physical_devs[i]);
|
||||||
for (uint32_t i = 0; i < count; i++)
|
count = 0;
|
||||||
vn_physical_device_fini(&physical_devs[i]);
|
goto out;
|
||||||
count = 0;
|
}
|
||||||
goto out;
|
} else {
|
||||||
|
/* no supported physical device is not an error */
|
||||||
|
result = VK_SUCCESS;
|
||||||
|
vk_free(alloc, physical_devs);
|
||||||
|
physical_devs = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
instance->physical_device.devices = physical_devs;
|
instance->physical_device.devices = physical_devs;
|
||||||
|
|
Loading…
Reference in New Issue