anv: Query memory region info

Create additional memory type with DEVICE_LOCAL_BIT if we have local
memory region aviable.

v2 (Jason Ekstrand):
 - Don't leak mem_regions if the second ioctl fails

Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5599>
This commit is contained in:
Sagar Ghuge
2020-03-31 18:23:25 -07:00
committed by Marge Bot
parent aa3775c8e4
commit 65e8d72bc1
2 changed files with 53 additions and 0 deletions

View File

@@ -875,6 +875,7 @@ struct anv_memory_heap {
};
struct anv_memregion {
struct drm_i915_gem_memory_class_instance region;
uint64_t size;
};