mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2024-11-24 10:44:15 +08:00
anv: Fix PHYSICAL_DEVICE_MEMORY_BUDGET_PROPERTIES with large BAR
Reported-by: Dave Airlie <airlied@redhat.com>
Fixes: fae88d8791
("anv: make use of the new smallbar uAPI")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6937
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17761>
This commit is contained in:
parent
11e51f7211
commit
fa79020ba9
@ -2771,7 +2771,11 @@ anv_get_memory_budget(VkPhysicalDevice physicalDevice,
|
||||
|
||||
if (device->memory.heaps[i].is_local_mem) {
|
||||
total_heaps_size = total_vram_heaps_size;
|
||||
mem_available = device->vram_non_mappable.available;
|
||||
if (device->vram_non_mappable.size > 0 && i == 0) {
|
||||
mem_available = device->vram_non_mappable.available;
|
||||
} else {
|
||||
mem_available = device->vram_mappable.available;
|
||||
}
|
||||
} else {
|
||||
total_heaps_size = total_sys_heaps_size;
|
||||
mem_available = device->sys.available;
|
||||
|
Loading…
Reference in New Issue
Block a user