mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 13:58:04 +02:00
anv/device: Set device->info sooner in CreateDevice
anv_block_pool_init calls anv_block_pool_grow which checks device->info.has_llc to see if it needs to set caching parameters. If we don't set device->info early enough, this reads an undefined value which is probably 0 and not what we want on llc platforms. Found with valgrind.
This commit is contained in:
parent
763176a3e2
commit
9c84b6cce0
1 changed files with 3 additions and 3 deletions
|
|
@ -706,6 +706,9 @@ VkResult anv_CreateDevice(
|
|||
if (device->context_id == -1)
|
||||
goto fail_fd;
|
||||
|
||||
device->info = *physical_device->info;
|
||||
device->isl_dev = physical_device->isl_dev;
|
||||
|
||||
pthread_mutex_init(&device->mutex, NULL);
|
||||
|
||||
anv_bo_pool_init(&device->batch_bo_pool, device, ANV_CMD_BUFFER_BATCH_SIZE);
|
||||
|
|
@ -725,9 +728,6 @@ VkResult anv_CreateDevice(
|
|||
|
||||
anv_block_pool_init(&device->scratch_block_pool, device, 0x10000);
|
||||
|
||||
device->info = *physical_device->info;
|
||||
device->isl_dev = physical_device->isl_dev;
|
||||
|
||||
anv_queue_init(device, &device->queue);
|
||||
|
||||
anv_device_init_meta(device);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue