anv: Use intel_engines_supported_count()
Signed-off-by: José Roberto de Souza <jose.souza@intel.com> Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25233>
This commit is contained in:

committed by
Marge Bot

parent
fe2982278f
commit
29ee85c203
@@ -2021,24 +2021,25 @@ anv_physical_device_init_queue_families(struct anv_physical_device *pdevice)
|
||||
kernel_supports_non_render_engines &&
|
||||
sparse_supports_non_render_engines;
|
||||
|
||||
if (debug_get_bool_option("INTEL_COMPUTE_CLASS", false)) {
|
||||
if (!can_use_non_render_engines)
|
||||
mesa_logw("cannot initialize compute engine");
|
||||
else
|
||||
c_count = intel_engines_count(pdevice->engine_info,
|
||||
INTEL_ENGINE_CLASS_COMPUTE);
|
||||
}
|
||||
if (!can_use_non_render_engines)
|
||||
mesa_logw("cannot initialize compute engine");
|
||||
else
|
||||
c_count = intel_engines_supported_count(pdevice->local_fd,
|
||||
&pdevice->info,
|
||||
pdevice->engine_info,
|
||||
INTEL_ENGINE_CLASS_COMPUTE);
|
||||
enum intel_engine_class compute_class =
|
||||
c_count < 1 ? INTEL_ENGINE_CLASS_RENDER : INTEL_ENGINE_CLASS_COMPUTE;
|
||||
|
||||
int blit_count = 0;
|
||||
if (debug_get_bool_option("INTEL_COPY_CLASS", true) &&
|
||||
pdevice->info.verx10 >= 125) {
|
||||
if (pdevice->info.verx10 >= 125) {
|
||||
if (!can_use_non_render_engines)
|
||||
mesa_logw("cannot initialize blitter engine");
|
||||
else
|
||||
blit_count = intel_engines_count(pdevice->engine_info,
|
||||
INTEL_ENGINE_CLASS_COPY);
|
||||
blit_count = intel_engines_supported_count(pdevice->local_fd,
|
||||
&pdevice->info,
|
||||
pdevice->engine_info,
|
||||
INTEL_ENGINE_CLASS_COPY);
|
||||
}
|
||||
|
||||
anv_override_engine_counts(&gc_count, &g_count, &c_count, &v_count);
|
||||
|
Reference in New Issue
Block a user